========================================================= Computing overlaps from file examples/lneed/lneed_fork.inp --------------------------------------------------------- ========================================================= Recognized function symbols in input: name arity strict-pos binder-arity ---- ----- ----- ----- \ 1 [] [1] app 2 [1] [0,0] ========================================================= --------------------------------------------------------- ================================================================================ Critical Pair: ( A#9[(app (\ X#5.S#7) T#11[(letrec {E#1;E#2} in S#3)])] , A#9[(letrec {X#5=T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#7)] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#5.[.])), (T#11[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (\ X#5.S#7) T#11)], T#10 |-> (app (\ X#5.S#7) T#11), S#6 |-> T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: A#9[(app (\ X#5.S#7) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] <-llet-in1- A#9[(app (\ X#5.S#7) T#11[(letrec {E#1;E#2} in S#3)])] ................................................................................ A#9[(app (\ X#5.S#7) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] -SR,lbeta1-> A#9[(letrec {X#5=T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#7)] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] , A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] ) where Delta1 = {A#8,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] <-llet-in1- A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] ................................................................................ A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] -SR,lbeta1-> A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] ================================================================================ Critical Pair: ( (app (\ X#5.S#7) T#9[(letrec {E#1;E#2} in S#3)]) , (letrec {X#5=T#9[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#9[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#5.[.])), (T#9[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (\ X#5.S#7) T#9), S#6 |-> T#9[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (app (\ X#5.S#7) T#9[(letrec {E#1} in (letrec {E#2} in S#3))]) <-llet-in1- (app (\ X#5.S#7) T#9[(letrec {E#1;E#2} in S#3)]) ................................................................................ (app (\ X#5.S#7) T#9[(letrec {E#1} in (letrec {E#2} in S#3))]) -SR,lbeta1-> (letrec {X#5=T#9[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#7) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1;E#2} in S#3)])]) , (letrec E#6 in A#11[(letrec {X#5=T#13[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#8)] ) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#13[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#5.[.])), (T#13[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (\ X#5.S#8) T#13)], T#12 |-> (app (\ X#5.S#8) T#13), S#7 |-> T#13[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#5=T#13[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#6 in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])] ) , (letrec E#6 in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,lbeta2-> (letrec {E#6} in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1;E#2} in S#3)])) , (letrec E#6 in (letrec {X#5=T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#8) ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#5.[.])), (T#11[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (\ X#5.S#8) T#11)), A#9 |-> [.], T#10 |-> (app (\ X#5.S#8) T#11), S#7 |-> T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])) <-llet-in1- (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1;E#2} in S#3)])) ................................................................................ (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])) -SR,lbeta2-> (letrec {E#6} in (letrec {X#5=T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#8)) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;E#13 in A#9[(app (\ X#5.S#8) S#7)] ) , (letrec X#11= T#10[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#13 in A#9[(letrec {X#5=S#7} in S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (\ X#5.S#8) S#7)]), E#6 |-> {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in A#9[(app (\ X#5.S#8) S#7)]) <-llet-in1- (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in A#9[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])] ) , (letrec E#7 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;E#15 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#15 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), E#7 |-> {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#6=T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9)] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#6.[.])), (T#18[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (\ X#6.S#9) T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16, T#12 |-> A#16[(app (\ X#6.S#9) T#18)], T#17 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#6=T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]}, X#13 |-> X#5, E#14 |-> {E#7}, T#12 |-> A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (\ X#6.S#9) T#16[(letrec {E#1;E#2} in S#3)]) ;E#7 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#6=T#16[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9) ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#16[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#6.[.])), (T#16[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (\ X#6.S#9) T#16);E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#16), S#8 |-> T#16[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1} in (letrec {E#2} in S#3))]);E#7} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1;E#2} in S#3)]);E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1} in (letrec {E#2} in S#3))]);E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=(letrec {X#6=T#16[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9);E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#17[X#16,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#7 ;EE#17[X#16,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#16,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (\ X#6.S#9) T#20[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#6=T#20[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#20[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#6.[.])), (T#20[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (\ X#6.S#9) T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (\ X#6.S#9) T#20)], T#19 |-> (app (\ X#6.S#9) T#20), S#8 |-> T#20[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#6=T#20[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)]) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#6=T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1} in (letrec {E#2} in S#3))],(\ X#6.[.])), (T#18[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (\ X#6.S#9) T#18);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=(letrec {X#6=T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} in S#9);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(\ X#6.S#8)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,cp-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(\ X#6.S#8)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(\ X#6.S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13}, E#12 |-> {X#5=(\ X#6.S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) <-llet-in1- (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#8);E#13} in A#9[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1;E#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(\ X#6.S#9)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(\ X#6.S#9)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(var X#7)] ) , (letrec X#13= T#12[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(\ X#6.S#9)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#10[[.]]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]), E#8 |-> {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15}, E#14 |-> {X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) <-llet-in1- (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(var X#5)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1;E#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#11,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#14= T#13[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]), E#8 |-> {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#16}, E#15 |-> {X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]}} and instantiated rules: (letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) <-llet-in1- (letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])]] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#10,A#17} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#19[(app A#20[[.]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21)]];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> A#17, T#13 |-> A#17[A#19[(app A#20[(var X#5)] T#21)]], T#18 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]];E#8} in A#11[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])]];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1;E#2} in S#3)])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, T#13 |-> A#17[(app A#18[A#10[(var X#5)]] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#11[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(var X#5)] T#19[(letrec {E#1;E#2} in S#3)])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(\ X#6.S#9)] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#17[(app A#18[[.]] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> [.], T#13 |-> A#17[(app A#18[(var X#5)] T#19)], A#10 |-> A#17[(app A#18 T#19[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#11[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(\ X#6.S#9)] T#19[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])] ;E#8 ;EE#18[X#17,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#8 ;EE#18[X#17,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#17,A#10[(var X#5)]]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#18[X#17,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) <-llet-in1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1;E#2} in S#3)])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#10,A#19} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#21[(app A#22[[.]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23)]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[A#21[(app A#22[(var X#5)] T#23)]], T#20 |-> A#21[(app A#22[(var X#5)] T#23)], A#10 |-> A#21[(app A#22 T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-llet-in1- (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[A#10[(var X#5)]] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-llet-in1- (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),A#19[(app A#20[[.]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(var X#5)] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> [.], T#13 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-llet-in1- (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1;E#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#12,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18)]), T#15 |-> A#16[(app A#17[(var X#7)] T#18)], A#12 |-> A#16[(app A#17 T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#16= T#15[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=T#15;X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), E#9 |-> {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18}, E#17 |-> {X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}} and instantiated rules: (letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#20,A#18,T#15,T#4,A#11,A#19} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23)]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#8)] T#23)]], T#20 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1;E#2} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, T#15 |-> A#19[(app A#20[A#11[(var X#8)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(var X#8)] T#21[(letrec {E#1;E#2} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(\ X#6.S#10)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#19[(app A#20[[.]] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#11 |-> A#19[(app A#20 T#21[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(\ X#6.S#10)] T#21[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])] ;E#9 ;EE#20[X#19,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#9 ;EE#20[X#19,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#20[X#19,[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];E#9;EE#20[X#19,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1;E#2} in S#3)])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#22,A#18,T#15,T#4,A#11,A#21} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#23[(app A#24[[.]] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25)]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#8)] T#25)]], T#22 |-> A#23[(app A#24[(var X#8)] T#25)], A#11 |-> A#23[(app A#24 T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(letrec {E#1} in (letrec {E#2} in S#3))])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[A#11[(var X#8)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-llet-in1- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1;E#2} in S#3)])) , (letrec {E#5;E#6} in T#9[(letrec {E#1} in (letrec {E#2} in S#3))]) ) where Delta1 = {T#8,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], [{E#5},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {E#6} in T#9)), T#8 |-> (letrec {E#6} in T#9), S#7 |-> T#9[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1} in (letrec {E#2} in S#3))])) <-llet-in1- (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1;E#2} in S#3)])) ................................................................................ (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1} in (letrec {E#2} in S#3))])) -SR,llet-in1-> (letrec {E#5;E#6} in T#9[(letrec {E#1} in (letrec {E#2} in S#3))]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12} in S#7)) , (letrec {X#10=T#9[(letrec {E#1} in (letrec {E#2} in S#3))];E#12;E#5} in S#7) ) where Delta1 = {T#8,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], [{E#5},(letrec {X#10=T#9[(letrec {E#1} in (letrec {E#2} in S#3))];E#12} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {X#10=T#9;E#12} in S#7)), T#8 |-> (letrec {X#10=T#9;E#12} in S#7), E#6 |-> {X#10=T#9[(letrec {E#1} in (letrec {E#2} in S#3))];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1} in (letrec {E#2} in S#3))];E#12} in S#7)) <-llet-in1- (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12} in S#7)) ................................................................................ (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1} in (letrec {E#2} in S#3))];E#12} in S#7)) -SR,llet-in1-> (letrec {X#10=T#9[(letrec {E#1} in (letrec {E#2} in S#3))];E#12;E#5} in S#7) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#1;E#2} in S#3)) , (letrec {E#1;E#5} in (letrec {E#2} in S#3)) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], [{E#5},(letrec {E#1} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in [.]), T#8 |-> [.], S#7 |-> (letrec {E#2} in S#3), E#6 |-> {E#1}} and instantiated rules: (letrec {E#5} in (letrec {E#1} in (letrec {E#2} in S#3))) <-llet-in1- (letrec {E#5} in (letrec {E#1;E#2} in S#3)) ................................................................................ (letrec {E#5} in (letrec {E#1} in (letrec {E#2} in S#3))) -SR,llet-in1-> (letrec {E#1;E#5} in (letrec {E#2} in S#3)) ================================================================================ Critical Pair: ( (letrec {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11} in (letrec {E#6} in S#7)) , (letrec {X#9=T#8[(letrec {E#1} in (letrec {E#2} in S#3))];E#11;E#6} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], [{X#9=T#8[(letrec {E#1} in (letrec {E#2} in S#3))];E#11},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {X#9=T#8;E#11} in (letrec {E#6} in S#7)), E#5 |-> {X#9=T#8[(letrec {E#1} in (letrec {E#2} in S#3))];E#11}, E#10 |-> {E#11}} and instantiated rules: (letrec {X#9=T#8[(letrec {E#1} in (letrec {E#2} in S#3))];E#11} in (letrec {E#6} in S#7)) <-llet-in1- (letrec {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11} in (letrec {E#6} in S#7)) ................................................................................ (letrec {X#9=T#8[(letrec {E#1} in (letrec {E#2} in S#3))];E#11} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {X#9=T#8[(letrec {E#1} in (letrec {E#2} in S#3))];E#11;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec {E#5;E#6} in S#7) , (letrec {E#5;E#6} in S#7) ) where Delta1 = {} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#5},(letrec {E#6} in [.])], [{E#5},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> [.], S#3 |-> S#7, E#2 |-> {E#6}, E#1 |-> {E#5}} and instantiated rules: (letrec {E#5} in (letrec {E#6} in S#7)) <-llet-in1- (letrec {E#5;E#6} in S#7) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])] ) , (letrec X#5= S#8 ;E#6 ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in T#13[(letrec {E#1;E#2} in S#3)]) ;E#7 in A#9[(var X#5)] ) , (letrec X#5= T#13[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#6 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in T#13);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1} in (letrec {E#2} in S#3))]);E#7} in A#9[(var X#5)]) <-llet-in1- (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1;E#2} in S#3)]);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1} in (letrec {E#2} in S#3))]);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#6;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16} in S#8) ;E#7 in A#9[(var X#5)] ) , (letrec X#14= T#13[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= S#8 ;E#16 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#16} in [.])), [{E#7},(letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#16} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#14=T#13;E#16} in S#8);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#16} in S#8);E#7} in A#9[(var X#5)]) <-llet-in1- (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16} in S#8);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];E#16} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#14=T#13[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=S#8;E#16;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#1;E#2} in S#3);E#7} in A#9[(var X#5)]) , (letrec {X#5=(letrec {E#2} in S#3);E#1;E#7} in A#9[(var X#5)]) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#1} in [.])), [{E#7},(letrec {E#1} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=[.];E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> [.], S#8 |-> (letrec {E#2} in S#3), E#6 |-> {E#1}} and instantiated rules: (letrec {X#5=(letrec {E#1} in (letrec {E#2} in S#3));E#7} in A#9[(var X#5)]) <-llet-in1- (letrec {X#5=(letrec {E#1;E#2} in S#3);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#1} in (letrec {E#2} in S#3));E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=(letrec {E#2} in S#3);E#1;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;X#5= (letrec {E#6} in S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= S#8 ;E#13 ;E#6 in A#9[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13}, E#12 |-> {X#5=(letrec {E#6} in S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) <-llet-in1- (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=S#8;E#13;E#6} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])] ) , (letrec X#5= S#9 ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15)]), T#12 |-> A#13[(app A#14[(var X#6)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in T#15[(letrec {E#1;E#2} in S#3)]) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= T#15[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in T#15);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1} in (letrec {E#2} in S#3))]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1;E#2} in S#3)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1} in (letrec {E#2} in S#3))]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= T#15[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= S#9 ;E#18 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#16=T#15;E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=T#15[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=S#9;E#18;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#1;E#2} in S#3) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= (letrec {E#2} in S#3) ;E#1 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {E#1;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#1} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#1} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=[.];E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> [.], S#9 |-> (letrec {E#2} in S#3), E#7 |-> {E#1}} and instantiated rules: (letrec {X#5=(letrec {E#1} in (letrec {E#2} in S#3));E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#5=(letrec {E#1;E#2} in S#3);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#1} in (letrec {E#2} in S#3));E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=(letrec {E#2} in S#3);E#1;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;X#5= (letrec {E#7} in S#9) ;E#15 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#13= T#12[(letrec {E#1} in (letrec {E#2} in S#3))] ;X#5= S#9 ;E#15 ;E#7 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;E#7;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), E#8 |-> {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15}, E#14 |-> {X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];X#5=S#9;E#15;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])] ;E#8 in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;E#8} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18)];E#8} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8}, T#12 |-> A#16[(app A#17[(var X#5)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#10[(var X#6)]) <-llet-in1- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])];E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#7 ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;E#8;EE#17[X#16,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#17[X#16,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20)];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#17[X#16,[.2]]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#16,(var X#5)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= S#9 ;E#7 ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=S#9;E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])] ;X#5= S#9 ;E#7 ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#7;E#8;EE#17[X#6,(var X#16)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#8;EE#17[X#6,(var X#16)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20)];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]}, T#12 |-> A#18[(app A#19[(var X#5)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-llet-in1- (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];X#5=S#9;E#7;E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in T#12[(letrec {E#1;E#2} in S#3)]) S#6)] , A#9[(letrec {E#5} in (app T#12[(letrec {E#1} in (letrec {E#2} in S#3))] S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in T#12) S#6)], T#10 |-> (app (letrec {E#5} in T#12) S#6), T#11 |-> (letrec {E#5} in T#12), S#7 |-> T#12[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: A#9[(app (letrec {E#5} in T#12[(letrec {E#1} in (letrec {E#2} in S#3))]) S#6)] <-llet-in1- A#9[(app (letrec {E#5} in T#12[(letrec {E#1;E#2} in S#3)]) S#6)] ................................................................................ A#9[(app (letrec {E#5} in T#12[(letrec {E#1} in (letrec {E#2} in S#3))]) S#6)] -SR,lapp1-> A#9[(letrec {E#5} in (app T#12[(letrec {E#1} in (letrec {E#2} in S#3))] S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#7) S#6)] , A#9[(letrec X#13= T#12[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#15 in (app S#7 S#6) )] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {X#13=T#12;E#15} in S#7) S#6)], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#7) S#6), T#11 |-> (letrec {X#13=T#12;E#15} in S#7), E#5 |-> {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15}, E#14 |-> {E#15}} and instantiated rules: A#9[(app (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in S#7) S#6)] <-llet-in1- A#9[(app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#7) S#6)] ................................................................................ A#9[(app (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#1;E#2} in S#3) S#6)] , A#9[(letrec {E#1} in (app (letrec {E#2} in S#3) S#6))] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app [.] S#6)], T#10 |-> (app [.] S#6), T#11 |-> [.], S#7 |-> (letrec {E#2} in S#3), E#5 |-> {E#1}} and instantiated rules: A#9[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#6)] <-llet-in1- A#9[(app (letrec {E#1;E#2} in S#3) S#6)] ................................................................................ A#9[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#6)] -SR,lapp1-> A#9[(letrec {E#1} in (app (letrec {E#2} in S#3) S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1;E#2} in S#3)])] , A#9[(letrec {E#5} in (app S#7 T#11[(letrec {E#1} in (letrec {E#2} in S#3))]))] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in S#7) T#11)], T#10 |-> (app (letrec {E#5} in S#7) T#11), S#6 |-> T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] <-llet-in1- A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1;E#2} in S#3)])] ................................................................................ A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] -SR,lapp1-> A#9[(letrec {E#5} in (app S#7 T#11[(letrec {E#1} in (letrec {E#2} in S#3))]))] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] , A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] ) where Delta1 = {A#8,T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] <-llet-in1- A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] ................................................................................ A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] -SR,lapp1-> A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(letrec {E#1} in (letrec {E#2} in S#3))])] ================================================================================ Critical Pair: ( (app (letrec {E#5} in T#10[(letrec {E#1;E#2} in S#3)]) S#6) , (letrec {E#5} in (app T#10[(letrec {E#1} in (letrec {E#2} in S#3))] S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in T#10) S#6), T#9 |-> (letrec {E#5} in T#10), S#7 |-> T#10[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (app (letrec {E#5} in T#10[(letrec {E#1} in (letrec {E#2} in S#3))]) S#6) <-llet-in1- (app (letrec {E#5} in T#10[(letrec {E#1;E#2} in S#3)]) S#6) ................................................................................ (app (letrec {E#5} in T#10[(letrec {E#1} in (letrec {E#2} in S#3))]) S#6) -SR,lapp1-> (letrec {E#5} in (app T#10[(letrec {E#1} in (letrec {E#2} in S#3))] S#6)) ================================================================================ Critical Pair: ( (app (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in S#7) S#6) , (letrec X#11= T#10[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#13 in (app S#7 S#6) ) ) where Delta1 = {T#9,T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {X#11=T#10;E#13} in S#7) S#6), T#9 |-> (letrec {X#11=T#10;E#13} in S#7), E#5 |-> {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13}, E#12 |-> {E#13}} and instantiated rules: (app (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in S#7) S#6) <-llet-in1- (app (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in S#7) S#6) ................................................................................ (app (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in S#7) S#6) -SR,lapp1-> (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in (app S#7 S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#1;E#2} in S#3) S#6) , (letrec {E#1} in (app (letrec {E#2} in S#3) S#6)) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app [.] S#6), T#9 |-> [.], S#7 |-> (letrec {E#2} in S#3), E#5 |-> {E#1}} and instantiated rules: (app (letrec {E#1} in (letrec {E#2} in S#3)) S#6) <-llet-in1- (app (letrec {E#1;E#2} in S#3) S#6) ................................................................................ (app (letrec {E#1} in (letrec {E#2} in S#3)) S#6) -SR,lapp1-> (letrec {E#1} in (app (letrec {E#2} in S#3) S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#5} in S#7) T#9[(letrec {E#1;E#2} in S#3)]) , (letrec {E#5} in (app S#7 T#9[(letrec {E#1} in (letrec {E#2} in S#3))])) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#9[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in S#7) T#9), S#6 |-> T#9[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (app (letrec {E#5} in S#7) T#9[(letrec {E#1} in (letrec {E#2} in S#3))]) <-llet-in1- (app (letrec {E#5} in S#7) T#9[(letrec {E#1;E#2} in S#3)]) ................................................................................ (app (letrec {E#5} in S#7) T#9[(letrec {E#1} in (letrec {E#2} in S#3))]) -SR,lapp1-> (letrec {E#5} in (app S#7 T#9[(letrec {E#1} in (letrec {E#2} in S#3))])) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {E#6} in T#14[(letrec {E#1;E#2} in S#3)]) S#7)] ) , (letrec E#5 in A#11[(letrec {E#6} in (app T#14[(letrec {E#1} in (letrec {E#2} in S#3))] S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in T#14) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in T#14) S#7)], T#12 |-> (app (letrec {E#6} in T#14) S#7), T#13 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1} in (letrec {E#2} in S#3))]) S#7)]) <-llet-in1- (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1;E#2} in S#3)]) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1} in (letrec {E#2} in S#3))]) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app T#14[(letrec {E#1} in (letrec {E#2} in S#3))] S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in S#8) S#7)] ) , (letrec E#5 in A#11[(letrec X#15= T#14[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#17 in (app S#8 S#7) )] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {X#15=T#14[(letrec {E#1} in (letrec {E#2} in S#3))];E#17} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#8) S#7), T#13 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(letrec {E#1} in (letrec {E#2} in S#3))];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1} in (letrec {E#2} in S#3))];E#17} in S#8) S#7)]) <-llet-in1- (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in S#8) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1} in (letrec {E#2} in S#3))];E#17} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {X#15=T#14[(letrec {E#1} in (letrec {E#2} in S#3))];E#17} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {E#1;E#2} in S#3) S#7)]) , (letrec {E#5} in A#11[(letrec {E#1} in (app (letrec {E#2} in S#3) S#7))]) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app [.] S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app [.] S#7)], T#12 |-> (app [.] S#7), T#13 |-> [.], S#8 |-> (letrec {E#2} in S#3), E#6 |-> {E#1}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#7)]) <-llet-in1- (letrec {E#5} in A#11[(app (letrec {E#1;E#2} in S#3) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#1} in (app (letrec {E#2} in S#3) S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1;E#2} in S#3)])] ) , (letrec E#5 in A#11[(letrec {E#6} in (app S#8 T#13[(letrec {E#1} in (letrec {E#2} in S#3))]))] ) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#13[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in S#8) T#13)], T#12 |-> (app (letrec {E#6} in S#8) T#13), S#7 |-> T#13[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 T#13[(letrec {E#1} in (letrec {E#2} in S#3))]))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])] ) , (letrec E#5 in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,lapp2-> (letrec {E#5} in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1;E#2} in S#3)]) S#7)) , (letrec E#5 in (letrec {E#6} in (app T#12[(letrec {E#1} in (letrec {E#2} in S#3))] S#7)) ) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in T#12) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in T#12) S#7), T#11 |-> (letrec {E#6} in T#12), S#8 |-> T#12[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1} in (letrec {E#2} in S#3))]) S#7)) <-llet-in1- (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1;E#2} in S#3)]) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1} in (letrec {E#2} in S#3))]) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app T#12[(letrec {E#1} in (letrec {E#2} in S#3))] S#7))) ================================================================================ Critical Pair: ( (letrec E#5 in (app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#8) S#7) ) , (letrec E#5 in (letrec X#13= T#12[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#15 in (app S#8 S#7) ) ) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {X#13=T#12;E#15} in S#8) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#8) S#7), T#11 |-> (letrec {X#13=T#12;E#15} in S#8), E#6 |-> {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in S#8) S#7)) <-llet-in1- (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#8) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in S#8) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#1;E#2} in S#3) S#7)) , (letrec {E#5} in (letrec {E#1} in (app (letrec {E#2} in S#3) S#7))) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app [.] S#7)), A#9 |-> [.], T#10 |-> (app [.] S#7), T#11 |-> [.], S#8 |-> (letrec {E#2} in S#3), E#6 |-> {E#1}} and instantiated rules: (letrec {E#5} in (app (letrec {E#1} in (letrec {E#2} in S#3)) S#7)) <-llet-in1- (letrec {E#5} in (app (letrec {E#1;E#2} in S#3) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#1} in (letrec {E#2} in S#3)) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#1} in (app (letrec {E#2} in S#3) S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1;E#2} in S#3)])) , (letrec E#5 in (letrec {E#6} in (app S#8 T#11[(letrec {E#1} in (letrec {E#2} in S#3))])) ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in S#8) T#11)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in S#8) T#11), S#7 |-> T#11[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])) <-llet-in1- (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1;E#2} in S#3)])) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1} in (letrec {E#2} in S#3))])) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(letrec {E#1} in (letrec {E#2} in S#3))]))) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;E#13 in A#9[(app (letrec {E#6} in S#8) S#7)] ) , (letrec X#11= T#10[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#13 in A#9[(letrec {E#6} in (app S#8 S#7))] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]), E#5 |-> {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) <-llet-in1- (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {X#11=T#10[(letrec {E#1} in (letrec {E#2} in S#3))];E#13} in A#9[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec E#6 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])] ) , (letrec E#6 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) <-llet-in1- (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (letrec {E#2} in S#3))])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;E#15 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#15 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), E#6 |-> {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#13=T#12[(letrec {E#1} in (letrec {E#2} in S#3))];E#15;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app T#19[(letrec {E#1} in (letrec {E#2} in S#3))] S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in T#19) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in T#19) S#8)], T#17 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8)];E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app T#19[(letrec {E#1} in (letrec {E#2} in S#3))] S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec X#20= T#19[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#22 in (app S#9 S#8) )] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)], T#17 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(app (letrec {E#1;E#2} in S#3) S#8)];E#6} in A#10[(var X#5)]) , (letrec X#5= A#16[(letrec {E#1} in (app (letrec {E#2} in S#3) S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app [.] S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app [.] S#8)], T#17 |-> (app [.] S#8), T#18 |-> [.], S#9 |-> (letrec {E#2} in S#3), E#7 |-> {E#1}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8)];E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app (letrec {E#1;E#2} in S#3) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#1} in (app (letrec {E#2} in S#3) S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app S#9 T#18[(letrec {E#1} in (letrec {E#2} in S#3))]))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in S#9) T#18)], T#17 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app S#9 T#18[(letrec {E#1} in (letrec {E#2} in S#3))]))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]}, X#13 |-> X#5, E#14 |-> {E#6}, T#12 |-> A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in T#17[(letrec {E#1;E#2} in S#3)]) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app T#17[(letrec {E#1} in (letrec {E#2} in S#3))] S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in T#17) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#17) S#8), T#16 |-> (letrec {E#7} in T#17), S#9 |-> T#17[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8);E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1;E#2} in S#3)]) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app T#17[(letrec {E#1} in (letrec {E#2} in S#3))] S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in S#9) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec X#18= T#17[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#20 in (app S#9 S#8) ) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#18=T#17[(letrec {E#1} in (letrec {E#2} in S#3))];E#20} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {X#18=T#17;E#20} in S#9) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {X#18=T#17;E#20} in S#9) S#8), T#16 |-> (letrec {X#18=T#17;E#20} in S#9), E#7 |-> {X#18=T#17[(letrec {E#1} in (letrec {E#2} in S#3))];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1} in (letrec {E#2} in S#3))];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1} in (letrec {E#2} in S#3))];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {X#18=T#17[(letrec {E#1} in (letrec {E#2} in S#3))];E#20} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(app (letrec {E#1;E#2} in S#3) S#8);E#6} in A#10[(var X#5)]) , (letrec X#5= (letrec {E#1} in (app (letrec {E#2} in S#3) S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app [.] S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app [.] S#8), T#16 |-> [.], S#9 |-> (letrec {E#2} in S#3), E#7 |-> {E#1}} and instantiated rules: (letrec {X#5=(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8);E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=(app (letrec {E#1;E#2} in S#3) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#1} in (app (letrec {E#2} in S#3) S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in S#9) T#16[(letrec {E#1;E#2} in S#3)]) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app S#9 T#16[(letrec {E#1} in (letrec {E#2} in S#3))])) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#16[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in S#9) T#16);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#16), S#8 |-> T#16[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1} in (letrec {E#2} in S#3))]);E#6} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1;E#2} in S#3)]);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1} in (letrec {E#2} in S#3))]);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app S#9 T#16[(letrec {E#1} in (letrec {E#2} in S#3))]));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#6 ;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in T#21[(letrec {E#1;E#2} in S#3)]) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app T#21[(letrec {E#1} in (letrec {E#2} in S#3))] S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in T#21) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in T#21) S#8)], T#19 |-> (app (letrec {E#7} in T#21) S#8), T#20 |-> (letrec {E#7} in T#21), S#9 |-> T#21[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1;E#2} in S#3)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app T#21[(letrec {E#1} in (letrec {E#2} in S#3))] S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in S#9) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec X#22= T#21[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#24 in (app S#9 S#8) )] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#22=T#21[(letrec {E#1} in (letrec {E#2} in S#3))];E#24} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#9) S#8), T#20 |-> (letrec {X#22=T#21;E#24} in S#9), E#7 |-> {X#22=T#21[(letrec {E#1} in (letrec {E#2} in S#3))];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1} in (letrec {E#2} in S#3))];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1} in (letrec {E#2} in S#3))];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {X#22=T#21[(letrec {E#1} in (letrec {E#2} in S#3))];E#24} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#1;E#2} in S#3) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#1} in (app (letrec {E#2} in S#3) S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app [.] S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app [.] S#8)], T#19 |-> (app [.] S#8), T#20 |-> [.], S#9 |-> (letrec {E#2} in S#3), E#7 |-> {E#1}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app (letrec {E#1;E#2} in S#3) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#1} in (app (letrec {E#2} in S#3) S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app S#9 T#20[(letrec {E#1} in (letrec {E#2} in S#3))]))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#20[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in S#9) T#20)], T#19 |-> (app (letrec {E#7} in S#9) T#20), S#8 |-> T#20[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app S#9 T#20[(letrec {E#1} in (letrec {E#2} in S#3))]))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in (letrec {E#2} in S#3))])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(letrec {E#1} in (letrec {E#2} in S#3))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app T#19[(letrec {E#1} in (letrec {E#2} in S#3))] S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in T#19) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1} in (letrec {E#2} in S#3))]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app T#19[(letrec {E#1} in (letrec {E#2} in S#3))] S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec X#20= T#19[(letrec {E#1} in (letrec {E#2} in S#3))] ;E#22 in (app S#9 S#8) ) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {X#20=T#19;E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {X#20=T#19[(letrec {E#1} in (letrec {E#2} in S#3))];E#22} in (app S#9 S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#1;E#2} in S#3) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#1} in (app (letrec {E#2} in S#3) S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app [.] S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app [.] S#8), T#18 |-> [.], S#9 |-> (letrec {E#2} in S#3), E#7 |-> {E#1}} and instantiated rules: (letrec {X#16=(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=(app (letrec {E#1;E#2} in S#3) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#1} in (letrec {E#2} in S#3)) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#1} in (app (letrec {E#2} in S#3) S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)]) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app S#9 T#18[(letrec {E#1} in (letrec {E#2} in S#3))])) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {[{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1} in (letrec {E#2} in S#3))],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-in1-> with input rules: T#4[(letrec {E#1} in (letrec {E#2} in S#3))] <-llet-in1- T#4[(letrec {E#1;E#2} in S#3)] and constraints: E#1/= {}, E#2/= {}, ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1} in (letrec {E#2} in S#3))] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in S#9) T#18);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(letrec {E#1} in (letrec {E#2} in S#3))]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-llet-in1- (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (letrec {E#2} in S#3))]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app S#9 T#18[(letrec {E#1} in (letrec {E#2} in S#3))]));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] , A#11[(letrec {X#7=T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#9)] ) where Delta1 = {T#12,A#10,T#6,A#11} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#7.[.])), (T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#7=[.]} in S#9))} Delta4= {} from overlapping <-SR,lbeta1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9))} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (\ X#7.S#9) T#13)], T#12 |-> (app (\ X#7.S#9) T#13), S#8 |-> T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] <-llet-e1- A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ................................................................................ A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] -SR,lbeta1-> A#11[(letrec {X#7=T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#9)] ================================================================================ Critical Pair: ( A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] , A#11[(app A#12[(letrec {X#7=S#8} in S#9)] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) where Delta1 = {A#10,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9))} Delta4= {} from overlapping <-SR,lbeta1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9))} and found solution: Sol = {T#6 |-> A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13)], A#10 |-> A#11[(app A#12 T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] <-llet-e1- A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ................................................................................ A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] -SR,lbeta1-> A#11[(app A#12[(letrec {X#7=S#8} in S#9)] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ================================================================================ Critical Pair: ( (app (\ X#7.S#9) T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)]) , (letrec {X#7=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#9) ) where Delta1 = {T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#7.[.])), (T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#7=[.]} in S#9))} Delta4= {} from overlapping <-SR,lbeta1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9))} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (\ X#7.S#9) T#11), S#8 |-> T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (app (\ X#7.S#9) T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) <-llet-e1- (app (\ X#7.S#9) T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ................................................................................ (app (\ X#7.S#9) T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) -SR,lbeta1-> (letrec {X#7=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#9) ================================================================================ Critical Pair: ( (letrec E#8 in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec E#8 in A#13[(letrec {X#7=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#10)] ) ) where Delta1 = {T#14,A#11,T#12,T#6,A#13} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#7.[.])), (T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#7=[.]} in S#10))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10))} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15)]), A#11 |-> A#13, T#12 |-> A#13[(app (\ X#7.S#10) T#15)], T#14 |-> (app (\ X#7.S#10) T#15), S#9 |-> T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,lbeta2-> (letrec {E#8} in A#13[(letrec {X#7=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#10)]) ================================================================================ Critical Pair: ( (letrec E#8 in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec E#8 in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10))} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15)]), T#12 |-> A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,lbeta2-> (letrec {E#8} in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])) , (letrec E#8 in (letrec {X#7=T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#10) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#7.[.])), (T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#7=[.]} in S#10))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10))} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (\ X#7.S#10) T#13)), A#11 |-> [.], T#12 |-> (app (\ X#7.S#10) T#13), S#9 |-> T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) <-llet-e1- (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])) ................................................................................ (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) -SR,lbeta2-> (letrec {E#8} in (letrec {X#7=T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#10)) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;E#15 in A#11[(app (\ X#7.S#10) S#9)] ) , (letrec X#13= T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#15 in A#11[(letrec {X#7=S#9} in S#10)] ) ) where Delta1 = {T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10))} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;E#15} in A#11[(app (\ X#7.S#10) S#9)]), E#8 |-> {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in A#11[(app (\ X#7.S#10) S#9)]) <-llet-e1- (letrec {X#13=T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#15} in A#11[(app (\ X#7.S#10) S#9)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in A#11[(letrec {X#7=S#9} in S#10)]) ================================================================================ Critical Pair: ( (letrec {X#1=S#4;E#12;E#2} in A#11[(app (\ X#7.S#10) S#9)]) , (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(letrec {X#7=S#9} in S#10)]) ) where Delta1 = {} Delta2 = {E#2,E#8} Delta3 = {(A#11[(app (\ X#7.S#10) S#9)],(letrec {E#2} in [.])), [{E#12},(letrec {E#2} in [.])], (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10))} Delta4= {} from overlapping <-SR,lbeta2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10))} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(app (\ X#7.S#10) S#9)], E#8 |-> {X#1=(letrec {E#2} in S#4);E#12}, E#3 |-> {E#12}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(app (\ X#7.S#10) S#9)]) <-llet-e1- (letrec {X#1=S#4;E#12;E#2} in A#11[(app (\ X#7.S#10) S#9)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(letrec {X#7=S#9} in S#10)]) ================================================================================ Critical Pair: ( (letrec E#9 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec E#9 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17)]), T#14 |-> A#15[(app A#16[(var X#7)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;E#17 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#17 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), E#9 |-> {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17}, E#16 |-> {E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#9 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {X#8=T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11)] ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#6,A#18} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#8.[.])), (T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (\ X#8.S#11) T#20)];E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#9}, A#17 |-> A#18, T#14 |-> A#18[(app (\ X#8.S#11) T#20)], T#19 |-> (app (\ X#8.S#11) T#20), S#10 |-> T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#18[(letrec {X#8=T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11)];E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#9 in A#12[(var X#7)] ) , (letrec X#7= A#18[(app A#19[(letrec {X#8=S#10} in S#11)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20)];E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]}, X#15 |-> X#7, E#16 |-> {E#9}, T#14 |-> A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#18[(app A#19[(letrec {X#8=S#10} in S#11)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (\ X#8.S#11) T#18[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ;E#9 in A#12[(var X#7)] ) , (letrec X#7= (letrec {X#8=T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11) ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#8.[.])), (T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (\ X#8.S#11) T#18);E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#9}, A#17 |-> [.], T#14 |-> (app (\ X#8.S#11) T#18), S#10 |-> T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#9} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=S#4;E#2;E#3} in S#5)]);E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=(letrec {X#8=T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11);E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#9 ;EE#19[X#18,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#9 ;EE#19[X#18,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22)];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#19[X#18,[.2]]}, X#15 |-> X#7, E#16 |-> {E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#18,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#9 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#9 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {X#8=T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11)] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#6,A#20} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#8.[.])), (T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (\ X#8.S#11) T#22)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (\ X#8.S#11) T#22)], T#21 |-> (app (\ X#8.S#11) T#22), S#10 |-> T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#20[(letrec {X#8=T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(app A#21[(letrec {X#8=S#10} in S#11)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, T#14 |-> A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#20[(app A#21[(letrec {X#8=S#10} in S#11)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (\ X#8.S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {X#8=T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11) ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(\ X#8.[.])), (T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (\ X#8.S#11) T#20);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (\ X#8.S#11) T#20), S#10 |-> T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=(letrec {X#8=T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} in S#11);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= S#4 ;E#14 ;E#2 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#1= (letrec {E#2} in S#4) ;E#14 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#2} Delta3 = {(A#12[(var X#7)],(letrec {E#2} in [.])), [{E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]},(letrec {E#2} in [.])], (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#9 |-> {X#1=(letrec {E#2} in S#4);E#14}, E#3 |-> {E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#1=S#4;E#14;E#2;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#1=(letrec {E#2} in S#4);E#14;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#10) ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#10) ;E#9 in A#13[(app A#14[(\ X#8.S#10)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(\ X#8.S#10)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;X#7= (\ X#8.S#10) ;E#15 in A#11[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= (\ X#8.S#10) ;E#15 in A#11[(\ X#8.S#10)] ) ) where Delta1 = {T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]), E#9 |-> {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15}, E#14 |-> {X#7=(\ X#8.S#10);E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) <-llet-e1- (letrec {X#13=T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#1=S#4;X#7=(\ X#8.S#10);E#12;E#2} in A#11[(var X#7)]) , (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#10);E#12} in A#11[(\ X#8.S#10)]) ) where Delta1 = {} Delta2 = {E#2} Delta3 = {(A#11[(var X#7)],(letrec {E#2} in [.])), [{X#7=(\ X#8.S#10);E#12},(letrec {E#2} in [.])], ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], E#9 |-> {X#1=(letrec {E#2} in S#4);E#12}, E#3 |-> {X#7=(\ X#8.S#10);E#12}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#10);E#12} in A#11[(var X#7)]) <-llet-e1- (letrec {X#1=S#4;X#7=(\ X#8.S#10);E#12;E#2} in A#11[(var X#7)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#10);E#12} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#10);E#12} in A#11[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(\ X#8.S#11)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17)]), T#14 |-> A#15[(app A#16[(var X#9)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(\ X#8.S#11)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#17 ;VV#13|X#9,(var X#7)| in A#12[(var X#9)] ) , (letrec X#15= T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#17 ;VV#13|X#9,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {T#6} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]), E#10 |-> {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17}, E#16 |-> {X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) <-llet-e1- (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#1= S#4 ;X#7= (\ X#8.S#11) ;E#14 ;E#2 ;VV#13|X#9,(var X#7)| in A#12[(var X#9)] ) , (letrec X#1= (letrec {E#2} in S#4) ;X#7= (\ X#8.S#11) ;E#14 ;VV#13|X#9,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {E#2} Delta3 = {(A#12[(var X#9)],(letrec {E#2} in [.])), [{X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#1=(letrec {E#2} in S#4);E#14}, E#3 |-> {X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) <-llet-e1- (letrec {X#1=S#4;X#7=(\ X#8.S#11);E#14;E#2;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(var X#7)]] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18)]), T#15 |-> A#16[(app A#17[(var X#9)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#18 ;EE#14[X#9,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#16= T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#18 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]), E#10 |-> {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#18}, E#17 |-> {X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#16=T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])]] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#12,A#19} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#21[(app A#22[[.]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23)]];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#7)] T#23)]], T#20 |-> A#21[(app A#22[(var X#7)] T#23)], A#12 |-> A#21[(app A#22 T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];E#10} in A#13[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])]];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[A#12[(\ X#8.S#11)]] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21)];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, T#15 |-> A#19[(app A#20[A#12[(var X#7)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#13[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(\ X#8.S#11)]] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[(\ X#8.S#11)] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#19[(app A#20[[.]] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21)];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#7)] T#21)], A#12 |-> A#19[(app A#20 T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#13[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(\ X#8.S#11)] T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#10 ;EE#20[X#19,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#10 ;EE#20[X#19,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23)];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#19,A#12[(var X#7)]]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#20[X#19,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#8.S#11)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#12,A#21} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#23[(app A#24[[.]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25)]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#7)] T#25)]], T#22 |-> A#23[(app A#24[(var X#7)] T#25)], A#12 |-> A#23[(app A#24 T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#8.S#11)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[A#12[(\ X#8.S#11)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23)];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, T#15 |-> A#21[(app A#22[A#12[(var X#7)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[A#12[(\ X#8.S#11)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6,A#12} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),A#21[(app A#22[[.]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(var X#7)] T#23)];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#7)] T#23)], A#12 |-> A#21[(app A#22 T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= S#4 ;X#7= (\ X#8.S#11) ;E#15 ;E#2 ;EE#14[X#9,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#1= (letrec {E#2} in S#4) ;X#7= (\ X#8.S#11) ;E#15 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {E#2} Delta3 = {(A#13[(var X#9)],(letrec {E#2} in [.])), [{X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]},(letrec {E#2} in [.])], ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#1=(letrec {E#2} in S#4);E#15}, E#3 |-> {X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) <-llet-e1- (letrec {X#1=S#4;X#7=(\ X#8.S#11);E#15;E#2;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#14,T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20)]), T#17 |-> A#18[(app A#19[(var X#9)] T#20)], A#14 |-> A#18[(app A#19 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#18= T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;X#7= (\ X#8.S#12) ;E#20 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= (\ X#8.S#12) ;E#20 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=T#17;X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), E#11 |-> {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#20}, E#19 |-> {X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#18=T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#22,A#20,T#17,T#6,A#13,A#21} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#23[(app A#24[[.]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25)]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#21[[.2]]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#20 |-> A#21, T#17 |-> A#21[A#23[(app A#24[(var X#10)] T#25)]], T#22 |-> A#23[(app A#24[(var X#10)] T#25)], A#13 |-> A#23[(app A#24 T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[A#13[(\ X#8.S#12)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23)];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, T#17 |-> A#21[(app A#22[A#13[(var X#10)]] T#23)], A#20 |-> A#21[(app A#22 T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(\ X#8.S#12)]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[(\ X#8.S#12)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#21[(app A#22[[.]] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23)];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#20 |-> [.], T#17 |-> A#21[(app A#22[(var X#10)] T#23)], A#13 |-> A#21[(app A#22 T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(\ X#8.S#12)] T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#11 ;EE#22[X#21,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#11 ;EE#22[X#21,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25)];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#22[X#21,[.2]]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, T#17 |-> A#23[(app A#24[(var X#21)] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#11;EE#22[X#21,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#23[X#9,(var X#21)] ;EE#24[X#22,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#23[X#9,(var X#21)] ;EE#24[X#22,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27)];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, T#17 |-> A#25[(app A#26[(var X#22)] T#27)], A#20 |-> A#25[(app A#26 T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=S#4;E#2;E#3} in S#5)])]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[A#25[(app A#26[(\ X#8.S#12)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#24,A#20,T#17,T#6,A#13,A#23} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#25[(app A#26[[.]] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27)]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, A#20 |-> A#23, T#17 |-> A#23[A#25[(app A#26[(var X#10)] T#27)]], T#24 |-> A#25[(app A#26[(var X#10)] T#27)], A#13 |-> A#25[(app A#26 T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=S#4;E#2;E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[A#25[(app A#26[(\ X#8.S#12)] T#27[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[(app A#24[A#13[(\ X#8.S#12)]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25)];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, T#17 |-> A#23[(app A#24[A#13[(var X#10)]] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[(app A#24[A#13[(\ X#8.S#12)]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#17,T#6,A#13} Delta2 = {E#2} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#23[(app A#24[[.]] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#23[(app A#24[(var X#10)] T#25)];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, A#20 |-> [.], T#17 |-> A#23[(app A#24[(var X#10)] T#25)], A#13 |-> A#23[(app A#24 T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= S#4 ;X#7= (\ X#8.S#12) ;E#17 ;E#2 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#1= (letrec {E#2} in S#4) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {E#2} Delta3 = {(A#14[(var X#9)],(letrec {E#2} in [.])), [{X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|},(letrec {E#2} in [.])], ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {E#2} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#1=(letrec {E#2} in S#4);E#17}, E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-llet-e1- (letrec {X#1=S#4;X#7=(\ X#8.S#12);E#17;E#2;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#1=(letrec {E#2} in S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)])) , (letrec {E#7;E#8} in T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) ) where Delta1 = {T#10,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], [{E#7},(letrec {E#8} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],[{E#7},(letrec {E#8} in [.])]} and found solution: Sol = {T#6 |-> (letrec {E#7} in (letrec {E#8} in T#11)), T#10 |-> (letrec {E#8} in T#11), S#9 |-> T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) <-llet-e1- (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)])) ................................................................................ (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) -SR,llet-in1-> (letrec {E#7;E#8} in T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) ================================================================================ Critical Pair: ( (letrec E#7 in (letrec {X#12=T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#14} in S#9) ) , (letrec X#12= T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#14 ;E#7 in S#9 ) ) where Delta1 = {T#10,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], [{E#7},(letrec {X#12=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#14} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],[{E#7},(letrec {E#8} in [.])]} and found solution: Sol = {T#6 |-> (letrec {E#7} in (letrec {X#12=T#11;E#14} in S#9)), T#10 |-> (letrec {X#12=T#11;E#14} in S#9), E#8 |-> {X#12=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#14} in S#9)) <-llet-e1- (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#14} in S#9)) ................................................................................ (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#14} in S#9)) -SR,llet-in1-> (letrec {X#12=T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#14;E#7} in S#9) ================================================================================ Critical Pair: ( (letrec {E#7} in (letrec {X#1=S#4;E#11;E#2} in S#9)) , (letrec {X#1=(letrec {E#2} in S#4);E#11;E#7} in S#9) ) where Delta1 = {T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#11},(letrec {E#2} in [.])], [{E#7},(letrec {X#1=(letrec {E#2} in S#4);E#11} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],[{E#7},(letrec {E#8} in [.])]} and found solution: Sol = {T#6 |-> (letrec {E#7} in [.]), T#10 |-> [.], S#5 |-> S#9, E#8 |-> {X#1=(letrec {E#2} in S#4);E#11}, E#3 |-> {E#11}} and instantiated rules: (letrec {E#7} in (letrec {X#1=(letrec {E#2} in S#4);E#11} in S#9)) <-llet-e1- (letrec {E#7} in (letrec {X#1=S#4;E#11;E#2} in S#9)) ................................................................................ (letrec {E#7} in (letrec {X#1=(letrec {E#2} in S#4);E#11} in S#9)) -SR,llet-in1-> (letrec {X#1=(letrec {E#2} in S#4);E#11;E#7} in S#9) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;E#13 in (letrec {E#8} in S#9) ) , (letrec X#11= T#10[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#13 ;E#8 in S#9 ) ) where Delta1 = {T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], [{X#11=T#10[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#13},(letrec {E#8} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],[{E#7},(letrec {E#8} in [.])]} and found solution: Sol = {T#6 |-> (letrec {X#11=T#10;E#13} in (letrec {E#8} in S#9)), E#7 |-> {X#11=T#10[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#13} in (letrec {E#8} in S#9)) <-llet-e1- (letrec {X#11=T#10[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#13} in (letrec {E#8} in S#9)) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#13} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {X#11=T#10[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#13;E#8} in S#9) ================================================================================ Critical Pair: ( (letrec {X#1=S#4;E#10;E#2} in (letrec {E#8} in S#9)) , (letrec {X#1=(letrec {E#2} in S#4);E#10;E#8} in S#9) ) where Delta1 = {} Delta2 = {E#2,E#7,E#8} Delta3 = {((letrec {E#8} in S#9),(letrec {E#2} in [.])), [{E#10},(letrec {E#2} in [.])], [{X#1=(letrec {E#2} in S#4);E#10},(letrec {E#8} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],[{E#7},(letrec {E#8} in [.])]} and found solution: Sol = {T#6 |-> [.], S#5 |-> (letrec {E#8} in S#9), E#7 |-> {X#1=(letrec {E#2} in S#4);E#10}, E#3 |-> {E#10}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);E#10} in (letrec {E#8} in S#9)) <-llet-e1- (letrec {X#1=S#4;E#10;E#2} in (letrec {E#8} in S#9)) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);E#10} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {X#1=(letrec {E#2} in S#4);E#10;E#8} in S#9) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#8} in S#10) ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec X#7= S#10 ;E#8 ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#8} in T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ;E#9 in A#11[(var X#7)] ) , (letrec X#7= T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#8 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {T#12,T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#8} in T#15);E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> (letrec {E#8} in T#15), S#10 |-> T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#9} in A#11[(var X#7)]) <-llet-e1- (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)]);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#8;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#16=T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#18} in S#10) ;E#9 in A#11[(var X#7)] ) , (letrec X#16= T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= S#10 ;E#18 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {T#12,T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (A#11[(var X#7)],(letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#18} in [.])), [{E#9},(letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#18} in [.])], ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {X#16=T#15;E#18} in S#10);E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> (letrec {X#16=T#15;E#18} in S#10), E#8 |-> {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#18} in S#10);E#9} in A#11[(var X#7)]) <-llet-e1- (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#18} in S#10);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#18} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#16=T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=S#10;E#18;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#7=(letrec {X#1=S#4;E#15;E#2} in S#10);E#9} in A#11[(var X#7)]) , (letrec {X#1=(letrec {E#2} in S#4);X#7=S#10;E#15;E#9} in A#11[(var X#7)]) ) where Delta1 = {T#6} Delta2 = {E#2,E#8} Delta3 = {(S#10,(letrec {E#2} in [.])), [{E#15},(letrec {E#2} in [.])], (A#11[(var X#7)],(letrec {X#1=(letrec {E#2} in S#4);E#15} in [.])), [{E#9},(letrec {X#1=(letrec {E#2} in S#4);E#15} in [.])], ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=[.];E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=(letrec {E#2} in S#4);E#15}, E#3 |-> {E#15}} and instantiated rules: (letrec {X#7=(letrec {X#1=(letrec {E#2} in S#4);E#15} in S#10);E#9} in A#11[(var X#7)]) <-llet-e1- (letrec {X#7=(letrec {X#1=S#4;E#15;E#2} in S#10);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {X#1=(letrec {E#2} in S#4);E#15} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#1=(letrec {E#2} in S#4);X#7=S#10;E#15;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;X#7= (letrec {E#8} in S#10) ;E#15 in A#11[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= S#10 ;E#15 ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#6} Delta2 = {E#2,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15},(letrec {E#8} in [.])], ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]), E#9 |-> {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15}, E#14 |-> {X#7=(letrec {E#8} in S#10);E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) <-llet-e1- (letrec {X#13=T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=S#10;E#15;E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) , (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) ) where Delta1 = {} Delta2 = {E#2,E#8} Delta3 = {(A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], (A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], X#1 |-> X#7, S#4 |-> S#10, E#2 |-> {E#8}, E#3 |-> {E#9}} and instantiated rules: (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) <-llet-e1- (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#1=S#4;X#7=(letrec {E#8} in S#10);E#12;E#2} in A#11[(var X#7)]) , (letrec {X#1=(letrec {E#2} in S#4);X#7=S#10;E#12;E#8} in A#11[(var X#7)]) ) where Delta1 = {} Delta2 = {E#2,E#8} Delta3 = {(A#11[(var X#7)],(letrec {E#2} in [.])), [{X#7=(letrec {E#8} in S#10);E#12},(letrec {E#2} in [.])], (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#1=(letrec {E#2} in S#4);E#12},(letrec {E#8} in [.])], ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], E#9 |-> {X#1=(letrec {E#2} in S#4);E#12}, E#3 |-> {X#7=(letrec {E#8} in S#10);E#12}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);X#7=(letrec {E#8} in S#10);E#12} in A#11[(var X#7)]) <-llet-e1- (letrec {X#1=S#4;X#7=(letrec {E#8} in S#10);E#12;E#2} in A#11[(var X#7)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);X#7=(letrec {E#8} in S#10);E#12} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#1=(letrec {E#2} in S#4);X#7=S#10;E#12;E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec X#7= S#11 ;E#10 ;E#9 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17)]), T#14 |-> A#15[(app A#16[(var X#8)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#7= T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#10 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in T#17);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> (letrec {E#9} in T#17), S#11 |-> T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#18=T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#20} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#18= T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= S#11 ;E#10 ;E#20 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#10;E#20;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#20} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#20} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {X#18=T#17;E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> (letrec {X#18=T#17;E#20} in S#11), E#9 |-> {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=S#11;E#10;E#20;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#1=S#4;E#17;E#2} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#1= (letrec {E#2} in S#4) ;X#7= S#11 ;E#10 ;E#17 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#2,E#9} Delta3 = {(S#11,(letrec {E#2} in [.])), [{E#17},(letrec {E#2} in [.])], ((var X#7),(letrec {X#1=(letrec {E#2} in S#4);E#10;E#17;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {X#1=(letrec {E#2} in S#4);E#17} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {X#1=(letrec {E#2} in S#4);E#17} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=[.];E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=(letrec {E#2} in S#4);E#17}, E#3 |-> {E#17}} and instantiated rules: (letrec {X#7=(letrec {X#1=(letrec {E#2} in S#4);E#17} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#7=(letrec {X#1=S#4;E#17;E#2} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {X#1=(letrec {E#2} in S#4);E#17} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#1=(letrec {E#2} in S#4);X#7=S#11;E#10;E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;X#7= (letrec {E#9} in S#11) ;E#17 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#15= T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;X#7= S#11 ;E#17 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), E#10 |-> {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17}, E#16 |-> {X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];X#7=S#11;E#17;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;X#8= A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#10 in A#12[(var X#8)] ) , (letrec X#7= S#11 ;X#8= A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#10 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;E#9} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20)];E#10} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]}, X#15 |-> X#8, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10}, T#14 |-> A#18[(app A#19[(var X#7)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#12[(var X#8)]) <-llet-e1- (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#10 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) , (letrec X#7= S#11 ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#10 ;E#9 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;E#9;EE#19[X#18,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22)];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#19[X#18,[.2]]}, X#15 |-> X#8, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#18,(var X#7)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;E#9;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,(var X#7)] in A#12[(var X#8)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= S#11 ;E#10 ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;E#9;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=S#11;E#10;E#9;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;X#7= S#11 ;E#10 ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], ((var X#7),(letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;E#9;EE#19[X#8,(var X#18)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#10;EE#19[X#8,(var X#18)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22)];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]}, T#14 |-> A#20[(app A#21[(var X#7)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];X#7=S#11;E#10;E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) , (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ) where Delta1 = {} Delta2 = {E#2,E#9} Delta3 = {(A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], X#1 |-> X#7, S#4 |-> S#11, E#2 |-> {E#9}, E#3 |-> {E#10;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= S#4 ;X#7= (letrec {E#9} in S#11) ;E#14 ;E#2 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#1= (letrec {E#2} in S#4) ;X#7= S#11 ;E#14 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#2,E#9} Delta3 = {(A#12[(var X#8)],(letrec {E#2} in [.])), [{X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]},(letrec {E#2} in [.])], ((var X#7),(letrec {X#1=(letrec {E#2} in S#4);E#14;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#1=(letrec {E#2} in S#4);E#14;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#1=(letrec {E#2} in S#4);E#14}, E#3 |-> {X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-llet-e1- (letrec {X#1=S#4;X#7=(letrec {E#9} in S#11);E#14;E#2;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#1=(letrec {E#2} in S#4);X#7=S#11;E#14;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( A#11[(app (letrec {E#7} in T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#8)] , A#11[(letrec E#7 in (app T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#8) )] ) where Delta1 = {T#13,T#12,A#10,T#6,A#11} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (letrec {E#7} in T#14) S#8)], T#12 |-> (app (letrec {E#7} in T#14) S#8), T#13 |-> (letrec {E#7} in T#14), S#9 |-> T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#8)] <-llet-e1- A#11[(app (letrec {E#7} in T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#8)] ................................................................................ A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#8)] -SR,lapp1-> A#11[(letrec {E#7} in (app T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#17} in S#9) S#8)] , A#11[(letrec X#15= T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#17 in (app S#9 S#8) )] ) where Delta1 = {T#13,T#12,A#10,T#6,A#11} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#8,(letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#9) S#8)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#9) S#8), T#13 |-> (letrec {X#15=T#14;E#17} in S#9), E#7 |-> {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17}, E#16 |-> {E#17}} and instantiated rules: A#11[(app (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in S#9) S#8)] <-llet-e1- A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#17} in S#9) S#8)] ................................................................................ A#11[(app (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in S#9) S#8)] -SR,lapp1-> A#11[(letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in (app S#9 S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {X#1=S#4;E#14;E#2} in S#9) S#8)] , A#11[(letrec {X#1=(letrec {E#2} in S#4);E#14} in (app S#9 S#8))] ) where Delta1 = {T#12,A#10,T#6,A#11} Delta2 = {E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#14},(letrec {E#2} in [.])], (S#8,(letrec {X#1=(letrec {E#2} in S#4);E#14} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app [.] S#8)], T#12 |-> (app [.] S#8), T#13 |-> [.], S#5 |-> S#9, E#7 |-> {X#1=(letrec {E#2} in S#4);E#14}, E#3 |-> {E#14}} and instantiated rules: A#11[(app (letrec {X#1=(letrec {E#2} in S#4);E#14} in S#9) S#8)] <-llet-e1- A#11[(app (letrec {X#1=S#4;E#14;E#2} in S#9) S#8)] ................................................................................ A#11[(app (letrec {X#1=(letrec {E#2} in S#4);E#14} in S#9) S#8)] -SR,lapp1-> A#11[(letrec {X#1=(letrec {E#2} in S#4);E#14} in (app S#9 S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] , A#11[(letrec E#7 in (app S#9 T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) )] ) where Delta1 = {T#12,A#10,T#6,A#11} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#7} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (letrec {E#7} in S#9) T#13)], T#12 |-> (app (letrec {E#7} in S#9) T#13), S#8 |-> T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] <-llet-e1- A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ................................................................................ A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] -SR,lapp1-> A#11[(letrec {E#7} in (app S#9 T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]))] ================================================================================ Critical Pair: ( A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] , A#11[(app A#12[(letrec {E#7} in (app S#9 S#8))] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) where Delta1 = {A#10,T#6} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {T#6 |-> A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13)], A#10 |-> A#11[(app A#12 T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] <-llet-e1- A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ................................................................................ A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] -SR,lapp1-> A#11[(app A#12[(letrec {E#7} in (app S#9 S#8))] T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ================================================================================ Critical Pair: ( (app (letrec {E#7} in T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#8) , (letrec E#7 in (app T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#8) ) ) where Delta1 = {T#11,T#6} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (letrec {E#7} in T#12) S#8), T#11 |-> (letrec {E#7} in T#12), S#9 |-> T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (app (letrec {E#7} in T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#8) <-llet-e1- (app (letrec {E#7} in T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#8) ................................................................................ (app (letrec {E#7} in T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#8) -SR,lapp1-> (letrec {E#7} in (app T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#8)) ================================================================================ Critical Pair: ( (app (letrec {X#13=T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#15} in S#9) S#8) , (letrec X#13= T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#15 in (app S#9 S#8) ) ) where Delta1 = {T#11,T#6} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#8,(letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (letrec {X#13=T#12;E#15} in S#9) S#8), T#11 |-> (letrec {X#13=T#12;E#15} in S#9), E#7 |-> {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (app (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in S#9) S#8) <-llet-e1- (app (letrec {X#13=T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#15} in S#9) S#8) ................................................................................ (app (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in S#9) S#8) -SR,lapp1-> (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in (app S#9 S#8)) ================================================================================ Critical Pair: ( (app (letrec {X#1=S#4;E#12;E#2} in S#9) S#8) , (letrec {X#1=(letrec {E#2} in S#4);E#12} in (app S#9 S#8)) ) where Delta1 = {T#6} Delta2 = {E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#12},(letrec {E#2} in [.])], (S#8,(letrec {X#1=(letrec {E#2} in S#4);E#12} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app [.] S#8), T#11 |-> [.], S#5 |-> S#9, E#7 |-> {X#1=(letrec {E#2} in S#4);E#12}, E#3 |-> {E#12}} and instantiated rules: (app (letrec {X#1=(letrec {E#2} in S#4);E#12} in S#9) S#8) <-llet-e1- (app (letrec {X#1=S#4;E#12;E#2} in S#9) S#8) ................................................................................ (app (letrec {X#1=(letrec {E#2} in S#4);E#12} in S#9) S#8) -SR,lapp1-> (letrec {X#1=(letrec {E#2} in S#4);E#12} in (app S#9 S#8)) ================================================================================ Critical Pair: ( (app (letrec {E#7} in S#9) T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)]) , (letrec E#7 in (app S#9 T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) ) ) where Delta1 = {T#6} Delta2 = {E#2,E#7} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#7} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#2,E#7} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.]))} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (letrec {E#7} in S#9) T#11), S#8 |-> T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) <-llet-e1- (app (letrec {E#7} in S#9) T#11[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ................................................................................ (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) -SR,lapp1-> (letrec {E#7} in (app S#9 T#11[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#9)] ) , (letrec E#7 in A#13[(letrec E#8 in (app T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#9) )] ) ) where Delta1 = {T#15,T#14,A#11,T#12,T#6,A#13} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app (letrec {E#8} in T#16) S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {E#8} in T#16) S#9)], T#14 |-> (app (letrec {E#8} in T#16) S#9), T#15 |-> (letrec {E#8} in T#16), S#10 |-> T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#9)]) <-llet-e1- (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {E#8} in (app T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {X#17=T#16[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#19} in S#10) S#9)] ) , (letrec E#7 in A#13[(letrec X#17= T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#19 in (app S#10 S#9) )] ) ) where Delta1 = {T#15,T#14,A#11,T#12,T#6,A#13} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(letrec {X#17=T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#19} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app (letrec {X#17=T#16;E#19} in S#10) S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {X#17=T#16;E#19} in S#10) S#9)], T#14 |-> (app (letrec {X#17=T#16;E#19} in S#10) S#9), T#15 |-> (letrec {X#17=T#16;E#19} in S#10), E#8 |-> {X#17=T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#19} in S#10) S#9)]) <-llet-e1- (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#19} in S#10) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#19} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {X#17=T#16[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#19} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec {E#7} in A#13[(app (letrec {X#1=S#4;E#16;E#2} in S#10) S#9)]) , (letrec E#7 in A#13[(letrec {X#1=(letrec {E#2} in S#4);E#16} in (app S#10 S#9))] ) ) where Delta1 = {T#14,A#11,T#12,T#6,A#13} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#10,(letrec {E#2} in [.])), [{E#16},(letrec {E#2} in [.])], (S#9,(letrec {X#1=(letrec {E#2} in S#4);E#16} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app [.] S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app [.] S#9)], T#14 |-> (app [.] S#9), T#15 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=(letrec {E#2} in S#4);E#16}, E#3 |-> {E#16}} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {X#1=(letrec {E#2} in S#4);E#16} in S#10) S#9)]) <-llet-e1- (letrec {E#7} in A#13[(app (letrec {X#1=S#4;E#16;E#2} in S#10) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {X#1=(letrec {E#2} in S#4);E#16} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {X#1=(letrec {E#2} in S#4);E#16} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec E#7 in A#13[(letrec E#8 in (app S#10 T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) )] ) ) where Delta1 = {T#14,A#11,T#12,T#6,A#13} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {E#8} in S#10) T#15)], T#14 |-> (app (letrec {E#8} in S#10) T#15), S#9 |-> T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {E#8} in (app S#10 T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec E#7 in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15)]), T#12 |-> A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,lapp2-> (letrec {E#7} in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] T#15[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {E#8} in T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#9) ) , (letrec E#7 in (letrec E#8 in (app T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#9) ) ) ) where Delta1 = {T#13,T#12,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app (letrec {E#8} in T#14) S#9)), A#11 |-> [.], T#12 |-> (app (letrec {E#8} in T#14) S#9), T#13 |-> (letrec {E#8} in T#14), S#10 |-> T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#9)) <-llet-e1- (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {E#8} in (app T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#9))) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#17} in S#10) S#9) ) , (letrec E#7 in (letrec X#15= T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#17 in (app S#10 S#9) ) ) ) where Delta1 = {T#13,T#12,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app (letrec {X#15=T#14;E#17} in S#10) S#9)), A#11 |-> [.], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#10) S#9), T#13 |-> (letrec {X#15=T#14;E#17} in S#10), E#8 |-> {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in S#10) S#9)) <-llet-e1- (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#17} in S#10) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in S#10) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17} in (app S#10 S#9))) ================================================================================ Critical Pair: ( (letrec {E#7} in (app (letrec {X#1=S#4;E#14;E#2} in S#10) S#9)) , (letrec {E#7} in (letrec {X#1=(letrec {E#2} in S#4);E#14} in (app S#10 S#9))) ) where Delta1 = {T#12,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#10,(letrec {E#2} in [.])), [{E#14},(letrec {E#2} in [.])], (S#9,(letrec {X#1=(letrec {E#2} in S#4);E#14} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app [.] S#9)), A#11 |-> [.], T#12 |-> (app [.] S#9), T#13 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=(letrec {E#2} in S#4);E#14}, E#3 |-> {E#14}} and instantiated rules: (letrec {E#7} in (app (letrec {X#1=(letrec {E#2} in S#4);E#14} in S#10) S#9)) <-llet-e1- (letrec {E#7} in (app (letrec {X#1=S#4;E#14;E#2} in S#10) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {X#1=(letrec {E#2} in S#4);E#14} in S#10) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {X#1=(letrec {E#2} in S#4);E#14} in (app S#10 S#9))) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ) , (letrec E#7 in (letrec E#8 in (app S#10 T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) ) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app (letrec {E#8} in S#10) T#13)), A#11 |-> [.], T#12 |-> (app (letrec {E#8} in S#10) T#13), S#9 |-> T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) <-llet-e1- (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=S#4;E#2;E#3} in S#5)])) ................................................................................ (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])) -SR,lapp2-> (letrec {E#7} in (letrec {E#8} in (app S#10 T#13[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]))) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;E#15 in A#11[(app (letrec {E#8} in S#10) S#9)] ) , (letrec X#13= T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#15 in A#11[(letrec {E#8} in (app S#10 S#9))] ) ) where Delta1 = {T#6} Delta2 = {E#2,E#7,E#8} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#9,(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]), E#7 |-> {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) <-llet-e1- (letrec {X#13=T#12[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {X#13=T#12[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#15} in A#11[(letrec {E#8} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec {X#1=S#4;E#12;E#2} in A#11[(app (letrec {E#8} in S#10) S#9)]) , (letrec X#1= (letrec {E#2} in S#4) ;E#12 in A#11[(letrec {E#8} in (app S#10 S#9))] ) ) where Delta1 = {} Delta2 = {E#2,E#7,E#8} Delta3 = {(A#11[(app (letrec {E#8} in S#10) S#9)],(letrec {E#2} in [.])), [{E#12},(letrec {E#2} in [.])], (S#9,(letrec {E#8} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#2,E#7,E#8} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#9,(letrec {E#8} in [.]))} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(app (letrec {E#8} in S#10) S#9)], E#7 |-> {X#1=(letrec {E#2} in S#4);E#12}, E#3 |-> {E#12}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(app (letrec {E#8} in S#10) S#9)]) <-llet-e1- (letrec {X#1=S#4;E#12;E#2} in A#11[(app (letrec {E#8} in S#10) S#9)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {X#1=(letrec {E#2} in S#4);E#12} in A#11[(letrec {E#8} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec E#8 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ) , (letrec E#8 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17)]), T#14 |-> A#15[(app A#16[(var X#7)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) <-llet-e1- (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;E#2;E#3} in S#5)])]) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)] ;E#17 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#17 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), E#8 |-> {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17}, E#16 |-> {E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#15=T#14[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=T#14[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#17;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {E#9} in T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec E#9 in (app T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#19,A#17,T#14,T#6,A#18} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (letrec {E#9} in T#21) S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {E#9} in T#21) S#10)], T#19 |-> (app (letrec {E#9} in T#21) S#10), T#20 |-> (letrec {E#9} in T#21), S#11 |-> T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10)];E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {E#9} in (app T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#24} in S#11) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec X#22= T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#24 in (app S#11 S#10) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#19,A#17,T#14,T#6,A#18} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (letrec {X#22=T#21;E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#11) S#10)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#11) S#10), T#20 |-> (letrec {X#22=T#21;E#24} in S#11), E#9 |-> {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in (app S#11 S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {X#1=S#4;E#2;E#21} in S#11) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {X#1=(letrec {E#2} in S#4);E#21} in (app S#11 S#10))] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#6,A#18} Delta2 = {E#2,E#9} Delta3 = {(S#11,(letrec {E#2} in [.])), [{E#21},(letrec {E#2} in [.])], (S#10,(letrec {X#1=(letrec {E#2} in S#4);E#21} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app [.] S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app [.] S#10)], T#19 |-> (app [.] S#10), T#20 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=(letrec {E#2} in S#4);E#21}, E#3 |-> {E#21}} and instantiated rules: (letrec {X#7=A#18[(app (letrec {X#1=(letrec {E#2} in S#4);E#21} in S#11) S#10)];E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app (letrec {X#1=S#4;E#2;E#21} in S#11) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {X#1=(letrec {E#2} in S#4);E#21} in S#11) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {X#1=(letrec {E#2} in S#4);E#21} in (app S#11 S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec E#9 in (app S#11 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#6,A#18} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {E#9} in S#11) T#20)], T#19 |-> (app (letrec {E#9} in S#11) T#20), S#10 |-> T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {E#9} in (app S#11 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(app A#19[(letrec {E#9} in (app S#11 S#10))] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]}, X#15 |-> X#7, E#16 |-> {E#8}, T#14 |-> A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(app A#19[(letrec {E#9} in (app S#11 S#10))] T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {E#9} in T#19[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec E#9 in (app T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#18,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (letrec {E#9} in T#19) S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in T#19) S#10), T#18 |-> (letrec {E#9} in T#19), S#11 |-> T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10);E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {E#9} in (app T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {X#20=T#19[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#22} in S#11) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec X#20= T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#22 in (app S#11 S#10) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#18,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {X#20=T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#22} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (letrec {X#20=T#19;E#22} in S#11) S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {X#20=T#19;E#22} in S#11) S#10), T#18 |-> (letrec {X#20=T#19;E#22} in S#11), E#9 |-> {X#20=T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {X#20=T#19[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#22} in (app S#11 S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {X#1=S#4;E#19;E#2} in S#11) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec {X#1=(letrec {E#2} in S#4);E#19} in (app S#11 S#10)) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#11,(letrec {E#2} in [.])), [{E#19},(letrec {E#2} in [.])], (S#10,(letrec {X#1=(letrec {E#2} in S#4);E#19} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app [.] S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app [.] S#10), T#18 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=(letrec {E#2} in S#4);E#19}, E#3 |-> {E#19}} and instantiated rules: (letrec {X#7=(app (letrec {X#1=(letrec {E#2} in S#4);E#19} in S#11) S#10);E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=(app (letrec {X#1=S#4;E#19;E#2} in S#11) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {X#1=(letrec {E#2} in S#4);E#19} in S#11) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {X#1=(letrec {E#2} in S#4);E#19} in (app S#11 S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {E#9} in S#11) T#18[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec E#9 in (app S#11 T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (letrec {E#9} in S#11) T#18);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in S#11) T#18), S#10 |-> T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#8} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=S#4;E#2;E#3} in S#5)]);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {E#9} in (app S#11 T#18[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#8 ;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#8 ;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22)];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#19[X#18,[.2]]}, X#15 |-> X#7, E#16 |-> {E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#8 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#8 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#9} in T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec E#9 in (app T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#22,T#21,A#17,T#14,T#6,A#20} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (letrec {E#9} in T#23) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {E#9} in T#23) S#10)], T#21 |-> (app (letrec {E#9} in T#23) S#10), T#22 |-> (letrec {E#9} in T#23), S#11 |-> T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#9} in (app T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {X#24=T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#26} in S#11) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec X#24= T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#26 in (app S#11 S#10) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#22,T#21,A#17,T#14,T#6,A#20} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {X#24=T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#26} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (letrec {X#24=T#23;E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {X#24=T#23;E#26} in S#11) S#10)], T#21 |-> (app (letrec {X#24=T#23;E#26} in S#11) S#10), T#22 |-> (letrec {X#24=T#23;E#26} in S#11), E#9 |-> {X#24=T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#26}, E#25 |-> {E#26}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#24=T#23[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#26} in (app S#11 S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {X#1=S#4;E#2;E#23} in S#11) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {X#1=(letrec {E#2} in S#4);E#23} in (app S#11 S#10))] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#6,A#20} Delta2 = {E#2,E#9} Delta3 = {(S#11,(letrec {E#2} in [.])), [{E#23},(letrec {E#2} in [.])], (S#10,(letrec {X#1=(letrec {E#2} in S#4);E#23} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app [.] S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app [.] S#10)], T#21 |-> (app [.] S#10), T#22 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=(letrec {E#2} in S#4);E#23}, E#3 |-> {E#23}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#1=(letrec {E#2} in S#4);E#23} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app (letrec {X#1=S#4;E#2;E#23} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#1=(letrec {E#2} in S#4);E#23} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#1=(letrec {E#2} in S#4);E#23} in (app S#11 S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec E#9 in (app S#11 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#6,A#20} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {E#9} in S#11) T#22)], T#21 |-> (app (letrec {E#9} in S#11) T#22), S#10 |-> T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#9} in (app S#11 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(app A#21[(letrec {E#9} in (app S#11 S#10))] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, T#14 |-> A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=S#4;E#2;E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(app A#21[(letrec {E#9} in (app S#11 S#10))] T#22[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#9} in T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec E#9 in (app T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (letrec {E#9} in T#21) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in T#21) S#10), T#20 |-> (letrec {E#9} in T#21), S#11 |-> T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {E#9} in (app T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {X#22=T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#24} in S#11) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec X#22= T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] ;E#24 in (app S#11 S#10) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (S#10,(letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (letrec {X#22=T#21;E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {X#22=T#21;E#24} in S#11) S#10), T#20 |-> (letrec {X#22=T#21;E#24} in S#11), E#9 |-> {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=S#4;E#2;E#3} in S#5)];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {X#22=T#21[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)];E#24} in (app S#11 S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {X#1=S#4;E#2;E#21} in S#11) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {X#1=(letrec {E#2} in S#4);E#21} in (app S#11 S#10)) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#11,(letrec {E#2} in [.])), [{E#21},(letrec {E#2} in [.])], (S#10,(letrec {X#1=(letrec {E#2} in S#4);E#21} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app [.] S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app [.] S#10), T#20 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=(letrec {E#2} in S#4);E#21}, E#3 |-> {E#21}} and instantiated rules: (letrec {X#18=(app (letrec {X#1=(letrec {E#2} in S#4);E#21} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=(app (letrec {X#1=S#4;E#2;E#21} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {X#1=(letrec {E#2} in S#4);E#21} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {X#1=(letrec {E#2} in S#4);E#21} in (app S#11 S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)]) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec E#9 in (app S#11 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#2,E#9} Delta3 = {(S#5,(letrec {E#2} in [.])), [{E#3},(letrec {E#2} in [.])], (T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (letrec {E#9} in S#11) T#20);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in S#11) T#20), S#10 |-> T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]} and instantiated rules: (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;E#2;E#3} in S#5)]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {E#9} in (app S#11 T#20[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)]));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= S#4 ;E#14 ;E#2 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#1= (letrec {E#2} in S#4) ;E#14 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#2,E#9} Delta3 = {(A#12[(var X#7)],(letrec {E#2} in [.])), [{E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]},(letrec {E#2} in [.])], (S#10,(letrec {E#9} in [.])), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -llet-e1-> with input rules: T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] <-llet-e1- T#6[(letrec {X#1=S#4;E#2;E#3} in S#5)] and constraints: E#2/= {}, (S#5,(letrec {E#2} in [.])), ({E#3},(letrec {E#2} in [.])) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=(letrec {E#2} in S#4);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#2,E#9} Delta3= {(S#5,(letrec {E#2} in [.])),[{E#3},(letrec {E#2} in [.])],(S#10,(letrec {E#9} in [.])),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#8 |-> {X#1=(letrec {E#2} in S#4);E#14}, E#3 |-> {E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#1=(letrec {E#2} in S#4);E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-llet-e1- (letrec {X#1=S#4;E#14;E#2;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#1=(letrec {E#2} in S#4);E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#1=(letrec {E#2} in S#4);E#14;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( A#13[(app (\ X#9.S#11) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] , A#13[(letrec X#9= T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#11 )] ) where Delta1 = {T#14,A#12,T#7,A#13} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#9.[.])), (T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#9=[.]} in S#11)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (\ X#9.S#11) S#10)] -SR,lbeta1-> A#12[(letrec {X#9=S#10} in S#11)] and constraints: (S#10,(\ X#9.[.])), (S#10,(letrec {X#9=[.]} in S#11)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (\ X#9.S#11) S#10)]} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(\ X#9.[.])),(S#10,(letrec {X#9=[.]} in S#11)),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> A#13, T#7 |-> A#13[(app (\ X#9.S#11) T#15)], T#14 |-> (app (\ X#9.S#11) T#15), S#10 |-> T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: A#13[(app (\ X#9.S#11) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] <-cp-e1- A#13[(app (\ X#9.S#11) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ................................................................................ A#13[(app (\ X#9.S#11) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] -SR,lbeta1-> A#13[(letrec {X#9=T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#11)] ================================================================================ Critical Pair: ( A#13[(app A#14[(app (\ X#9.S#11) S#10)] T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] , A#13[(app A#14[(letrec {X#9=S#10} in S#11)] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) where Delta1 = {A#12,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(\ X#9.[.])), (S#10,(letrec {X#9=[.]} in S#11)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (\ X#9.S#11) S#10)] -SR,lbeta1-> A#12[(letrec {X#9=S#10} in S#11)] and constraints: (S#10,(\ X#9.[.])), (S#10,(letrec {X#9=[.]} in S#11)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (\ X#9.S#11) S#10)]} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(\ X#9.[.])),(S#10,(letrec {X#9=[.]} in S#11)),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> A#13[(app A#14[(app (\ X#9.S#11) S#10)] T#15)], A#12 |-> A#13[(app A#14 T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: A#13[(app A#14[(app (\ X#9.S#11) S#10)] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] <-cp-e1- A#13[(app A#14[(app (\ X#9.S#11) S#10)] T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ................................................................................ A#13[(app A#14[(app (\ X#9.S#11) S#10)] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] -SR,lbeta1-> A#13[(app A#14[(letrec {X#9=S#10} in S#11)] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ================================================================================ Critical Pair: ( (app (\ X#9.S#11) T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) , (letrec X#9= T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#11 ) ) where Delta1 = {T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#9.[.])), (T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#9=[.]} in S#11)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (\ X#9.S#11) S#10)] -SR,lbeta1-> A#12[(letrec {X#9=S#10} in S#11)] and constraints: (S#10,(\ X#9.[.])), (S#10,(letrec {X#9=[.]} in S#11)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (\ X#9.S#11) S#10)]} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(\ X#9.[.])),(S#10,(letrec {X#9=[.]} in S#11)),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> [.], T#7 |-> (app (\ X#9.S#11) T#13), S#10 |-> T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (app (\ X#9.S#11) T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) <-cp-e1- (app (\ X#9.S#11) T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ................................................................................ (app (\ X#9.S#11) T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) -SR,lbeta1-> (letrec {X#9=T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#11) ================================================================================ Critical Pair: ( (letrec E#10 in A#15[(app (\ X#9.S#12) T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec E#10 in A#15[(letrec X#9= T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#12 )] ) ) where Delta1 = {T#16,A#13,T#14,T#7,A#15} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#9.[.])), (T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#9=[.]} in S#12)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {E#10} in A#13[(letrec {X#9=S#11} in S#12)]) and constraints: E#10/= {}, (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#10} in A#15[(app (\ X#9.S#12) T#17)]), A#13 |-> A#15, T#14 |-> A#15[(app (\ X#9.S#12) T#17)], T#16 |-> (app (\ X#9.S#12) T#17), S#11 |-> T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#10} in A#15[(app (\ X#9.S#12) T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {E#10} in A#15[(app (\ X#9.S#12) T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {E#10} in A#15[(app (\ X#9.S#12) T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,lbeta2-> (letrec {E#10} in A#15[(letrec {X#9=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#12)]) ================================================================================ Critical Pair: ( (letrec E#10 in A#15[(app A#16[(app (\ X#9.S#12) S#11)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec E#10 in A#15[(app A#16[(letrec {X#9=S#11} in S#12)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#13,T#14,T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {E#10} in A#13[(letrec {X#9=S#11} in S#12)]) and constraints: E#10/= {}, (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#10} in A#15[(app A#16[(app (\ X#9.S#12) S#11)] T#17)]), T#14 |-> A#15[(app A#16[(app (\ X#9.S#12) S#11)] T#17)], A#13 |-> A#15[(app A#16 T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {E#10} in A#15[(app A#16[(app (\ X#9.S#12) S#11)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {E#10} in A#15[(app A#16[(app (\ X#9.S#12) S#11)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {E#10} in A#15[(app A#16[(app (\ X#9.S#12) S#11)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,lbeta2-> (letrec {E#10} in A#15[(app A#16[(letrec {X#9=S#11} in S#12)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec E#10 in (app (\ X#9.S#12) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ) , (letrec E#10 in (letrec X#9= T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#12 ) ) ) where Delta1 = {T#14,T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#9.[.])), (T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#9=[.]} in S#12)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {E#10} in A#13[(letrec {X#9=S#11} in S#12)]) and constraints: E#10/= {}, (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#10} in (app (\ X#9.S#12) T#15)), A#13 |-> [.], T#14 |-> (app (\ X#9.S#12) T#15), S#11 |-> T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#10} in (app (\ X#9.S#12) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) <-cp-e1- (letrec {E#10} in (app (\ X#9.S#12) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])) ................................................................................ (letrec {E#10} in (app (\ X#9.S#12) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) -SR,lbeta2-> (letrec {E#10} in (letrec {X#9=T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#12)) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#17 in A#13[(app (\ X#9.S#12) S#11)] ) , (letrec X#15= T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#17 in A#13[(letrec {X#9=S#11} in S#12)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {E#10} in A#13[(letrec {X#9=S#11} in S#12)]) and constraints: E#10/= {}, (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#15=T#14;E#17} in A#13[(app (\ X#9.S#12) S#11)]), E#10 |-> {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(app (\ X#9.S#12) S#11)]) <-cp-e1- (letrec {X#15=T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(app (\ X#9.S#12) S#11)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(letrec {X#9=S#11} in S#12)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;E#15 in A#13[(app (\ X#9.S#12) S#11)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;E#15 in A#13[(letrec {X#9=S#11} in S#12)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {E#10} in A#13[(letrec {X#9=S#11} in S#12)]) and constraints: E#10/= {}, (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10} in A#13[(app (\ X#9.S#12) S#11)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(app (\ X#9.S#12) S#11)], E#10 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15}, E#14 |-> {X#1=C#8[(var X#2)];E#15}, E#4 |-> {E#15}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in A#13[(app (\ X#9.S#12) S#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#15} in A#13[(app (\ X#9.S#12) S#11)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in A#13[(app (\ X#9.S#12) S#11)]) -SR,lbeta2-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in A#13[(letrec {X#9=S#11} in S#12)]) ================================================================================ Critical Pair: ( (letrec E#11 ;EE#15[X#9,(app (\ X#10.S#13) S#12)] in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec E#11 ;EE#15[X#9,(letrec {X#10=S#12} in S#13)] in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#14,T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19)]), T#16 |-> A#17[(app A#18[(var X#9)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 ;EE#15[X#9,(app (\ X#10.S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#17= T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 ;EE#15[X#9,(letrec {X#10=S#12} in S#13)] in A#14[(var X#9)] ) ) where Delta1 = {T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#17=T#16;E#19;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]), E#11 |-> {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19}, E#18 |-> {E#19;EE#15[X#9,(app (\ X#10.S#13) S#12)]}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#17=T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 in A#14[(var X#9)] ) , (letrec X#9= A#20[(letrec X#10= T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#13 )] ;E#11 in A#14[(var X#9)] ) ) where Delta1 = {T#21,A#19,T#16,T#7,A#20} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#10.[.])), (T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app (\ X#10.S#13) T#22)];E#11} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#9, E#18 |-> {E#11}, A#19 |-> A#20, T#16 |-> A#20[(app (\ X#10.S#13) T#22)], T#21 |-> (app (\ X#10.S#13) T#22), S#12 |-> T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=A#20[(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#9=A#20[(letrec {X#10=T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#13)];E#11} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app A#21[(app (\ X#10.S#13) S#12)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 in A#14[(var X#9)] ) , (letrec X#9= A#20[(app A#21[(letrec {X#10=S#12} in S#13)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app A#21[(app (\ X#10.S#13) S#12)] T#22)];E#11} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]}, X#17 |-> X#9, E#18 |-> {E#11}, T#16 |-> A#20[(app A#21[(app (\ X#10.S#13) S#12)] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=A#20[(app A#21[(app (\ X#10.S#13) S#12)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app A#21[(app (\ X#10.S#13) S#12)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app A#21[(app (\ X#10.S#13) S#12)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#9=A#20[(app A#21[(letrec {X#10=S#12} in S#13)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (app (\ X#10.S#13) T#20[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ;E#11 in A#14[(var X#9)] ) , (letrec X#9= (letrec X#10= T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#13 ) ;E#11 in A#14[(var X#9)] ) ) where Delta1 = {T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#10.[.])), (T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(app (\ X#10.S#13) T#20);E#11} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#9, E#18 |-> {E#11}, A#19 |-> [.], T#16 |-> (app (\ X#10.S#13) T#20), S#12 |-> T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=(app (\ X#10.S#13) T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=(app (\ X#10.S#13) T#20[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=(app (\ X#10.S#13) T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#9=(letrec {X#10=T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#13);E#11} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#21[X#20,(app (\ X#10.S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#9= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#21[X#20,(letrec {X#10=S#12} in S#13)] in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#22[(app A#23[(var X#20)] T#24)];E#11;EE#21[X#20,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#21[X#20,[.2]]}, X#17 |-> X#9, E#18 |-> {E#11;EE#21[X#20,(app (\ X#10.S#13) S#12)]}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#20,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#20,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#20,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#20,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#22[X#9,(var X#20)] ;EE#23[X#21,(app (\ X#10.S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#22[X#9,(var X#20)] ;EE#23[X#21,(letrec {X#10=S#12} in S#13)] in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];E#11;EE#22[X#9,(var X#20)];EE#23[X#21,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {E#11;EE#22[X#9,(var X#20)];EE#23[X#21,(app (\ X#10.S#13) S#12)]}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#22[X#9,(var X#20)];EE#23[X#21,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#22[X#9,(var X#20)];EE#23[X#21,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#22[X#9,(var X#20)];EE#23[X#21,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#22[X#9,(var X#20)];EE#23[X#21,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app (\ X#10.S#13) T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(letrec X#10= T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#13 )] ;E#11 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#23,A#19,T#16,T#7,A#22} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#10.[.])), (T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app (\ X#10.S#13) T#24)];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#11;EE#21[X#9,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[(app (\ X#10.S#13) T#24)], T#23 |-> (app (\ X#10.S#13) T#24), S#12 |-> T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#20=A#22[(app (\ X#10.S#13) T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app (\ X#10.S#13) T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app (\ X#10.S#13) T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#20=A#22[(letrec {X#10=T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#13)];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(app (\ X#10.S#13) S#12)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(app A#23[(letrec {X#10=S#12} in S#13)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#11 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app A#23[(app (\ X#10.S#13) S#12)] T#24)];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#11;EE#21[X#9,(var X#20)]}, T#16 |-> A#22[(app A#23[(app (\ X#10.S#13) S#12)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(app (\ X#10.S#13) S#12)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app A#23[(app (\ X#10.S#13) S#12)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(app (\ X#10.S#13) S#12)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#20=A#22[(app A#23[(letrec {X#10=S#12} in S#13)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= (app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ;E#11 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= (letrec X#10= T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] in S#13 ) ;E#11 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(\ X#10.[.])), (T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=(app (\ X#10.S#13) T#22);E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#11;EE#21[X#9,(var X#20)]}, A#19 |-> [.], T#16 |-> (app (\ X#10.S#13) T#22), S#12 |-> T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#20=(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=(app (\ X#10.S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#20=(letrec {X#10=T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} in S#13);E#11;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;E#17 ;EE#15[X#9,(app (\ X#10.S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;E#17 ;EE#15[X#9,(letrec {X#10=S#12} in S#13)] in A#14[(var X#9)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17}, E#16 |-> {X#1=C#8[(var X#2)];E#17}, E#4 |-> {E#17;EE#15[X#9,(app (\ X#10.S#13) S#12)]}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app (\ X#10.C#21[(\ X#3.S#5)]) S#12)] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(letrec {X#10=S#12} in C#21[(var X#2)])] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#20,C#19,A#17,C#8,A#18} Delta2 = {} Delta3 = {((\ X#3.S#5),A#18[(app (\ X#10.C#21) S#12)]), ((var X#2),A#18[(app (\ X#10.C#21) S#12)]), (S#5,A#18[(app (\ X#10.C#21) S#12)]), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in C#21[(var X#2)])), ((var X#2),A#18[(app (\ X#10.C#21[[.]]) S#12)]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> A#18, C#8 |-> A#18[(app (\ X#10.C#21) S#12)], C#19 |-> (app (\ X#10.C#21) S#12), C#20 |-> (\ X#10.C#21), S#13 |-> C#21[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (\ X#10.C#21[(var X#2)]) S#12)];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (\ X#10.C#21[(\ X#3.S#5)]) S#12)];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (\ X#10.C#21[(var X#2)]) S#12)];E#16} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(letrec {X#10=S#12} in C#21[(var X#2)])];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app (\ X#10.S#13) C#20[(\ X#3.S#5)])] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(letrec {X#10=C#20[(var X#2)]} in S#13)] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#19,A#17,C#8,A#18} Delta2 = {} Delta3 = {((\ X#3.S#5),A#18[(app (\ X#10.S#13) C#20)]), ((var X#2),A#18[(app (\ X#10.S#13) C#20)]), (S#5,A#18[(app (\ X#10.S#13) C#20)]), (C#20[(var X#2)],(\ X#10.[.])), (C#20[(var X#2)],(letrec {X#10=[.]} in S#13)), ((var X#2),A#18[(app (\ X#10.S#13) C#20[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> A#18, C#8 |-> A#18[(app (\ X#10.S#13) C#20)], C#19 |-> (app (\ X#10.S#13) C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (\ X#10.S#13) C#20[(var X#2)])];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (\ X#10.S#13) C#20[(\ X#3.S#5)])];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (\ X#10.S#13) C#20[(var X#2)])];E#16} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(letrec {X#10=C#20[(var X#2)]} in S#13)];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20[(\ X#3.S#5)])] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app A#19[(letrec {X#10=S#12} in S#13)] C#20[(var X#2)])] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20)]), ((var X#2),A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20)]), (S#5,A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20)]), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] C#20[(var X#2)])]}, X#1 |-> X#9, E#4 |-> {E#16}, C#8 |-> A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20)], A#17 |-> A#18[(app A#19 C#20[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20[(var X#2)])];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20[(\ X#3.S#5)])];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(app (\ X#10.S#13) S#12)] C#20[(var X#2)])];E#16} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(letrec {X#10=S#12} in S#13)] C#20[(var X#2)])];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (app (\ X#10.C#19[(\ X#3.S#5)]) S#12) ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {X#10=S#12} in C#19[(var X#2)]) ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#18,C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),(app (\ X#10.C#19) S#12)), ((var X#2),(app (\ X#10.C#19) S#12)), (S#5,(app (\ X#10.C#19) S#12)), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in C#19[(var X#2)])), ((var X#2),(app (\ X#10.C#19[[.]]) S#12)), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> [.], C#8 |-> (app (\ X#10.C#19) S#12), C#18 |-> (\ X#10.C#19), S#13 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(app (\ X#10.C#19[(var X#2)]) S#12);E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(app (\ X#10.C#19[(\ X#3.S#5)]) S#12);E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(app (\ X#10.C#19[(var X#2)]) S#12);E#16} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#10=S#12} in C#19[(var X#2)]);E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (app (\ X#10.S#13) C#18[(\ X#3.S#5)]) ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {X#10=C#18[(var X#2)]} in S#13) ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),(app (\ X#10.S#13) C#18)), ((var X#2),(app (\ X#10.S#13) C#18)), (S#5,(app (\ X#10.S#13) C#18)), (C#18[(var X#2)],(\ X#10.[.])), (C#18[(var X#2)],(letrec {X#10=[.]} in S#13)), ((var X#2),(app (\ X#10.S#13) C#18[[.]])), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> [.], C#8 |-> (app (\ X#10.S#13) C#18), S#12 |-> C#18[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(app (\ X#10.S#13) C#18[(var X#2)]);E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(app (\ X#10.S#13) C#18[(\ X#3.S#5)]);E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(app (\ X#10.S#13) C#18[(var X#2)]);E#16} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#10=C#18[(var X#2)]} in S#13);E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#20[(app A#21[(var X#18)] C#22[(\ X#3.S#5)])] ;E#16 ;EE#19[X#18,(app (\ X#10.S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#20[(app A#21[(var X#18)] C#22[(var X#2)])] ;E#16 ;EE#19[X#18,(letrec {X#10=S#12} in S#13)] in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),A#20[(app A#21[(var X#18)] C#22)]), ((var X#2),A#20[(app A#21[(var X#18)] C#22)]), (S#5,A#20[(app A#21[(var X#18)] C#22)]), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),A#20[(app A#21[(var X#18)] C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];EE#19[X#18,[.2]]}, X#1 |-> X#9, E#4 |-> {E#16;EE#19[X#18,(app (\ X#10.S#13) S#12)]}, C#8 |-> A#20[(app A#21[(var X#18)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];E#16;EE#19[X#18,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(\ X#3.S#5)])];E#16;EE#19[X#18,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];E#16;EE#19[X#18,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];E#16;EE#19[X#18,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#20[X#9,(var X#18)] ;EE#21[X#19,(app (\ X#10.S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(var X#2)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#20[X#9,(var X#18)] ;EE#21[X#19,(letrec {X#10=S#12} in S#13)] in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),A#22[(app A#23[(var X#19)] C#24)]), ((var X#2),A#22[(app A#23[(var X#19)] C#24)]), (S#5,A#22[(app A#23[(var X#19)] C#24)]), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),A#22[(app A#23[(var X#19)] C#24[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#1 |-> X#18, E#4 |-> {E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (\ X#10.S#13) S#12)]}, C#8 |-> A#22[(app A#23[(var X#19)] C#24)], A#17 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(\ X#3.S#5)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (\ X#10.C#23[(\ X#3.S#5)]) S#12)] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(letrec {X#10=S#12} in C#23[(var X#2)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#22,C#21,A#17,C#8,A#20} Delta2 = {} Delta3 = {((\ X#3.S#5),A#20[(app (\ X#10.C#23) S#12)]), ((var X#2),A#20[(app (\ X#10.C#23) S#12)]), (S#5,A#20[(app (\ X#10.C#23) S#12)]), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in C#23[(var X#2)])), ((var X#2),A#20[(app (\ X#10.C#23[[.]]) S#12)]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[(app (\ X#10.C#23) S#12)], C#21 |-> (app (\ X#10.C#23) S#12), C#22 |-> (\ X#10.C#23), S#13 |-> C#23[(var X#2)]} and instantiated rules: (letrec {X#18=A#20[(app (\ X#10.C#23[(var X#2)]) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app (\ X#10.C#23[(\ X#3.S#5)]) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app (\ X#10.C#23[(var X#2)]) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#18=A#20[(letrec {X#10=S#12} in C#23[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (\ X#10.S#13) C#22[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(letrec {X#10=C#22[(var X#2)]} in S#13)] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#21,A#17,C#8,A#20} Delta2 = {} Delta3 = {((\ X#3.S#5),A#20[(app (\ X#10.S#13) C#22)]), ((var X#2),A#20[(app (\ X#10.S#13) C#22)]), (S#5,A#20[(app (\ X#10.S#13) C#22)]), (C#22[(var X#2)],(\ X#10.[.])), (C#22[(var X#2)],(letrec {X#10=[.]} in S#13)), ((var X#2),A#20[(app (\ X#10.S#13) C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[(app (\ X#10.S#13) C#22)], C#21 |-> (app (\ X#10.S#13) C#22), S#12 |-> C#22[(var X#2)]} and instantiated rules: (letrec {X#18=A#20[(app (\ X#10.S#13) C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app (\ X#10.S#13) C#22[(\ X#3.S#5)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app (\ X#10.S#13) C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#18=A#20[(letrec {X#10=C#22[(var X#2)]} in S#13)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(app A#21[(letrec {X#10=S#12} in S#13)] C#22[(var X#2)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22)]), ((var X#2),A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22)]), (S#5,A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22)]), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)), ((var X#2),A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] C#22[(var X#2)])];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, C#8 |-> A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22[(\ X#3.S#5)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (\ X#10.S#13) S#12)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#18=A#20[(app A#21[(letrec {X#10=S#12} in S#13)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (\ X#10.C#21[(\ X#3.S#5)]) S#12) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= (letrec {X#10=S#12} in C#21[(var X#2)]) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#20,C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),(app (\ X#10.C#21) S#12)), ((var X#2),(app (\ X#10.C#21) S#12)), (S#5,(app (\ X#10.C#21) S#12)), (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in C#21[(var X#2)])), ((var X#2),(app (\ X#10.C#21[[.]]) S#12)), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> [.], C#8 |-> (app (\ X#10.C#21) S#12), C#20 |-> (\ X#10.C#21), S#13 |-> C#21[(var X#2)]} and instantiated rules: (letrec {X#18=(app (\ X#10.C#21[(var X#2)]) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=(app (\ X#10.C#21[(\ X#3.S#5)]) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(app (\ X#10.C#21[(var X#2)]) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#18=(letrec {X#10=S#12} in C#21[(var X#2)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (\ X#10.S#13) C#20[(\ X#3.S#5)]) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= (letrec {X#10=C#20[(var X#2)]} in S#13) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),(app (\ X#10.S#13) C#20)), ((var X#2),(app (\ X#10.S#13) C#20)), (S#5,(app (\ X#10.S#13) C#20)), (C#20[(var X#2)],(\ X#10.[.])), (C#20[(var X#2)],(letrec {X#10=[.]} in S#13)), ((var X#2),(app (\ X#10.S#13) C#20[[.]])), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {E#11;EE#15[X#9,(letrec {X#10=S#12} in S#13)]} in A#14[(var X#9)]) and constraints: (S#12,(\ X#10.[.])), (S#12,(letrec {X#10=[.]} in S#13)) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#11;EE#15[X#9,(app (\ X#10.S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(\ X#10.[.])),(S#12,(letrec {X#10=[.]} in S#13)),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> [.], C#8 |-> (app (\ X#10.S#13) C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#18=(app (\ X#10.S#13) C#20[(var X#2)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=(app (\ X#10.S#13) C#20[(\ X#3.S#5)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(app (\ X#10.S#13) C#20[(var X#2)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lbeta3-> (letrec {X#18=(letrec {X#10=C#20[(var X#2)]} in S#13);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (\ X#10.S#12) ;E#11 in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec X#9= (\ X#10.S#12) ;E#11 in A#15[(app A#16[(\ X#10.S#12)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#13,T#14,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#15[(app A#16[[.]] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(\ X#10.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(\ X#10.S#12);E#11} in A#15[(app A#16[(var X#9)] T#17)]), T#14 |-> A#15[(app A#16[(var X#9)] T#17)], A#13 |-> A#15[(app A#16 T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=(\ X#10.S#12);E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {X#9=(\ X#10.S#12);E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {X#9=(\ X#10.S#12);E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,cp-in1-> (letrec {X#9=(\ X#10.S#12);E#11} in A#15[(app A#16[(\ X#10.S#12)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#12) ;E#17 in A#13[(var X#9)] ) , (letrec X#15= T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#12) ;E#17 in A#13[(\ X#10.S#12)] ) ) where Delta1 = {T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(\ X#10.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#15=T#14;X#9=(\ X#10.S#12);E#17} in A#13[(var X#9)]), E#11 |-> {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17}, E#16 |-> {X#9=(\ X#10.S#12);E#17}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#12);E#17} in A#13[(var X#9)]) <-cp-e1- (letrec {X#15=T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#12);E#17} in A#13[(var X#9)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#12);E#17} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#12);E#17} in A#13[(\ X#10.S#12)]) ================================================================================ Critical Pair: ( (letrec {X#1=C#8[(\ X#10.S#12)];X#9=(\ X#10.S#12);E#14} in A#13[(var X#9)]) , (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#12);E#14} in A#13[(\ X#10.S#12)]) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#10.S#12),C#8), ((var X#9),C#8), (S#12,C#8), ((var X#9),C#8[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(\ X#10.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(var X#9)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#12, E#11 |-> {X#1=C#8[(var X#9)];E#14}, E#4 |-> {E#14}} and instantiated rules: (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#12);E#14} in A#13[(var X#9)]) <-cp-e1- (letrec {X#1=C#8[(\ X#10.S#12)];X#9=(\ X#10.S#12);E#14} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#12);E#14} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#12);E#14} in A#13[(\ X#10.S#12)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#15[(\ X#3.S#5)]) ;E#14 in A#13[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#15[(var X#2)]) ;E#14 in A#13[(\ X#10.C#15[(var X#2)])] ) ) where Delta1 = {C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),(\ X#10.C#15)), ((var X#2),(\ X#10.C#15)), (S#5,(\ X#10.C#15)), ((var X#2),(\ X#10.C#15[[.]])), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(\ X#10.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#14}, X#1 |-> X#9, E#4 |-> {E#14}, C#8 |-> (\ X#10.C#15), S#12 |-> C#15[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#15[(var X#2)]);E#14} in A#13[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#15[(\ X#3.S#5)]);E#14} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#15[(var X#2)]);E#14} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#15[(var X#2)]);E#14} in A#13[(\ X#10.C#15[(var X#2)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#12) ;E#15 in A#13[(var X#9)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#12) ;E#15 in A#13[(\ X#10.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(\ X#10.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(var X#9)], E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15}, E#14 |-> {X#1=C#8[(var X#2)];E#15}, E#4 |-> {X#9=(\ X#10.S#12);E#15}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#12);E#15} in A#13[(var X#9)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#12);E#15} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#12);E#15} in A#13[(var X#9)]) -SR,cp-in1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#12);E#15} in A#13[(\ X#10.S#12)]) ================================================================================ Critical Pair: ( (letrec X#9= (\ X#10.S#13) ;E#12 ;VV#15|X#11,(var X#9)| in A#17[(app A#18[(var X#11)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec X#9= (\ X#10.S#13) ;E#12 ;VV#15|X#11,(var X#9)| in A#17[(app A#18[(\ X#10.S#13)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#14,T#16,T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#17[(app A#18[(var X#11)] T#19)]), T#16 |-> A#17[(app A#18[(var X#11)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#17[(app A#18[(var X#11)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#17[(app A#18[(var X#11)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#17[(app A#18[(var X#11)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#17[(app A#18[(\ X#10.S#13)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#13) ;E#19 ;VV#15|X#11,(var X#9)| in A#14[(var X#11)] ) , (letrec X#17= T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#13) ;E#19 ;VV#15|X#11,(var X#9)| in A#14[(\ X#10.S#13)] ) ) where Delta1 = {T#7} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#14[[.]]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> (letrec {X#17=T#16;X#9=(\ X#10.S#13);E#19;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]), E#12 |-> {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19}, E#18 |-> {X#9=(\ X#10.S#13);E#19;VV#15|X#11,(var X#9)|}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#19;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) <-cp-e1- (letrec {X#17=T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#19;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#19;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#19;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#10.S#13)] ;X#9= (\ X#10.S#13) ;E#16 ;VV#15|X#11,(var X#9)| in A#14[(var X#11)] ) , (letrec X#1= C#8[(var X#9)] ;X#9= (\ X#10.S#13) ;E#16 ;VV#15|X#11,(var X#9)| in A#14[(\ X#10.S#13)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#10.S#13),C#8), ((var X#9),C#8), (S#13,C#8), ((var X#9),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#14[[.]]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, E#12 |-> {X#1=C#8[(var X#9)];E#16}, E#4 |-> {E#16;VV#15|X#11,(var X#9)|}} and instantiated rules: (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#13);E#16;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#16;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) ................................................................................ (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#13);E#16;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#13);E#16;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) ================================================================================ Critical Pair: ( (letrec {X#11=(\ X#10.S#13);X#9=(\ X#10.S#13);E#12} in A#14[(var X#11)]) , (letrec {X#11=(var X#9);X#9=(\ X#10.S#13);E#12} in A#14[(\ X#10.S#13)]) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#10.S#13),[.]), ((var X#9),[.]), (S#13,[.]), ((var X#9),[.]), ((var X#9),[.]), ((var X#11),A#14[[.]]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, VV#15|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {E#12}, C#8 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#11=(var X#9);X#9=(\ X#10.S#13);E#12} in A#14[(var X#11)]) <-cp-e1- (letrec {X#11=(\ X#10.S#13);X#9=(\ X#10.S#13);E#12} in A#14[(var X#11)]) ................................................................................ (letrec {X#11=(var X#9);X#9=(\ X#10.S#13);E#12} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#11=(var X#9);X#9=(\ X#10.S#13);E#12} in A#14[(\ X#10.S#13)]) ================================================================================ Critical Pair: ( (letrec X#17= (\ X#10.S#13) ;X#9= (\ X#10.S#13) ;E#12 ;VV#18|X#11,(var X#17)| in A#14[(var X#11)] ) , (letrec X#17= (var X#9) ;X#9= (\ X#10.S#13) ;E#12 ;VV#18|X#11,(var X#17)| in A#14[(\ X#10.S#13)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#10.S#13),[.]), ((var X#9),[.]), (S#13,[.]), ((var X#9),[.]), ((var X#9),[.]), ((var X#11),A#14[[.]]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, VV#15|.1,.2| |-> {X#17=[.2];VV#18|[.1],(var X#17)|}, X#1 |-> X#17, E#4 |-> {E#12;VV#18|X#11,(var X#17)|}, C#8 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#17=(var X#9);X#9=(\ X#10.S#13);E#12;VV#18|X#11,(var X#17)|} in A#14[(var X#11)]) <-cp-e1- (letrec {X#17=(\ X#10.S#13);X#9=(\ X#10.S#13);E#12;VV#18|X#11,(var X#17)|} in A#14[(var X#11)]) ................................................................................ (letrec {X#17=(var X#9);X#9=(\ X#10.S#13);E#12;VV#18|X#11,(var X#17)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#17=(var X#9);X#9=(\ X#10.S#13);E#12;VV#18|X#11,(var X#17)|} in A#14[(\ X#10.S#13)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#17[(\ X#3.S#5)]) ;E#16 ;VV#15|X#11,(var X#9)| in A#14[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#17[(var X#2)]) ;E#16 ;VV#15|X#11,(var X#9)| in A#14[(\ X#10.C#17[(var X#2)])] ) ) where Delta1 = {C#8} Delta2 = {} Delta3 = {((\ X#3.S#5),(\ X#10.C#17)), ((var X#2),(\ X#10.C#17)), (S#5,(\ X#10.C#17)), ((var X#2),(\ X#10.C#17[[.]])), ((var X#9),[.]), ((var X#11),A#14[[.]]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, X#1 |-> X#9, E#4 |-> {E#16;VV#15|X#11,(var X#9)|}, C#8 |-> (\ X#10.C#17), S#13 |-> C#17[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#17[(var X#2)]);E#16;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#17[(\ X#3.S#5)]);E#16;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#17[(var X#2)]);E#16;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#17[(var X#2)]);E#16;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.C#17[(var X#2)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;VV#15|X#11,(var X#9)| in A#14[(var X#11)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;VV#15|X#11,(var X#9)| in A#14[(\ X#10.S#13)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#14[[.]]), ((var X#9),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) and constraints: and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;VV#15|X#11,(var X#9)|} in A#14[(var X#11)])} Delta1= {} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#14[[.]]),((var X#9),[.])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#11)], E#12 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17}, E#16 |-> {X#1=C#8[(var X#2)];E#17}, E#4 |-> {X#9=(\ X#10.S#13);E#17;VV#15|X#11,(var X#9)|}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;VV#15|X#11,(var X#9)|} in A#14[(var X#11)]) -SR,cp-in2-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;VV#15|X#11,(var X#9)|} in A#14[(\ X#10.S#13)]) ================================================================================ Critical Pair: ( (letrec X#9= (\ X#10.S#13) ;E#12 ;EE#16[X#11,A#14[(var X#9)]] in A#18[(app A#19[(var X#11)] T#20[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec X#9= (\ X#10.S#13) ;E#12 ;EE#16[X#11,A#14[(\ X#10.S#13)]] in A#18[(app A#19[(var X#11)] T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#15,T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#18[(app A#19[[.]] T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#11),A#18[(app A#19[[.]] T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#18[(app A#19[(var X#11)] T#20)]), T#17 |-> A#18[(app A#19[(var X#11)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#18[(app A#19[(var X#11)] T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#18[(app A#19[(var X#11)] T#20[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#18[(app A#19[(var X#11)] T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#18[(app A#19[(var X#11)] T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#18= T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#13) ;E#20 ;EE#16[X#11,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#18= T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#13) ;E#20 ;EE#16[X#11,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#18=T#17;X#9=(\ X#10.S#13);E#20;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]), E#12 |-> {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20}, E#19 |-> {X#9=(\ X#10.S#13);E#20;EE#16[X#11,A#14[(var X#9)]]}} and instantiated rules: (letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#20;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#20;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#20;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#13);E#20;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#21[A#23[(app A#24[(\ X#10.S#13)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {T#22,A#20,T#17,T#7,A#14,A#21} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#23[(app A#24[[.]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#21[A#23[(app A#24[(var X#9)] T#25)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]), EE#16[.1,.2] |-> {[.1]=A#21[[.2]]}, X#18 |-> X#11, E#19 |-> {X#9=(\ X#10.S#13);E#12}, A#20 |-> A#21, T#17 |-> A#21[A#23[(app A#24[(var X#9)] T#25)]], T#22 |-> A#23[(app A#24[(var X#9)] T#25)], A#14 |-> A#23[(app A#24 T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#21[A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#21[A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#21[A#23[(app A#24[(\ X#10.S#13)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[(app A#22[A#14[(var X#9)]] T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#21[(app A#22[A#14[(\ X#10.S#13)]] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {A#20,T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#21[(app A#22[A#14[(var X#9)]] T#23)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]), EE#16[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]}, X#18 |-> X#11, E#19 |-> {X#9=(\ X#10.S#13);E#12}, T#17 |-> A#21[(app A#22[A#14[(var X#9)]] T#23)], A#20 |-> A#21[(app A#22 T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#21[(app A#22[A#14[(var X#9)]] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[(app A#22[A#14[(var X#9)]] T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#21[(app A#22[A#14[(var X#9)]] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#21[(app A#22[A#14[(\ X#10.S#13)]] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[(app A#22[(var X#9)] T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#21[(app A#22[(\ X#10.S#13)] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#21[(app A#22[[.]] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#21[(app A#22[(var X#9)] T#23)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]), EE#16[.1,.2] |-> {[.1]=[.2]}, X#18 |-> X#11, E#19 |-> {X#9=(\ X#10.S#13);E#12}, A#20 |-> [.], T#17 |-> A#21[(app A#22[(var X#9)] T#23)], A#14 |-> A#21[(app A#22 T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#21[(app A#22[(var X#9)] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[(app A#22[(var X#9)] T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#21[(app A#22[(var X#9)] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#21[(app A#22[(\ X#10.S#13)] T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#21,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#11= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#21,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#20,T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#23[(app A#24[(var X#21)] T#25)];X#9=(\ X#10.S#13);E#12;EE#22[X#21,A#14[(var X#9)]]} in A#15[(var X#11)]), EE#16[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#22[X#21,[.2]]}, X#18 |-> X#11, E#19 |-> {X#9=(\ X#10.S#13);E#12;EE#22[X#21,A#14[(var X#9)]]}, T#17 |-> A#23[(app A#24[(var X#21)] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#21,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#21,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#21,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#21,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#23[X#11,(var X#21)] ;EE#24[X#22,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#23[X#11,(var X#21)] ;EE#24[X#22,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#20,T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27)];X#9=(\ X#10.S#13);E#12;EE#23[X#11,(var X#21)];EE#24[X#22,A#14[(var X#9)]]} in A#15[(var X#11)]), EE#16[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#18 |-> X#21, E#19 |-> {X#9=(\ X#10.S#13);E#12;EE#23[X#11,(var X#21)];EE#24[X#22,A#14[(var X#9)]]}, T#17 |-> A#25[(app A#26[(var X#22)] T#27)], A#20 |-> A#25[(app A#26 T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#23[X#11,(var X#21)];EE#24[X#22,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#23[X#11,(var X#21)];EE#24[X#22,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#23[X#11,(var X#21)];EE#24[X#22,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#23[X#11,(var X#21)];EE#24[X#22,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#25[(app A#26[(var X#9)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#11,(var X#21)] in A#15[(var X#11)] ) , (letrec X#21= A#23[A#25[(app A#26[(\ X#10.S#13)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#11,(var X#21)] in A#15[(var X#11)] ) ) where Delta1 = {T#24,A#20,T#17,T#7,A#14,A#23} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#25[(app A#26[[.]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#21=A#23[A#25[(app A#26[(var X#9)] T#27)]];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]), EE#16[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]}, A#20 |-> A#23, T#17 |-> A#23[A#25[(app A#26[(var X#9)] T#27)]], T#24 |-> A#25[(app A#26[(var X#9)] T#27)], A#14 |-> A#25[(app A#26 T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#21=A#23[A#25[(app A#26[(var X#9)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#21=A#23[A#25[(app A#26[(var X#9)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#21=A#23[A#25[(app A#26[(var X#9)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#21=A#23[A#25[(app A#26[(\ X#10.S#13)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[A#14[(var X#9)]] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#11,(var X#21)] in A#15[(var X#11)] ) , (letrec X#21= A#23[(app A#24[A#14[(\ X#10.S#13)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#11,(var X#21)] in A#15[(var X#11)] ) ) where Delta1 = {A#20,T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#21=A#23[(app A#24[A#14[(var X#9)]] T#25)];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]), EE#16[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]}, T#17 |-> A#23[(app A#24[A#14[(var X#9)]] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[A#14[(var X#9)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#21=A#23[(app A#24[A#14[(var X#9)]] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#21=A#23[(app A#24[A#14[(var X#9)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#21=A#23[(app A#24[A#14[(\ X#10.S#13)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#11,(var X#21)] in A#15[(var X#11)] ) , (letrec X#21= A#23[(app A#24[(\ X#10.S#13)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#22[X#11,(var X#21)] in A#15[(var X#11)] ) ) where Delta1 = {T#17,T#7,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#23[(app A#24[[.]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#21=A#23[(app A#24[(var X#9)] T#25)];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]), EE#16[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]}, A#20 |-> [.], T#17 |-> A#23[(app A#24[(var X#9)] T#25)], A#14 |-> A#23[(app A#24 T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#21=A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#21=A#23[(app A#24[(var X#9)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#21=A#23[(app A#24[(\ X#10.S#13)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#13);E#12;EE#22[X#11,(var X#21)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#10.S#13)] ;X#9= (\ X#10.S#13) ;E#17 ;EE#16[X#11,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#1= C#8[(var X#9)] ;X#9= (\ X#10.S#13) ;E#17 ;EE#16[X#11,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),C#8), ((var X#9),C#8), (S#13,C#8), ((var X#9),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, E#12 |-> {X#1=C#8[(var X#9)];E#17}, E#4 |-> {E#17;EE#16[X#11,A#14[(var X#9)]]}} and instantiated rules: (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#13);E#17;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#17;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#13);E#17;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#13);E#17;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#18[A#20[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#18[A#20[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {C#19,A#17,C#8,A#14,A#18,A#20} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18[A#20[[.]]]), ((var X#9),A#18[A#20[[.]]]), (S#13,A#18[A#20[[.]]]), ((var X#9),A#18[A#20[[.]]]), ((var X#9),A#20[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#11, E#4 |-> {E#12}, A#17 |-> A#18, C#8 |-> A#18[A#20[[.]]], A#14 |-> A#20, C#19 |-> A#20[[.]], C#21 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#11=A#18[A#20[(var X#9)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[A#20[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[A#20[(var X#9)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[A#20[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#18[A#20[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#18[A#20[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {C#19,A#17,C#8,A#14,A#18,A#20} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18[A#20]), ((var X#9),A#18[A#20]), (S#13,A#18[A#20]), ((var X#9),A#18[A#20[[.]]]), ((var X#9),A#20[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#11, E#4 |-> {E#12}, A#17 |-> A#18, C#8 |-> A#18[A#20], A#14 |-> A#20[[.]], C#19 |-> A#20, A#21 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#11=A#18[A#20[(var X#9)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[A#20[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[A#20[(var X#9)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[A#20[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#18[A#20[(app A#21[(var X#9)] C#22[(\ X#10.S#13)])]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#18[A#20[(app A#21[(\ X#10.S#13)] C#22[(var X#9)])]] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {C#19,A#17,C#8,A#14,A#18} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18[A#20[(app A#21[(var X#9)] C#22)]]), ((var X#9),A#18[A#20[(app A#21[(var X#9)] C#22)]]), (S#13,A#18[A#20[(app A#21[(var X#9)] C#22)]]), ((var X#9),A#18[A#20[(app A#21[(var X#9)] C#22[[.]])]]), ((var X#9),A#20[(app A#21[[.]] C#22[(var X#9)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#11, E#4 |-> {E#12}, A#17 |-> A#18, C#8 |-> A#18[A#20[(app A#21[(var X#9)] C#22)]], C#19 |-> A#20[(app A#21[(var X#9)] C#22)], A#14 |-> A#20[(app A#21 C#22[(var X#9)])]} and instantiated rules: (letrec {X#11=A#18[A#20[(app A#21[(var X#9)] C#22[(var X#9)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[A#20[(app A#21[(var X#9)] C#22[(\ X#10.S#13)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[A#20[(app A#21[(var X#9)] C#22[(var X#9)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[A#20[(app A#21[(\ X#10.S#13)] C#22[(var X#9)])]];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#18[(app A#19[A#14[(var X#9)]] C#20[(\ X#10.S#13)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#18[(app A#19[A#14[(\ X#10.S#13)]] C#20[(var X#9)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {A#17,C#8,A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18[(app A#19[A#14[(var X#9)]] C#20)]), ((var X#9),A#18[(app A#19[A#14[(var X#9)]] C#20)]), (S#13,A#18[(app A#19[A#14[(var X#9)]] C#20)]), ((var X#9),A#18[(app A#19[A#14[(var X#9)]] C#20[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] C#20[(var X#9)])]}, X#1 |-> X#11, E#4 |-> {E#12}, C#8 |-> A#18[(app A#19[A#14[(var X#9)]] C#20)], A#17 |-> A#18[(app A#19 C#20[(var X#9)])]} and instantiated rules: (letrec {X#11=A#18[(app A#19[A#14[(var X#9)]] C#20[(var X#9)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[(app A#19[A#14[(var X#9)]] C#20[(\ X#10.S#13)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[(app A#19[A#14[(var X#9)]] C#20[(var X#9)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[(app A#19[A#14[(\ X#10.S#13)]] C#20[(var X#9)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) , (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ) where Delta1 = {C#8,A#14,A#18} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18[[.]]), ((var X#9),A#18[[.]]), (S#13,A#18[[.]]), ((var X#9),A#18[[.]]), ((var X#9),A#18[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {E#12}, A#17 |-> [.], A#14 |-> A#18, C#8 |-> A#18[[.]], C#19 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#11=A#18[(var X#9)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[(var X#9)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) , (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ) where Delta1 = {C#8,A#14,A#18} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18), ((var X#9),A#18), (S#13,A#18), ((var X#9),A#18[[.]]), ((var X#9),A#18[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {E#12}, A#17 |-> [.], A#14 |-> A#18[[.]], C#8 |-> A#18, A#19 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#11=A#18[(var X#9)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[(var X#9)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#18[(app A#19[(var X#9)] C#20[(\ X#10.S#13)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) , (letrec X#11= A#18[(app A#19[(\ X#10.S#13)] C#20[(var X#9)])] ;X#9= (\ X#10.S#13) ;E#12 in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),A#18[(app A#19[(var X#9)] C#20)]), ((var X#9),A#18[(app A#19[(var X#9)] C#20)]), (S#13,A#18[(app A#19[(var X#9)] C#20)]), ((var X#9),A#18[(app A#19[(var X#9)] C#20[[.]])]), ((var X#9),A#18[(app A#19[[.]] C#20[(var X#9)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {E#12}, A#17 |-> [.], C#8 |-> A#18[(app A#19[(var X#9)] C#20)], A#14 |-> A#18[(app A#19 C#20[(var X#9)])]} and instantiated rules: (letrec {X#11=A#18[(app A#19[(var X#9)] C#20[(var X#9)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#18[(app A#19[(var X#9)] C#20[(\ X#10.S#13)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#18[(app A#19[(var X#9)] C#20[(var X#9)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#18[(app A#19[(\ X#10.S#13)] C#20[(var X#9)])];X#9=(\ X#10.S#13);E#12} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#20[(app A#21[(var X#18)] C#22[(\ X#10.S#13)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#18,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#11= A#20[(app A#21[(var X#18)] C#22[(var X#9)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#18,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#17,C#8,A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[(app A#21[(var X#18)] C#22)]), ((var X#9),A#20[(app A#21[(var X#18)] C#22)]), (S#13,A#20[(app A#21[(var X#18)] C#22)]), ((var X#9),A#20[(app A#21[(var X#18)] C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] C#22[(var X#9)])];EE#19[X#18,[.2]]}, X#1 |-> X#11, E#4 |-> {E#12;EE#19[X#18,A#14[(var X#9)]]}, C#8 |-> A#20[(app A#21[(var X#18)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#9)])]} and instantiated rules: (letrec {X#11=A#20[(app A#21[(var X#18)] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#18,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#20[(app A#21[(var X#18)] C#22[(\ X#10.S#13)])];X#9=(\ X#10.S#13);E#12;EE#19[X#18,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#20[(app A#21[(var X#18)] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#18,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#20[(app A#21[(var X#18)] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#18,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(\ X#10.S#13)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#20[X#11,(var X#18)] ;EE#21[X#19,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(var X#9)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#20[X#11,(var X#18)] ;EE#21[X#19,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#17,C#8,A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),A#22[(app A#23[(var X#19)] C#24)]), ((var X#9),A#22[(app A#23[(var X#19)] C#24)]), (S#13,A#22[(app A#23[(var X#19)] C#24)]), ((var X#9),A#22[(app A#23[(var X#19)] C#24[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#9)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#1 |-> X#18, E#4 |-> {E#12;EE#20[X#11,(var X#18)];EE#21[X#19,A#14[(var X#9)]]}, C#8 |-> A#22[(app A#23[(var X#19)] C#24)], A#17 |-> A#22[(app A#23 C#24[(var X#9)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#20[X#11,(var X#18)];EE#21[X#19,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(\ X#10.S#13)])];X#9=(\ X#10.S#13);E#12;EE#20[X#11,(var X#18)];EE#21[X#19,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#20[X#11,(var X#18)];EE#21[X#19,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#20[X#11,(var X#18)];EE#21[X#19,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[A#22[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {C#21,A#17,C#8,A#14,A#20,A#22} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[A#22[[.]]]), ((var X#9),A#20[A#22[[.]]]), (S#13,A#20[A#22[[.]]]), ((var X#9),A#20[A#22[[.]]]), ((var X#9),A#22[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[A#22[[.]]], A#14 |-> A#22, C#21 |-> A#22[[.]], C#23 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#18=A#20[A#22[(var X#9)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[A#22[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[A#22[(var X#9)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[A#22[(\ X#10.S#13)]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {C#21,A#17,C#8,A#14,A#20,A#22} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[A#22]), ((var X#9),A#20[A#22]), (S#13,A#20[A#22]), ((var X#9),A#20[A#22[[.]]]), ((var X#9),A#22[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[A#22], A#14 |-> A#22[[.]], C#21 |-> A#22, A#23 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#18=A#20[A#22[(var X#9)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[A#22[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[A#22[(var X#9)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(\ X#10.S#13)]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(app A#23[(var X#9)] C#24[(\ X#10.S#13)])]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[A#22[(app A#23[(\ X#10.S#13)] C#24[(var X#9)])]] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {C#21,A#17,C#8,A#14,A#20} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[A#22[(app A#23[(var X#9)] C#24)]]), ((var X#9),A#20[A#22[(app A#23[(var X#9)] C#24)]]), (S#13,A#20[A#22[(app A#23[(var X#9)] C#24)]]), ((var X#9),A#20[A#22[(app A#23[(var X#9)] C#24[[.]])]]), ((var X#9),A#22[(app A#23[[.]] C#24[(var X#9)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[A#22[(app A#23[(var X#9)] C#24)]], C#21 |-> A#22[(app A#23[(var X#9)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#9)])]} and instantiated rules: (letrec {X#18=A#20[A#22[(app A#23[(var X#9)] C#24[(var X#9)])]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[A#22[(app A#23[(var X#9)] C#24[(\ X#10.S#13)])]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[A#22[(app A#23[(var X#9)] C#24[(var X#9)])]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(app A#23[(\ X#10.S#13)] C#24[(var X#9)])]];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[A#14[(var X#9)]] C#22[(\ X#10.S#13)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[(app A#21[A#14[(\ X#10.S#13)]] C#22[(var X#9)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {A#17,C#8,A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[(app A#21[A#14[(var X#9)]] C#22)]), ((var X#9),A#20[(app A#21[A#14[(var X#9)]] C#22)]), (S#13,A#20[(app A#21[A#14[(var X#9)]] C#22)]), ((var X#9),A#20[(app A#21[A#14[(var X#9)]] C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] C#22[(var X#9)])];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, C#8 |-> A#20[(app A#21[A#14[(var X#9)]] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#9)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[A#14[(var X#9)]] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[(app A#21[A#14[(var X#9)]] C#22[(\ X#10.S#13)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[(app A#21[A#14[(var X#9)]] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[A#14[(\ X#10.S#13)]] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(\ X#10.S#13)] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[(\ X#10.S#13)] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14,A#20} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[[.]]), ((var X#9),A#20[[.]]), (S#13,A#20[[.]]), ((var X#9),A#20[[.]]), ((var X#9),A#20[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, A#17 |-> [.], A#14 |-> A#20, C#8 |-> A#20[[.]], C#21 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#18=A#20[(var X#9)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[(var X#9)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(\ X#10.S#13)] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[(\ X#10.S#13)] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14,A#20} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20), ((var X#9),A#20), (S#13,A#20), ((var X#9),A#20[[.]]), ((var X#9),A#20[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, A#17 |-> [.], A#14 |-> A#20[[.]], C#8 |-> A#20, A#21 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#18=A#20[(var X#9)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[(var X#9)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[(\ X#10.S#13)];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#9)] C#22[(\ X#10.S#13)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) , (letrec X#18= A#20[(app A#21[(\ X#10.S#13)] C#22[(var X#9)])] ;X#9= (\ X#10.S#13) ;E#12 ;EE#19[X#11,(var X#18)] in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14} Delta2 = {} Delta3 = {((\ X#10.S#13),A#20[(app A#21[(var X#9)] C#22)]), ((var X#9),A#20[(app A#21[(var X#9)] C#22)]), (S#13,A#20[(app A#21[(var X#9)] C#22)]), ((var X#9),A#20[(app A#21[(var X#9)] C#22[[.]])]), ((var X#9),A#20[(app A#21[[.]] C#22[(var X#9)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#13, EE#16[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#12;EE#19[X#11,(var X#18)]}, A#17 |-> [.], C#8 |-> A#20[(app A#21[(var X#9)] C#22)], A#14 |-> A#20[(app A#21 C#22[(var X#9)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(\ X#10.S#13)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[(\ X#10.S#13)] C#22[(var X#9)])];X#9=(\ X#10.S#13);E#12;EE#19[X#11,(var X#18)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#18[(\ X#3.S#5)]) ;E#17 ;EE#16[X#11,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#18[(var X#2)]) ;E#17 ;EE#16[X#11,A#14[(\ X#10.C#18[(var X#2)])]] in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),(\ X#10.C#18)), ((var X#2),(\ X#10.C#18)), (S#5,(\ X#10.C#18)), ((var X#2),(\ X#10.C#18[[.]])), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, X#1 |-> X#9, E#4 |-> {E#17;EE#16[X#11,A#14[(var X#9)]]}, C#8 |-> (\ X#10.C#18), S#13 |-> C#18[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#18[(var X#2)]);E#17;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#18[(\ X#3.S#5)]);E#17;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#18[(var X#2)]);E#17;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#18[(var X#2)]);E#17;EE#16[X#11,A#14[(\ X#10.C#18[(var X#2)])]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#18 ;EE#16[X#11,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#18 ;EE#16[X#11,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#18}, E#17 |-> {X#1=C#8[(var X#2)];E#18}, E#4 |-> {X#9=(\ X#10.S#13);E#18;EE#16[X#11,A#14[(var X#9)]]}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#18;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#18;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#18;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#18;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#19[A#21[(app A#22[(var X#9)] C#23[(\ X#3.S#5)])]] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 in A#15[(var X#11)] ) , (letrec X#11= A#19[A#21[(app A#22[(\ X#10.S#13)] C#23[(var X#2)])]] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 in A#15[(var X#11)] ) ) where Delta1 = {C#20,A#18,C#8,A#14,A#19} Delta2 = {} Delta3 = {((\ X#3.S#5),A#19[A#21[(app A#22[(var X#9)] C#23)]]), ((var X#2),A#19[A#21[(app A#22[(var X#9)] C#23)]]), (S#5,A#19[A#21[(app A#22[(var X#9)] C#23)]]), ((var X#2),A#19[A#21[(app A#22[(var X#9)] C#23[[.]])]]), ((var X#9),A#21[(app A#22[[.]] C#23[(var X#2)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#13);E#17}, A#18 |-> A#19, C#8 |-> A#19[A#21[(app A#22[(var X#9)] C#23)]], C#20 |-> A#21[(app A#22[(var X#9)] C#23)], A#14 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#11=A#19[A#21[(app A#22[(var X#9)] C#23[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#19[A#21[(app A#22[(var X#9)] C#23[(\ X#3.S#5)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#19[A#21[(app A#22[(var X#9)] C#23[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#19[A#21[(app A#22[(\ X#10.S#13)] C#23[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#19[(app A#20[A#14[(var X#9)]] C#21[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 in A#15[(var X#11)] ) , (letrec X#11= A#19[(app A#20[A#14[(\ X#10.S#13)]] C#21[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 in A#15[(var X#11)] ) ) where Delta1 = {A#18,C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),A#19[(app A#20[A#14[(var X#9)]] C#21)]), ((var X#2),A#19[(app A#20[A#14[(var X#9)]] C#21)]), (S#5,A#19[(app A#20[A#14[(var X#9)]] C#21)]), ((var X#2),A#19[(app A#20[A#14[(var X#9)]] C#21[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] C#21[(var X#2)])]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#13);E#17}, C#8 |-> A#19[(app A#20[A#14[(var X#9)]] C#21)], A#18 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#11=A#19[(app A#20[A#14[(var X#9)]] C#21[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#19[(app A#20[A#14[(var X#9)]] C#21[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#19[(app A#20[A#14[(var X#9)]] C#21[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#19[(app A#20[A#14[(\ X#10.S#13)]] C#21[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#19[(app A#20[(var X#9)] C#21[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 in A#15[(var X#11)] ) , (letrec X#11= A#19[(app A#20[(\ X#10.S#13)] C#21[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),A#19[(app A#20[(var X#9)] C#21)]), ((var X#2),A#19[(app A#20[(var X#9)] C#21)]), (S#5,A#19[(app A#20[(var X#9)] C#21)]), ((var X#2),A#19[(app A#20[(var X#9)] C#21[[.]])]), ((var X#9),A#19[(app A#20[[.]] C#21[(var X#2)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#13);E#17}, A#18 |-> [.], C#8 |-> A#19[(app A#20[(var X#9)] C#21)], A#14 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#11=A#19[(app A#20[(var X#9)] C#21[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#19[(app A#20[(var X#9)] C#21[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#19[(app A#20[(var X#9)] C#21[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#19[(app A#20[(\ X#10.S#13)] C#21[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[(app A#22[(var X#19)] C#23[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#19,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#11= A#21[(app A#22[(var X#19)] C#23[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#19,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#18,C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[(app A#22[(var X#19)] C#23)]), ((var X#2),A#21[(app A#22[(var X#19)] C#23)]), (S#5,A#21[(app A#22[(var X#19)] C#23)]), ((var X#2),A#21[(app A#22[(var X#19)] C#23[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] C#23[(var X#2)])];EE#20[X#19,[.2]]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#13);E#17;EE#20[X#19,A#14[(var X#9)]]}, C#8 |-> A#21[(app A#22[(var X#19)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#11=A#21[(app A#22[(var X#19)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#19,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[(app A#22[(var X#19)] C#23[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#19,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#11=A#21[(app A#22[(var X#19)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#19,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#11=A#21[(app A#22[(var X#19)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#19,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#21[X#11,(var X#19)] ;EE#22[X#20,A#14[(var X#9)]] in A#15[(var X#11)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#21[X#11,(var X#19)] ;EE#22[X#20,A#14[(\ X#10.S#13)]] in A#15[(var X#11)] ) ) where Delta1 = {A#18,C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),A#23[(app A#24[(var X#20)] C#25)]), ((var X#2),A#23[(app A#24[(var X#20)] C#25)]), (S#5,A#23[(app A#24[(var X#20)] C#25)]), ((var X#2),A#23[(app A#24[(var X#20)] C#25[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#2)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#1 |-> X#19, E#4 |-> {X#9=(\ X#10.S#13);E#17;EE#21[X#11,(var X#19)];EE#22[X#20,A#14[(var X#9)]]}, C#8 |-> A#23[(app A#24[(var X#20)] C#25)], A#18 |-> A#23[(app A#24 C#25[(var X#2)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#21[X#11,(var X#19)];EE#22[X#20,A#14[(var X#9)]]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#21[X#11,(var X#19)];EE#22[X#20,A#14[(var X#9)]]} in A#15[(var X#11)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#21[X#11,(var X#19)];EE#22[X#20,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#21[X#11,(var X#19)];EE#22[X#20,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#9)] C#25[(\ X#3.S#5)])]] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#11,(var X#19)] in A#15[(var X#11)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#10.S#13)] C#25[(var X#2)])]] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#11,(var X#19)] in A#15[(var X#11)] ) ) where Delta1 = {C#22,A#18,C#8,A#14,A#21} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[A#23[(app A#24[(var X#9)] C#25)]]), ((var X#2),A#21[A#23[(app A#24[(var X#9)] C#25)]]), (S#5,A#21[A#23[(app A#24[(var X#9)] C#25)]]), ((var X#2),A#21[A#23[(app A#24[(var X#9)] C#25[[.]])]]), ((var X#9),A#23[(app A#24[[.]] C#25[(var X#2)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]}, A#18 |-> A#21, C#8 |-> A#21[A#23[(app A#24[(var X#9)] C#25)]], C#22 |-> A#23[(app A#24[(var X#9)] C#25)], A#14 |-> A#23[(app A#24 C#25[(var X#2)])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#9)] C#25[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#19=A#21[A#23[(app A#24[(var X#9)] C#25[(\ X#3.S#5)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#9)] C#25[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#10.S#13)] C#25[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#14[(var X#9)]] C#23[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#11,(var X#19)] in A#15[(var X#11)] ) , (letrec X#19= A#21[(app A#22[A#14[(\ X#10.S#13)]] C#23[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#11,(var X#19)] in A#15[(var X#11)] ) ) where Delta1 = {A#18,C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[(app A#22[A#14[(var X#9)]] C#23)]), ((var X#2),A#21[(app A#22[A#14[(var X#9)]] C#23)]), (S#5,A#21[(app A#22[A#14[(var X#9)]] C#23)]), ((var X#2),A#21[(app A#22[A#14[(var X#9)]] C#23[[.]])]), ((var X#9),A#14[[.]]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#2)])];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]}, C#8 |-> A#21[(app A#22[A#14[(var X#9)]] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#14[(var X#9)]] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#19=A#21[(app A#22[A#14[(var X#9)]] C#23[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#14[(var X#9)]] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[A#14[(\ X#10.S#13)]] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#9)] C#23[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#11,(var X#19)] in A#15[(var X#11)] ) , (letrec X#19= A#21[(app A#22[(\ X#10.S#13)] C#23[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#13) ;E#17 ;EE#20[X#11,(var X#19)] in A#15[(var X#11)] ) ) where Delta1 = {C#8,A#14} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[(app A#22[(var X#9)] C#23)]), ((var X#2),A#21[(app A#22[(var X#9)] C#23)]), (S#5,A#21[(app A#22[(var X#9)] C#23)]), ((var X#2),A#21[(app A#22[(var X#9)] C#23[[.]])]), ((var X#9),A#21[(app A#22[[.]] C#23[(var X#2)])]), ((var X#11),A#15[[.]]), ((var X#11),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(\ X#10.S#13)]]} in A#15[(var X#11)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#13);E#12;EE#16[X#11,A#14[(var X#9)]]} in A#15[(var X#11)])} Delta1= {A#14} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#11),A#15[[.]]),((var X#11),A#15[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#15[(var X#11)], E#12 |-> {X#2=(\ X#3.S#5);E#17}, EE#16[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]}, A#18 |-> [.], C#8 |-> A#21[(app A#22[(var X#9)] C#23)], A#14 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#9)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) <-cp-e1- (letrec {X#19=A#21[(app A#22[(var X#9)] C#23[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#9)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[(\ X#10.S#13)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#13);E#17;EE#20[X#11,(var X#19)]} in A#15[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#9= (\ X#10.S#14) ;E#13 ;EE#17[X#11,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#20[(app A#21[(var X#11)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec X#9= (\ X#10.S#14) ;E#13 ;EE#17[X#11,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#20[(app A#21[(var X#11)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#16,T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#20[(app A#21[[.]] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#20[(app A#21[[.]] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#20[(app A#21[(var X#11)] T#22)]), T#19 |-> A#20[(app A#21[(var X#11)] T#22)], A#16 |-> A#20[(app A#21 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#20[(app A#21[(var X#11)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#20[(app A#21[(var X#11)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#20[(app A#21[(var X#11)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#20[(app A#21[(var X#11)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#20= T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#14) ;E#22 ;EE#17[X#11,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#20= T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (\ X#10.S#14) ;E#22 ;EE#17[X#11,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=T#19;X#9=(\ X#10.S#14);E#22;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), E#13 |-> {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22}, E#21 |-> {X#9=(\ X#10.S#14);E#22;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}} and instantiated rules: (letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#14);E#22;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#20=T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#14);E#22;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#14);E#22;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(\ X#10.S#14);E#22;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#23[A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#23[A#25[(app A#26[(\ X#10.S#14)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {T#24,A#22,T#19,T#7,A#15,A#23} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#25[(app A#26[[.]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#23[A#25[(app A#26[(var X#12)] T#27)]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {[.1]=A#23[[.2]]}, X#20 |-> X#11, E#21 |-> {X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|}, A#22 |-> A#23, T#19 |-> A#23[A#25[(app A#26[(var X#12)] T#27)]], T#24 |-> A#25[(app A#26[(var X#12)] T#27)], A#15 |-> A#25[(app A#26 T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#23[A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#23[A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#23[A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#23[A#25[(app A#26[(\ X#10.S#14)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#23[(app A#24[A#15[(var X#12)]] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#23[(app A#24[A#15[(\ X#10.S#14)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#22,T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#23[(app A#24[A#15[(var X#12)]] T#25)];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {[.1]=A#23[(app A#24[[.2]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]}, X#20 |-> X#11, E#21 |-> {X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|}, T#19 |-> A#23[(app A#24[A#15[(var X#12)]] T#25)], A#22 |-> A#23[(app A#24 T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#23[(app A#24[A#15[(var X#12)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#23[(app A#24[A#15[(var X#12)]] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#23[(app A#24[A#15[(var X#12)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#23[(app A#24[A#15[(\ X#10.S#14)]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#23[(app A#24[(var X#12)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#23[(app A#24[(\ X#10.S#14)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#23[(app A#24[[.]] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#23[(app A#24[(var X#12)] T#25)];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {[.1]=[.2]}, X#20 |-> X#11, E#21 |-> {X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|}, A#22 |-> [.], T#19 |-> A#23[(app A#24[(var X#12)] T#25)], A#15 |-> A#23[(app A#24 T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#23[(app A#24[(var X#12)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#23[(app A#24[(var X#12)] T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#23[(app A#24[(var X#12)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#23[(app A#24[(\ X#10.S#14)] T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#23,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#23,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#22,T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#11=A#25[(app A#26[(var X#23)] T#27)];X#9=(\ X#10.S#14);E#13;EE#24[X#23,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {[.1]=A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#24[X#23,[.2]]}, X#20 |-> X#11, E#21 |-> {X#9=(\ X#10.S#14);E#13;EE#24[X#23,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, T#19 |-> A#25[(app A#26[(var X#23)] T#27)], A#22 |-> A#25[(app A#26 T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#11=A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#23,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#23,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#23,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#25[(app A#26[(var X#23)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#23,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#23= A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#25[X#11,(var X#23)] ;EE#26[X#24,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#23= A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#25[X#11,(var X#23)] ;EE#26[X#24,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#22,T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#23=A#27[(app A#28[(var X#24)] T#29)];X#9=(\ X#10.S#14);E#13;EE#25[X#11,(var X#23)];EE#26[X#24,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {X#23=A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#25[[.1],(var X#23)];EE#26[X#24,[.2]]}, X#20 |-> X#23, E#21 |-> {X#9=(\ X#10.S#14);E#13;EE#25[X#11,(var X#23)];EE#26[X#24,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, T#19 |-> A#27[(app A#28[(var X#24)] T#29)], A#22 |-> A#27[(app A#28 T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#23=A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#25[X#11,(var X#23)];EE#26[X#24,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#23=A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#25[X#11,(var X#23)];EE#26[X#24,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#23=A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#25[X#11,(var X#23)];EE#26[X#24,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#23=A#27[(app A#28[(var X#24)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#25[X#11,(var X#23)];EE#26[X#24,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#23= A#25[A#27[(app A#28[(var X#12)] T#29[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#11,(var X#23)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#23= A#25[A#27[(app A#28[(\ X#10.S#14)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#11,(var X#23)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {T#26,A#22,T#19,T#7,A#15,A#25} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#27[(app A#28[[.]] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#23=A#25[A#27[(app A#28[(var X#12)] T#29)]];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {X#23=A#25[[.2]];EE#24[[.1],(var X#23)]}, X#20 |-> X#23, E#21 |-> {X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|}, A#22 |-> A#25, T#19 |-> A#25[A#27[(app A#28[(var X#12)] T#29)]], T#26 |-> A#27[(app A#28[(var X#12)] T#29)], A#15 |-> A#27[(app A#28 T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#23=A#25[A#27[(app A#28[(var X#12)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#23=A#25[A#27[(app A#28[(var X#12)] T#29[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#23=A#25[A#27[(app A#28[(var X#12)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#23=A#25[A#27[(app A#28[(\ X#10.S#14)] T#29[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#23= A#25[(app A#26[A#15[(var X#12)]] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#11,(var X#23)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#23= A#25[(app A#26[A#15[(\ X#10.S#14)]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#11,(var X#23)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#22,T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#23=A#25[(app A#26[A#15[(var X#12)]] T#27)];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {X#23=A#25[(app A#26[[.2]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#24[[.1],(var X#23)]}, X#20 |-> X#23, E#21 |-> {X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|}, T#19 |-> A#25[(app A#26[A#15[(var X#12)]] T#27)], A#22 |-> A#25[(app A#26 T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#23=A#25[(app A#26[A#15[(var X#12)]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#23=A#25[(app A#26[A#15[(var X#12)]] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#23=A#25[(app A#26[A#15[(var X#12)]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#23=A#25[(app A#26[A#15[(\ X#10.S#14)]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#23= A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#11,(var X#23)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#23= A#25[(app A#26[(\ X#10.S#14)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#24[X#11,(var X#23)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {T#19,T#7,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#25[(app A#26[[.]] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#23=A#25[(app A#26[(var X#12)] T#27)];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]), EE#17[.1,.2] |-> {X#23=[.2];EE#24[[.1],(var X#23)]}, X#20 |-> X#23, E#21 |-> {X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|}, A#22 |-> [.], T#19 |-> A#25[(app A#26[(var X#12)] T#27)], A#15 |-> A#25[(app A#26 T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#23=A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#23=A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#23=A#25[(app A#26[(var X#12)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#23=A#25[(app A#26[(\ X#10.S#14)] T#27[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(\ X#10.S#14);E#13;EE#24[X#11,(var X#23)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#10.S#14)] ;X#9= (\ X#10.S#14) ;E#19 ;EE#17[X#11,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#1= C#8[(var X#9)] ;X#9= (\ X#10.S#14) ;E#19 ;EE#17[X#11,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),C#8), ((var X#9),C#8), (S#14,C#8), ((var X#9),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, E#13 |-> {X#1=C#8[(var X#9)];E#19}, E#4 |-> {E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}} and instantiated rules: (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#14);E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#10.S#14)];X#9=(\ X#10.S#14);E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#14);E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#1=C#8[(var X#9)];X#9=(\ X#10.S#14);E#19;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#12= (\ X#10.S#14) ;X#9= (\ X#10.S#14) ;E#13 ;EE#17[X#11,A#15[(var X#12)]] in A#16[(var X#11)] ) , (letrec X#12= (var X#9) ;X#9= (\ X#10.S#14) ;E#13 ;EE#17[X#11,A#15[(\ X#10.S#14)]] in A#16[(var X#11)] ) ) where Delta1 = {A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),[.]), ((var X#9),[.]), (S#14,[.]), ((var X#9),[.]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, VV#18|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#12, E#4 |-> {E#13;EE#17[X#11,A#15[(var X#12)]]}, C#8 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#12=(var X#9);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]]} in A#16[(var X#11)]) <-cp-e1- (letrec {X#12=(\ X#10.S#14);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]]} in A#16[(var X#11)]) ................................................................................ (letrec {X#12=(var X#9);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]]} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#12=(var X#9);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]]} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#20= (\ X#10.S#14) ;X#9= (\ X#10.S#14) ;E#13 ;EE#17[X#11,A#15[(var X#12)]] ;VV#21|X#12,(var X#20)| in A#16[(var X#11)] ) , (letrec X#20= (var X#9) ;X#9= (\ X#10.S#14) ;E#13 ;EE#17[X#11,A#15[(\ X#10.S#14)]] ;VV#21|X#12,(var X#20)| in A#16[(var X#11)] ) ) where Delta1 = {A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),[.]), ((var X#9),[.]), (S#14,[.]), ((var X#9),[.]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, VV#18|.1,.2| |-> {X#20=[.2];VV#21|[.1],(var X#20)|}, X#1 |-> X#20, E#4 |-> {E#13;EE#17[X#11,A#15[(var X#12)]];VV#21|X#12,(var X#20)|}, C#8 |-> [.], X#9 |-> X#9} and instantiated rules: (letrec {X#20=(var X#9);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#21|X#12,(var X#20)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#20=(\ X#10.S#14);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#21|X#12,(var X#20)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#20=(var X#9);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#21|X#12,(var X#20)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#20=(var X#9);X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#21|X#12,(var X#20)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#20[A#22[(app A#23[(var X#12)] C#24[(\ X#10.S#14)])]] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#20[A#22[(app A#23[(\ X#10.S#14)] C#24[(var X#9)])]] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#21,A#19,C#8,A#15,A#20} Delta2 = {} Delta3 = {((\ X#10.S#14),A#20[A#22[(app A#23[(var X#12)] C#24)]]), ((var X#9),A#20[A#22[(app A#23[(var X#12)] C#24)]]), (S#14,A#20[A#22[(app A#23[(var X#12)] C#24)]]), ((var X#9),A#20[A#22[(app A#23[(var X#12)] C#24[[.]])]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#22[(app A#23[[.]] C#24[(var X#9)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#11, E#4 |-> {E#13;VV#18|X#12,(var X#9)|}, A#19 |-> A#20, C#8 |-> A#20[A#22[(app A#23[(var X#12)] C#24)]], C#21 |-> A#22[(app A#23[(var X#12)] C#24)], A#15 |-> A#22[(app A#23 C#24[(var X#9)])]} and instantiated rules: (letrec {X#11=A#20[A#22[(app A#23[(var X#12)] C#24[(var X#9)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#20[A#22[(app A#23[(var X#12)] C#24[(\ X#10.S#14)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#20[A#22[(app A#23[(var X#12)] C#24[(var X#9)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#20[A#22[(app A#23[(\ X#10.S#14)] C#24[(var X#9)])]];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#20[(app A#21[A#15[(var X#12)]] C#22[(\ X#10.S#14)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#20[(app A#21[A#15[(\ X#10.S#14)]] C#22[(var X#9)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#19,C#8,A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),A#20[(app A#21[A#15[(var X#12)]] C#22)]), ((var X#9),A#20[(app A#21[A#15[(var X#12)]] C#22)]), (S#14,A#20[(app A#21[A#15[(var X#12)]] C#22)]), ((var X#9),A#20[(app A#21[A#15[(var X#12)]] C#22[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] C#22[(var X#9)])]}, X#1 |-> X#11, E#4 |-> {E#13;VV#18|X#12,(var X#9)|}, C#8 |-> A#20[(app A#21[A#15[(var X#12)]] C#22)], A#19 |-> A#20[(app A#21 C#22[(var X#9)])]} and instantiated rules: (letrec {X#11=A#20[(app A#21[A#15[(var X#12)]] C#22[(var X#9)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#20[(app A#21[A#15[(var X#12)]] C#22[(\ X#10.S#14)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#20[(app A#21[A#15[(var X#12)]] C#22[(var X#9)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#20[(app A#21[A#15[(\ X#10.S#14)]] C#22[(var X#9)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#20[(app A#21[(var X#12)] C#22[(\ X#10.S#14)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#20[(app A#21[(\ X#10.S#14)] C#22[(var X#9)])] ;X#9= (\ X#10.S#14) ;E#13 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#8,A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),A#20[(app A#21[(var X#12)] C#22)]), ((var X#9),A#20[(app A#21[(var X#12)] C#22)]), (S#14,A#20[(app A#21[(var X#12)] C#22)]), ((var X#9),A#20[(app A#21[(var X#12)] C#22[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#20[(app A#21[[.]] C#22[(var X#9)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {E#13;VV#18|X#12,(var X#9)|}, A#19 |-> [.], C#8 |-> A#20[(app A#21[(var X#12)] C#22)], A#15 |-> A#20[(app A#21 C#22[(var X#9)])]} and instantiated rules: (letrec {X#11=A#20[(app A#21[(var X#12)] C#22[(var X#9)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#20[(app A#21[(var X#12)] C#22[(\ X#10.S#14)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#20[(app A#21[(var X#12)] C#22[(var X#9)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#20[(app A#21[(\ X#10.S#14)] C#22[(var X#9)])];X#9=(\ X#10.S#14);E#13;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#22[(app A#23[(var X#20)] C#24[(\ X#10.S#14)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#20,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#22[(app A#23[(var X#20)] C#24[(var X#9)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#20,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#19,C#8,A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),A#22[(app A#23[(var X#20)] C#24)]), ((var X#9),A#22[(app A#23[(var X#20)] C#24)]), (S#14,A#22[(app A#23[(var X#20)] C#24)]), ((var X#9),A#22[(app A#23[(var X#20)] C#24[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] C#24[(var X#9)])];EE#21[X#20,[.2]]}, X#1 |-> X#11, E#4 |-> {E#13;EE#21[X#20,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, C#8 |-> A#22[(app A#23[(var X#20)] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#9)])]} and instantiated rules: (letrec {X#11=A#22[(app A#23[(var X#20)] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#20,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#22[(app A#23[(var X#20)] C#24[(\ X#10.S#14)])];X#9=(\ X#10.S#14);E#13;EE#21[X#20,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#22[(app A#23[(var X#20)] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#20,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#22[(app A#23[(var X#20)] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#20,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] C#26[(\ X#10.S#14)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#22[X#11,(var X#20)] ;EE#23[X#21,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] C#26[(var X#9)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#22[X#11,(var X#20)] ;EE#23[X#21,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#19,C#8,A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),A#24[(app A#25[(var X#21)] C#26)]), ((var X#9),A#24[(app A#25[(var X#21)] C#26)]), (S#14,A#24[(app A#25[(var X#21)] C#26)]), ((var X#9),A#24[(app A#25[(var X#21)] C#26[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#9)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#1 |-> X#20, E#4 |-> {E#13;EE#22[X#11,(var X#20)];EE#23[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, C#8 |-> A#24[(app A#25[(var X#21)] C#26)], A#19 |-> A#24[(app A#25 C#26[(var X#9)])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#22[X#11,(var X#20)];EE#23[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#20=A#24[(app A#25[(var X#21)] C#26[(\ X#10.S#14)])];X#9=(\ X#10.S#14);E#13;EE#22[X#11,(var X#20)];EE#23[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#22[X#11,(var X#20)];EE#23[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#22[X#11,(var X#20)];EE#23[X#21,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(app A#25[(var X#12)] C#26[(\ X#10.S#14)])]] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#11,(var X#20)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#20= A#22[A#24[(app A#25[(\ X#10.S#14)] C#26[(var X#9)])]] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#11,(var X#20)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#23,A#19,C#8,A#15,A#22} Delta2 = {} Delta3 = {((\ X#10.S#14),A#22[A#24[(app A#25[(var X#12)] C#26)]]), ((var X#9),A#22[A#24[(app A#25[(var X#12)] C#26)]]), (S#14,A#22[A#24[(app A#25[(var X#12)] C#26)]]), ((var X#9),A#22[A#24[(app A#25[(var X#12)] C#26[[.]])]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#24[(app A#25[[.]] C#26[(var X#9)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|}, A#19 |-> A#22, C#8 |-> A#22[A#24[(app A#25[(var X#12)] C#26)]], C#23 |-> A#24[(app A#25[(var X#12)] C#26)], A#15 |-> A#24[(app A#25 C#26[(var X#9)])]} and instantiated rules: (letrec {X#20=A#22[A#24[(app A#25[(var X#12)] C#26[(var X#9)])]];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#20=A#22[A#24[(app A#25[(var X#12)] C#26[(\ X#10.S#14)])]];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#20=A#22[A#24[(app A#25[(var X#12)] C#26[(var X#9)])]];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#20=A#22[A#24[(app A#25[(\ X#10.S#14)] C#26[(var X#9)])]];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[A#15[(var X#12)]] C#24[(\ X#10.S#14)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#11,(var X#20)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#20= A#22[(app A#23[A#15[(\ X#10.S#14)]] C#24[(var X#9)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#11,(var X#20)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#19,C#8,A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),A#22[(app A#23[A#15[(var X#12)]] C#24)]), ((var X#9),A#22[(app A#23[A#15[(var X#12)]] C#24)]), (S#14,A#22[(app A#23[A#15[(var X#12)]] C#24)]), ((var X#9),A#22[(app A#23[A#15[(var X#12)]] C#24[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] C#24[(var X#9)])];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|}, C#8 |-> A#22[(app A#23[A#15[(var X#12)]] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#9)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[A#15[(var X#12)]] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#20=A#22[(app A#23[A#15[(var X#12)]] C#24[(\ X#10.S#14)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#20=A#22[(app A#23[A#15[(var X#12)]] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#20=A#22[(app A#23[A#15[(\ X#10.S#14)]] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#12)] C#24[(\ X#10.S#14)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#11,(var X#20)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#20= A#22[(app A#23[(\ X#10.S#14)] C#24[(var X#9)])] ;X#9= (\ X#10.S#14) ;E#13 ;EE#21[X#11,(var X#20)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#8,A#15} Delta2 = {} Delta3 = {((\ X#10.S#14),A#22[(app A#23[(var X#12)] C#24)]), ((var X#9),A#22[(app A#23[(var X#12)] C#24)]), (S#14,A#22[(app A#23[(var X#12)] C#24)]), ((var X#9),A#22[(app A#23[(var X#12)] C#24[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#22[(app A#23[[.]] C#24[(var X#9)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], X#2 |-> X#9, X#3 |-> X#10, S#5 |-> S#14, EE#17[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|}, A#19 |-> [.], C#8 |-> A#22[(app A#23[(var X#12)] C#24)], A#15 |-> A#22[(app A#23 C#24[(var X#9)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(var X#12)] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#20=A#22[(app A#23[(var X#12)] C#24[(\ X#10.S#14)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(var X#12)] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#20=A#22[(app A#23[(\ X#10.S#14)] C#24[(var X#9)])];X#9=(\ X#10.S#14);E#13;EE#21[X#11,(var X#20)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#20[(\ X#3.S#5)]) ;E#19 ;EE#17[X#11,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (\ X#10.C#20[(var X#2)]) ;E#19 ;EE#17[X#11,A#15[(\ X#10.C#20[(var X#2)])]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),(\ X#10.C#20)), ((var X#2),(\ X#10.C#20)), (S#5,(\ X#10.C#20)), ((var X#2),(\ X#10.C#20[[.]])), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, X#1 |-> X#9, E#4 |-> {E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, C#8 |-> (\ X#10.C#20), S#14 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#20[(var X#2)]);E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#20[(\ X#3.S#5)]);E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#20[(var X#2)]);E#19;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#2=(\ X#3.S#5);X#9=(\ X#10.C#20[(var X#2)]);E#19;EE#17[X#11,A#15[(\ X#10.C#20[(var X#2)])]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#20 ;EE#17[X#11,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#20 ;EE#17[X#11,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#20}, E#19 |-> {X#1=C#8[(var X#2)];E#20}, E#4 |-> {X#9=(\ X#10.S#14);E#20;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#20;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#20;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#20;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#20;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[A#23[(app A#24[(var X#12)] C#25[(\ X#3.S#5)])]] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#21[A#23[(app A#24[(\ X#10.S#14)] C#25[(var X#2)])]] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#22,A#20,C#8,A#15,A#21} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[A#23[(app A#24[(var X#12)] C#25)]]), ((var X#2),A#21[A#23[(app A#24[(var X#12)] C#25)]]), (S#5,A#21[A#23[(app A#24[(var X#12)] C#25)]]), ((var X#2),A#21[A#23[(app A#24[(var X#12)] C#25[[.]])]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#23[(app A#24[[.]] C#25[(var X#2)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|}, A#20 |-> A#21, C#8 |-> A#21[A#23[(app A#24[(var X#12)] C#25)]], C#22 |-> A#23[(app A#24[(var X#12)] C#25)], A#15 |-> A#23[(app A#24 C#25[(var X#2)])]} and instantiated rules: (letrec {X#11=A#21[A#23[(app A#24[(var X#12)] C#25[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[A#23[(app A#24[(var X#12)] C#25[(\ X#3.S#5)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#21[A#23[(app A#24[(var X#12)] C#25[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#21[A#23[(app A#24[(\ X#10.S#14)] C#25[(var X#2)])]];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[(app A#22[A#15[(var X#12)]] C#23[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#21[(app A#22[A#15[(\ X#10.S#14)]] C#23[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#20,C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[(app A#22[A#15[(var X#12)]] C#23)]), ((var X#2),A#21[(app A#22[A#15[(var X#12)]] C#23)]), (S#5,A#21[(app A#22[A#15[(var X#12)]] C#23)]), ((var X#2),A#21[(app A#22[A#15[(var X#12)]] C#23[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#2)])]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|}, C#8 |-> A#21[(app A#22[A#15[(var X#12)]] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#11=A#21[(app A#22[A#15[(var X#12)]] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[(app A#22[A#15[(var X#12)]] C#23[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#21[(app A#22[A#15[(var X#12)]] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#21[(app A#22[A#15[(\ X#10.S#14)]] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#21[(app A#22[(var X#12)] C#23[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#21[(app A#22[(\ X#10.S#14)] C#23[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),A#21[(app A#22[(var X#12)] C#23)]), ((var X#2),A#21[(app A#22[(var X#12)] C#23)]), (S#5,A#21[(app A#22[(var X#12)] C#23)]), ((var X#2),A#21[(app A#22[(var X#12)] C#23[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#21[(app A#22[[.]] C#23[(var X#2)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|}, A#20 |-> [.], C#8 |-> A#21[(app A#22[(var X#12)] C#23)], A#15 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#11=A#21[(app A#22[(var X#12)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#21[(app A#22[(var X#12)] C#23[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#21[(app A#22[(var X#12)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#21[(app A#22[(\ X#10.S#14)] C#23[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#11= A#23[(app A#24[(var X#21)] C#25[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#21,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#11= A#23[(app A#24[(var X#21)] C#25[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#21,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#20,C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),A#23[(app A#24[(var X#21)] C#25)]), ((var X#2),A#23[(app A#24[(var X#21)] C#25)]), (S#5,A#23[(app A#24[(var X#21)] C#25)]), ((var X#2),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#2)])];EE#22[X#21,[.2]]}, X#1 |-> X#11, E#4 |-> {X#9=(\ X#10.S#14);E#19;EE#22[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, C#8 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#2)])]} and instantiated rules: (letrec {X#11=A#23[(app A#24[(var X#21)] C#25[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;EE#22[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#11=A#23[(app A#24[(var X#21)] C#25[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;EE#22[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#11=A#23[(app A#24[(var X#21)] C#25[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;EE#22[X#21,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#11=A#23[(app A#24[(var X#21)] C#25[(var X#2)])];X#2=(\ X#3.S#5);X#9=(\ X#10.S#14);E#19;EE#22[X#21,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#21= A#25[(app A#26[(var X#22)] C#27[(\ X#3.S#5)])] ;X#9= (\ X#10.S#14) ;E#19 ;EE#23[X#11,(var X#21)] ;EE#24[X#22,A#15[(var X#12)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#2)])] ;X#9= (\ X#10.S#14) ;E#19 ;EE#23[X#11,(var X#21)] ;EE#24[X#22,A#15[(\ X#10.S#14)]] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#20,C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),A#25[(app A#26[(var X#22)] C#27)]), ((var X#2),A#25[(app A#26[(var X#22)] C#27)]), (S#5,A#25[(app A#26[(var X#22)] C#27)]), ((var X#2),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#2)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {X#9=(\ X#10.S#14);E#19;EE#23[X#11,(var X#21)];EE#24[X#22,A#15[(var X#12)]];VV#18|X#12,(var X#9)|}, C#8 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#23[X#11,(var X#21)];EE#24[X#22,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#21=A#25[(app A#26[(var X#22)] C#27[(\ X#3.S#5)])];X#9=(\ X#10.S#14);E#19;EE#23[X#11,(var X#21)];EE#24[X#22,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#23[X#11,(var X#21)];EE#24[X#22,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#2=(\ X#3.S#5);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#23[X#11,(var X#21)];EE#24[X#22,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#21= A#23[A#25[(app A#26[(var X#12)] C#27[(\ X#3.S#5)])]] ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#11,(var X#21)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#21= A#23[A#25[(app A#26[(\ X#10.S#14)] C#27[(var X#2)])]] ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#11,(var X#21)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#24,A#20,C#8,A#15,A#23} Delta2 = {} Delta3 = {((\ X#3.S#5),A#23[A#25[(app A#26[(var X#12)] C#27)]]), ((var X#2),A#23[A#25[(app A#26[(var X#12)] C#27)]]), (S#5,A#23[A#25[(app A#26[(var X#12)] C#27)]]), ((var X#2),A#23[A#25[(app A#26[(var X#12)] C#27[[.]])]]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#25[(app A#26[[.]] C#27[(var X#2)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|}, A#20 |-> A#23, C#8 |-> A#23[A#25[(app A#26[(var X#12)] C#27)]], C#24 |-> A#25[(app A#26[(var X#12)] C#27)], A#15 |-> A#25[(app A#26 C#27[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#21=A#23[A#25[(app A#26[(var X#12)] C#27[(var X#2)])]];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#21=A#23[A#25[(app A#26[(var X#12)] C#27[(\ X#3.S#5)])]];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#21=A#23[A#25[(app A#26[(var X#12)] C#27[(var X#2)])]];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#2=(\ X#3.S#5);X#21=A#23[A#25[(app A#26[(\ X#10.S#14)] C#27[(var X#2)])]];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#21= A#23[(app A#24[A#15[(var X#12)]] C#25[(\ X#3.S#5)])] ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#11,(var X#21)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#21= A#23[(app A#24[A#15[(\ X#10.S#14)]] C#25[(var X#2)])] ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#11,(var X#21)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {A#20,C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),A#23[(app A#24[A#15[(var X#12)]] C#25)]), ((var X#2),A#23[(app A#24[A#15[(var X#12)]] C#25)]), (S#5,A#23[(app A#24[A#15[(var X#12)]] C#25)]), ((var X#2),A#23[(app A#24[A#15[(var X#12)]] C#25[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#15[[.]]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#2)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|}, C#8 |-> A#23[(app A#24[A#15[(var X#12)]] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[A#15[(var X#12)]] C#25[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[A#15[(var X#12)]] C#25[(\ X#3.S#5)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[A#15[(var X#12)]] C#25[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[A#15[(\ X#10.S#14)]] C#25[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#21= A#23[(app A#24[(var X#12)] C#25[(\ X#3.S#5)])] ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#11,(var X#21)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) , (letrec X#2= (\ X#3.S#5) ;X#21= A#23[(app A#24[(\ X#10.S#14)] C#25[(var X#2)])] ;X#9= (\ X#10.S#14) ;E#19 ;EE#22[X#11,(var X#21)] ;VV#18|X#12,(var X#9)| in A#16[(var X#11)] ) ) where Delta1 = {C#8,A#15} Delta2 = {} Delta3 = {((\ X#3.S#5),A#23[(app A#24[(var X#12)] C#25)]), ((var X#2),A#23[(app A#24[(var X#12)] C#25)]), (S#5,A#23[(app A#24[(var X#12)] C#25)]), ((var X#2),A#23[(app A#24[(var X#12)] C#25[[.]])]), ((var X#9),[.]), ((var X#11),A#16[[.]]), ((var X#12),A#23[(app A#24[[.]] C#25[(var X#2)])]), ((var X#9),[.]), ((var X#11),A#16[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(\ X#10.S#14)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) and constraints: A#15/= [.] and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(\ X#10.S#14);E#13;EE#17[X#11,A#15[(var X#12)]];VV#18|X#12,(var X#9)|} in A#16[(var X#11)])} Delta1= {A#15} Delta2= {} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#2),C#8[[.]]),((var X#9),[.]),((var X#11),A#16[[.]]),((var X#12),A#15[[.]]),((var X#9),[.]),((var X#11),A#16[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#16[(var X#11)], E#13 |-> {X#2=(\ X#3.S#5);E#19}, EE#17[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|}, A#20 |-> [.], C#8 |-> A#23[(app A#24[(var X#12)] C#25)], A#15 |-> A#23[(app A#24 C#25[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[(var X#12)] C#25[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[(var X#12)] C#25[(\ X#3.S#5)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[(var X#12)] C#25[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) -SR,cp-e2-> (letrec {X#2=(\ X#3.S#5);X#21=A#23[(app A#24[(\ X#10.S#14)] C#25[(var X#2)])];X#9=(\ X#10.S#14);E#19;EE#22[X#11,(var X#21)];VV#18|X#12,(var X#9)|} in A#16[(var X#11)]) ================================================================================ Critical Pair: ( (letrec E#9 in (letrec E#10 in T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) ) , (letrec E#10 ;E#9 in T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ) ) where Delta1 = {T#12,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), [{E#9},(letrec {E#10} in [.])], ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {E#10;E#9} in S#11) and constraints: E#9/= {}, E#10/= {}, ({E#9},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in (letrec {E#10} in S#11))} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),[{E#9},(letrec {E#10} in [.])],((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in (letrec {E#10} in T#13)), T#12 |-> (letrec {E#10} in T#13), S#11 |-> T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#9} in (letrec {E#10} in T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) <-cp-e1- (letrec {E#9} in (letrec {E#10} in T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])) ................................................................................ (letrec {E#9} in (letrec {E#10} in T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) -SR,llet-in1-> (letrec {E#10;E#9} in T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) ================================================================================ Critical Pair: ( (letrec E#9 in (letrec X#14= T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#16 in S#11 ) ) , (letrec X#14= T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#16 ;E#9 in S#11 ) ) where Delta1 = {T#12,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), [{E#9},(letrec {X#14=T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#16} in [.])], ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {E#10;E#9} in S#11) and constraints: E#9/= {}, E#10/= {}, ({E#9},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in (letrec {E#10} in S#11))} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),[{E#9},(letrec {E#10} in [.])],((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in (letrec {X#14=T#13;E#16} in S#11)), T#12 |-> (letrec {X#14=T#13;E#16} in S#11), E#10 |-> {X#14=T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {E#9} in (letrec {X#14=T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#16} in S#11)) <-cp-e1- (letrec {E#9} in (letrec {X#14=T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#16} in S#11)) ................................................................................ (letrec {E#9} in (letrec {X#14=T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#16} in S#11)) -SR,llet-in1-> (letrec {X#14=T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#16;E#9} in S#11) ================================================================================ Critical Pair: ( (letrec {E#9} in (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#14} in S#11)) , (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#14;E#9} in S#11) ) where Delta1 = {T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), [{E#9},(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#14} in [.])], ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {E#10;E#9} in S#11) and constraints: E#9/= {}, E#10/= {}, ({E#9},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in (letrec {E#10} in S#11))} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),[{E#9},(letrec {E#10} in [.])],((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in [.]), T#12 |-> [.], S#6 |-> S#11, E#10 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#14}, E#13 |-> {X#1=C#8[(var X#2)];E#14}, E#4 |-> {E#14}} and instantiated rules: (letrec {E#9} in (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#14} in S#11)) <-cp-e1- (letrec {E#9} in (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#14} in S#11)) ................................................................................ (letrec {E#9} in (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#14} in S#11)) -SR,llet-in1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#14;E#9} in S#11) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#15 in (letrec {E#10} in S#11) ) , (letrec X#13= T#12[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#10 ;E#15 in S#11 ) ) where Delta1 = {T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), [{X#13=T#12[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#15},(letrec {E#10} in [.])], ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {E#10;E#9} in S#11) and constraints: E#9/= {}, E#10/= {}, ({E#9},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in (letrec {E#10} in S#11))} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),[{E#9},(letrec {E#10} in [.])],((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#13=T#12;E#15} in (letrec {E#10} in S#11)), E#9 |-> {X#13=T#12[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#15} in (letrec {E#10} in S#11)) <-cp-e1- (letrec {X#13=T#12[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#15} in (letrec {E#10} in S#11)) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#15} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {X#13=T#12[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#10;E#15} in S#11) ================================================================================ Critical Pair: ( (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#13} in (letrec {E#10} in S#11)) , (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#10;E#13} in S#11) ) where Delta1 = {} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), [{X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#13},(letrec {E#10} in [.])], ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {E#10;E#9} in S#11) and constraints: E#9/= {}, E#10/= {}, ({E#9},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in (letrec {E#10} in S#11))} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),[{E#9},(letrec {E#10} in [.])],((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> (letrec {E#10} in S#11), E#9 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#13}, E#12 |-> {X#1=C#8[(var X#2)];E#13}, E#4 |-> {E#13}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#13} in (letrec {E#10} in S#11)) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#13} in (letrec {E#10} in S#11)) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#13} in (letrec {E#10} in S#11)) -SR,llet-in1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#10;E#13} in S#11) ================================================================================ Critical Pair: ( (letrec X#9= (letrec {E#10} in S#12) ;E#11 in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec X#9= S#12 ;E#10 ;E#11 in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#13,T#14,T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])],(letrec {E#10} in [.])), [{E#11},(letrec {E#10} in [.])], ((var X#2),C#8[[.]]), ((var X#9),A#15[(app A#16[[.]] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),A#15[(app A#16[[.]] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#15[(app A#16[(var X#9)] T#17)]), T#14 |-> A#15[(app A#16[(var X#9)] T#17)], A#13 |-> A#15[(app A#16 T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec E#10 in T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) ;E#11 in A#13[(var X#9)] ) , (letrec X#9= T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {T#14,T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (A#13[(var X#9)],(letrec {E#10} in [.])), [{E#11},(letrec {E#10} in [.])], ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(letrec {E#10} in T#17);E#11} in A#13[(var X#9)]), X#15 |-> X#9, E#16 |-> {E#11}, T#14 |-> (letrec {E#10} in T#17), S#12 |-> T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=(letrec {E#10} in T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11} in A#13[(var X#9)]) <-cp-e1- (letrec {X#9=(letrec {E#10} in T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#9=(letrec {E#10} in T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec X#18= T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#20 in S#12 ) ;E#11 in A#13[(var X#9)] ) , (letrec X#18= T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= S#12 ;E#11 ;E#20 in A#13[(var X#9)] ) ) where Delta1 = {T#14,T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (A#13[(var X#9)],(letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20} in [.])), [{E#11},(letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20} in [.])], ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(letrec {X#18=T#17;E#20} in S#12);E#11} in A#13[(var X#9)]), X#15 |-> X#9, E#16 |-> {E#11}, T#14 |-> (letrec {X#18=T#17;E#20} in S#12), E#10 |-> {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#9=(letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20} in S#12);E#11} in A#13[(var X#9)]) <-cp-e1- (letrec {X#9=(letrec {X#18=T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20} in S#12);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#9=(letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#20} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#18=T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=S#12;E#11;E#20} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#18} in S#12) ;E#11 in A#13[(var X#9)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= S#12 ;E#11 ;E#18 in A#13[(var X#9)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (A#13[(var X#9)],(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#18} in [.])), [{E#11},(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#18} in [.])], ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=[.];E#11} in A#13[(var X#9)]), X#15 |-> X#9, E#16 |-> {E#11}, T#14 |-> [.], S#6 |-> S#12, E#10 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#18}, E#17 |-> {X#1=C#8[(var X#2)];E#18}, E#4 |-> {E#18}} and instantiated rules: (letrec {X#9=(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#18} in S#12);E#11} in A#13[(var X#9)]) <-cp-e1- (letrec {X#9=(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#18} in S#12);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#9=(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#18} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=S#12;E#11;E#18} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (letrec {E#10} in S#12) ;E#17 in A#13[(var X#9)] ) , (letrec X#15= T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= S#12 ;E#10 ;E#17 in A#13[(var X#9)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17},(letrec {E#10} in [.])], ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#15=T#14;X#9=(letrec {E#10} in S#12);E#17} in A#13[(var X#9)]), E#11 |-> {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17}, E#16 |-> {X#9=(letrec {E#10} in S#12);E#17}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(letrec {E#10} in S#12);E#17} in A#13[(var X#9)]) <-cp-e1- (letrec {X#15=T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(letrec {E#10} in S#12);E#17} in A#13[(var X#9)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(letrec {E#10} in S#12);E#17} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=S#12;E#10;E#17} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {E#10} in C#15[(\ X#3.S#5)]) ;E#14 in A#13[(var X#9)] ) , (letrec {X#2=(\ X#3.S#5);X#9=C#15[(var X#2)];E#10;E#14} in A#13[(var X#9)]) ) where Delta1 = {C#8} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),(letrec {E#10} in C#15)), ((var X#2),(letrec {E#10} in C#15)), (S#5,(letrec {E#10} in C#15)), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=(\ X#3.S#5);E#14},(letrec {E#10} in [.])], ((var X#2),(letrec {E#10} in C#15[[.]])), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#14}, X#1 |-> X#9, E#4 |-> {E#14}, C#8 |-> (letrec {E#10} in C#15), S#12 |-> C#15[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#10} in C#15[(var X#2)]);E#14} in A#13[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#10} in C#15[(\ X#3.S#5)]);E#14} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#10} in C#15[(var X#2)]);E#14} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#2=(\ X#3.S#5);X#9=C#15[(var X#2)];E#10;E#14} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {X#16=C#15[(\ X#3.S#5)];E#18} in S#12) ;E#14 in A#13[(var X#9)] ) , (letrec X#16= C#15[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= S#12 ;E#14 ;E#18 in A#13[(var X#9)] ) ) where Delta1 = {C#8} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),(letrec {X#16=C#15;E#18} in S#12)), ((var X#2),(letrec {X#16=C#15;E#18} in S#12)), (S#5,(letrec {X#16=C#15;E#18} in S#12)), (A#13[(var X#9)],(letrec {X#16=C#15[(var X#2)];E#18} in [.])), [{X#2=(\ X#3.S#5);E#14},(letrec {X#16=C#15[(var X#2)];E#18} in [.])], ((var X#2),(letrec {X#16=C#15[[.]];E#18} in S#12)), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(var X#9)], E#11 |-> {X#2=(\ X#3.S#5);E#14}, X#1 |-> X#9, E#4 |-> {E#14}, C#8 |-> (letrec {X#16=C#15;E#18} in S#12), E#10 |-> {X#16=C#15[(var X#2)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#16=C#15[(var X#2)];E#18} in S#12);E#14} in A#13[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#16=C#15[(\ X#3.S#5)];E#18} in S#12);E#14} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#16=C#15[(var X#2)];E#18} in S#12);E#14} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#16=C#15[(var X#2)];X#2=(\ X#3.S#5);X#9=S#12;E#14;E#18} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;X#9= (letrec {E#10} in S#12) ;E#15 in A#13[(var X#9)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= S#12 ;E#10 ;E#15 in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15},(letrec {E#10} in [.])], ((var X#2),C#8[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#9=S#12;E#10;E#11} in A#13[(var X#9)]) and constraints: E#10/= {}, (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11},(letrec {E#10} in [.])],((var X#2),C#8[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(var X#9)], E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15}, E#14 |-> {X#1=C#8[(var X#2)];E#15}, E#4 |-> {X#9=(letrec {E#10} in S#12);E#15}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(letrec {E#10} in S#12);E#15} in A#13[(var X#9)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);X#9=(letrec {E#10} in S#12);E#15} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(letrec {E#10} in S#12);E#15} in A#13[(var X#9)]) -SR,llet-e1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=S#12;E#10;E#15} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec {E#11} in S#13) ;E#12 ;EE#15[X#10,(var X#9)] in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec X#9= S#13 ;E#11 ;E#12 ;EE#15[X#10,(var X#9)] in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#14,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])],(letrec {E#11} in [.])), [{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),[.]), ((var X#10),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#17[(app A#18[(var X#10)] T#19)]), T#16 |-> A#17[(app A#18[(var X#10)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec E#11 in T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) ;E#12 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#9= T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#11 ;E#12 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(letrec {E#11} in T#19);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]), X#17 |-> X#9, E#18 |-> {E#12;EE#15[X#10,(var X#9)]}, T#16 |-> (letrec {E#11} in T#19), S#13 |-> T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=(letrec {E#11} in T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#9=(letrec {E#11} in T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#9=(letrec {E#11} in T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec X#20= T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#22 in S#13 ) ;E#12 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#20= T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= S#13 ;E#12 ;E#22 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#12;E#22;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22} in [.])), [{E#12;EE#15[X#10,(var X#9)]},(letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(letrec {X#20=T#19;E#22} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]), X#17 |-> X#9, E#18 |-> {E#12;EE#15[X#10,(var X#9)]}, T#16 |-> (letrec {X#20=T#19;E#22} in S#13), E#11 |-> {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#9=(letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#9=(letrec {X#20=T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#9=(letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#22} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#20=T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=S#13;E#12;E#22;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#9= (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#20} in S#13) ;E#12 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#12 ;E#20 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#12;E#20;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#20} in [.])), [{E#12;EE#15[X#10,(var X#9)]},(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#20} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=[.];E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]), X#17 |-> X#9, E#18 |-> {E#12;EE#15[X#10,(var X#9)]}, T#16 |-> [.], S#6 |-> S#13, E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#20}, E#19 |-> {X#1=C#8[(var X#2)];E#20}, E#4 |-> {E#20}} and instantiated rules: (letrec {X#9=(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#20} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#9=(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#20} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#9=(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#20} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=S#13;E#12;E#20;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= (letrec {E#11} in S#13) ;E#19 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#17= T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;X#9= S#13 ;E#11 ;E#19 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#11;E#19;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#17=T#16;X#9=(letrec {E#11} in S#13);E#19;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]), E#12 |-> {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19}, E#18 |-> {X#9=(letrec {E#11} in S#13);E#19;EE#15[X#10,(var X#9)]}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(letrec {E#11} in S#13);E#19;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#17=T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(letrec {E#11} in S#13);E#19;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=(letrec {E#11} in S#13);E#19;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];X#9=S#13;E#11;E#19;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (letrec {E#11} in S#13) ;E#12 in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= S#13 ;E#11 ;E#12 in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#10=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;E#12} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#10=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#12},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#10=A#20[(app A#21[(var X#9)] T#22)];X#9=(letrec {E#11} in S#13);E#12} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]}, X#17 |-> X#10, E#18 |-> {X#9=(letrec {E#11} in S#13);E#12}, T#16 |-> A#20[(app A#21[(var X#9)] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12} in A#14[(var X#10)]) <-cp-e1- (letrec {X#10=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#10=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=S#13;E#11;E#12} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (letrec {E#11} in S#13) ;E#12 ;EE#21[X#20,(var X#9)] in A#14[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= S#13 ;E#11 ;E#12 ;EE#21[X#20,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;E#12;EE#21[X#20,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#12;EE#21[X#20,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24)];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#20,(var X#9)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#21[X#20,[.2]]}, X#17 |-> X#10, E#18 |-> {X#9=(letrec {E#11} in S#13);E#12;EE#21[X#20,(var X#9)]}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#20,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#20,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#20,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=S#13;E#11;E#12;EE#21[X#20,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (letrec {E#11} in S#13) ;E#12 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,(var X#9)] in A#14[(var X#10)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= S#13 ;E#11 ;E#12 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];X#9=(letrec {E#11} in S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {X#9=(letrec {E#11} in S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=S#13;E#11;E#12;EE#22[X#10,(var X#20)];EE#23[X#21,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= (letrec {E#11} in S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;X#9= S#13 ;E#11 ;E#12 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#11;E#12;EE#21[X#10,(var X#20)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#12;EE#21[X#10,(var X#20)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app A#23[(var X#9)] T#24)];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#9=(letrec {E#11} in S#13);E#12;EE#21[X#10,(var X#20)]}, T#16 |-> A#22[(app A#23[(var X#9)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=(letrec {E#11} in S#13);E#12;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];X#9=S#13;E#11;E#12;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in C#17[(\ X#3.S#5)]) ;E#16 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= C#17[(var X#2)] ;E#11 ;E#16 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(letrec {E#11} in C#17)), ((var X#2),(letrec {E#11} in C#17)), (S#5,(letrec {E#11} in C#17)), ((var X#9),(letrec {X#2=(\ X#3.S#5);E#11;E#16;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#2=(\ X#3.S#5);E#16;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),(letrec {E#11} in C#17[[.]])), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, X#1 |-> X#9, E#4 |-> {E#16;EE#15[X#10,(var X#9)]}, C#8 |-> (letrec {E#11} in C#17), S#13 |-> C#17[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#11} in C#17[(var X#2)]);E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#11} in C#17[(\ X#3.S#5)]);E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#11} in C#17[(var X#2)]);E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#2=(\ X#3.S#5);X#9=C#17[(var X#2)];E#11;E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {X#18=C#17[(\ X#3.S#5)];E#20} in S#13) ;E#16 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#18= C#17[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#16 ;E#20 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(letrec {X#18=C#17;E#20} in S#13)), ((var X#2),(letrec {X#18=C#17;E#20} in S#13)), (S#5,(letrec {X#18=C#17;E#20} in S#13)), ((var X#9),(letrec {X#18=C#17[(var X#2)];X#2=(\ X#3.S#5);E#16;E#20;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {X#18=C#17[(var X#2)];E#20} in [.])), [{X#2=(\ X#3.S#5);E#16;EE#15[X#10,(var X#9)]},(letrec {X#18=C#17[(var X#2)];E#20} in [.])], ((var X#2),(letrec {X#18=C#17[[.]];E#20} in S#13)), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, X#1 |-> X#9, E#4 |-> {E#16;EE#15[X#10,(var X#9)]}, C#8 |-> (letrec {X#18=C#17;E#20} in S#13), E#11 |-> {X#18=C#17[(var X#2)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#18=C#17[(var X#2)];E#20} in S#13);E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#18=C#17[(\ X#3.S#5)];E#20} in S#13);E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#18=C#17[(var X#2)];E#20} in S#13);E#16;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#18=C#17[(var X#2)];X#2=(\ X#3.S#5);X#9=S#13;E#16;E#20;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in S#13) ;E#17 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#11 ;E#17 ;EE#15[X#10,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), ((var X#9),(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#11;E#17;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),C#8[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17}, E#16 |-> {X#1=C#8[(var X#2)];E#17}, E#4 |-> {X#9=(letrec {E#11} in S#13);E#17;EE#15[X#10,(var X#9)]}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#17;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#17;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#17;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);X#9=S#13;E#11;E#17;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[(app A#19[(var X#9)] C#20[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in S#13) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[(app A#19[(var X#9)] C#20[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#11 ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#18[(app A#19[(var X#9)] C#20)]), ((var X#2),A#18[(app A#19[(var X#9)] C#20)]), (S#5,A#18[(app A#19[(var X#9)] C#20)]), ((var X#9),(letrec {X#10=A#18[(app A#19[(var X#9)] C#20[(var X#2)])];X#2=(\ X#3.S#5);E#11;E#16} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#10=A#18[(app A#19[(var X#9)] C#20[(var X#2)])];X#2=(\ X#3.S#5);E#16},(letrec {E#11} in [.])], ((var X#2),A#18[(app A#19[(var X#9)] C#20[[.]])]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] C#20[(var X#2)])]}, X#1 |-> X#10, E#4 |-> {X#9=(letrec {E#11} in S#13);E#16}, C#8 |-> A#18[(app A#19[(var X#9)] C#20)], A#17 |-> A#18[(app A#19 C#20[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[(app A#19[(var X#9)] C#20[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16} in A#14[(var X#10)]) <-cp-e1- (letrec {X#10=A#18[(app A#19[(var X#9)] C#20[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[(app A#19[(var X#9)] C#20[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#10=A#18[(app A#19[(var X#9)] C#20[(var X#2)])];X#2=(\ X#3.S#5);X#9=S#13;E#11;E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#18)] C#22[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in S#13) ;E#16 ;EE#19[X#18,(var X#9)] in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(var X#18)] C#22[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#11 ;E#16 ;EE#19[X#18,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app A#21[(var X#18)] C#22)]), ((var X#2),A#20[(app A#21[(var X#18)] C#22)]), (S#5,A#20[(app A#21[(var X#18)] C#22)]), ((var X#9),(letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#11;E#16;EE#19[X#18,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#18,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),A#20[(app A#21[(var X#18)] C#22[[.]])]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];EE#19[X#18,[.2]]}, X#1 |-> X#10, E#4 |-> {X#9=(letrec {E#11} in S#13);E#16;EE#19[X#18,(var X#9)]}, C#8 |-> A#20[(app A#21[(var X#18)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#19[X#18,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#19[X#18,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#19[X#18,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(\ X#3.S#5);X#9=S#13;E#11;E#16;EE#19[X#18,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in S#13) ;E#16 ;EE#20[X#10,(var X#18)] ;EE#21[X#19,(var X#9)] in A#14[(var X#10)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#11 ;E#16 ;EE#20[X#10,(var X#18)] ;EE#21[X#19,(var X#9)] in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#22[(app A#23[(var X#19)] C#24)]), ((var X#2),A#22[(app A#23[(var X#19)] C#24)]), (S#5,A#22[(app A#23[(var X#19)] C#24)]), ((var X#9),(letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#11;E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]},(letrec {E#11} in [.])], ((var X#2),A#22[(app A#23[(var X#19)] C#24[[.]])]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#1 |-> X#18, E#4 |-> {X#9=(letrec {E#11} in S#13);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]}, C#8 |-> A#22[(app A#23[(var X#19)] C#24)], A#17 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);X#9=S#13;E#11;E#16;EE#20[X#10,(var X#18)];EE#21[X#19,(var X#9)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#9)] C#22[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in S#13) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[(app A#21[(var X#9)] C#22[(var X#2)])] ;X#2= (\ X#3.S#5) ;X#9= S#13 ;E#11 ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app A#21[(var X#9)] C#22)]), ((var X#2),A#20[(app A#21[(var X#9)] C#22)]), (S#5,A#20[(app A#21[(var X#9)] C#22)]), ((var X#9),(letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#11;E#16;EE#19[X#10,(var X#18)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), [{X#18=A#20[(app A#21[(var X#9)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#10,(var X#18)]},(letrec {E#11} in [.])], ((var X#2),A#20[(app A#21[(var X#9)] C#22[[.]])]), ((var X#9),[.]), ((var X#10),A#14[[.]]), ((var X#9),[.]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#9=S#13;E#11;E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)]) and constraints: E#11/= {}, ((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])), (A#14[(var X#10)],(letrec {E#11} in [.])), ({E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {X#9=(letrec {E#11} in S#13);E#12;EE#15[X#10,(var X#9)]} in A#14[(var X#10)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),((var X#9),(letrec {E#11;E#12;EE#15[X#10,(var X#9)]} in [.])),(A#14[(var X#10)],(letrec {E#11} in [.])),[{E#12;EE#15[X#10,(var X#9)]},(letrec {E#11} in [.])],((var X#2),C#8[[.]]),((var X#9),[.]),((var X#10),A#14[[.]]),((var X#9),[.]),((var X#10),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#10)], E#12 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] C#22[(var X#2)])];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {X#9=(letrec {E#11} in S#13);E#16;EE#19[X#10,(var X#18)]}, C#8 |-> A#20[(app A#21[(var X#9)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-cp-e1- (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(\ X#3.S#5)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(var X#2)])];X#2=(\ X#3.S#5);X#9=(letrec {E#11} in S#13);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,llet-e2-> (letrec {X#18=A#20[(app A#21[(var X#9)] C#22[(var X#2)])];X#2=(\ X#3.S#5);X#9=S#13;E#11;E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( A#13[(app (letrec E#9 in T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#10)] , A#13[(letrec E#9 in (app T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#10) )] ) where Delta1 = {T#15,T#14,A#12,T#7,A#13} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {E#9} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> A#13, T#7 |-> A#13[(app (letrec {E#9} in T#16) S#10)], T#14 |-> (app (letrec {E#9} in T#16) S#10), T#15 |-> (letrec {E#9} in T#16), S#11 |-> T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: A#13[(app (letrec {E#9} in T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#10)] <-cp-e1- A#13[(app (letrec {E#9} in T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#10)] ................................................................................ A#13[(app (letrec {E#9} in T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#10)] -SR,lapp1-> A#13[(letrec {E#9} in (app T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#10))] ================================================================================ Critical Pair: ( A#13[(app (letrec X#17= T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 in S#11 ) S#10)] , A#13[(letrec X#17= T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 in (app S#11 S#10) )] ) where Delta1 = {T#15,T#14,A#12,T#7,A#13} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> A#13, T#7 |-> A#13[(app (letrec {X#17=T#16;E#19} in S#11) S#10)], T#14 |-> (app (letrec {X#17=T#16;E#19} in S#11) S#10), T#15 |-> (letrec {X#17=T#16;E#19} in S#11), E#9 |-> {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19}, E#18 |-> {E#19}} and instantiated rules: A#13[(app (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in S#11) S#10)] <-cp-e1- A#13[(app (letrec {X#17=T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in S#11) S#10)] ................................................................................ A#13[(app (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in S#11) S#10)] -SR,lapp1-> A#13[(letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in (app S#11 S#10))] ================================================================================ Critical Pair: ( A#13[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#17} in S#11) S#10)] , A#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in (app S#11 S#10))] ) where Delta1 = {T#14,A#12,T#7,A#13} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> A#13, T#7 |-> A#13[(app [.] S#10)], T#14 |-> (app [.] S#10), T#15 |-> [.], S#6 |-> S#11, E#9 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17}, E#16 |-> {X#1=C#8[(var X#2)];E#17}, E#4 |-> {E#17}} and instantiated rules: A#13[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in S#11) S#10)] <-cp-e1- A#13[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#17} in S#11) S#10)] ................................................................................ A#13[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in S#11) S#10)] -SR,lapp1-> A#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in (app S#11 S#10))] ================================================================================ Critical Pair: ( A#13[(app (letrec {E#9} in S#11) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] , A#13[(letrec E#9 in (app S#11 T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) )] ) where Delta1 = {T#14,A#12,T#7,A#13} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#9} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> A#13, T#7 |-> A#13[(app (letrec {E#9} in S#11) T#15)], T#14 |-> (app (letrec {E#9} in S#11) T#15), S#10 |-> T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: A#13[(app (letrec {E#9} in S#11) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] <-cp-e1- A#13[(app (letrec {E#9} in S#11) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ................................................................................ A#13[(app (letrec {E#9} in S#11) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] -SR,lapp1-> A#13[(letrec {E#9} in (app S#11 T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]))] ================================================================================ Critical Pair: ( A#13[(app A#14[(app (letrec {E#9} in S#11) S#10)] T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] , A#13[(app A#14[(letrec {E#9} in (app S#11 S#10))] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) where Delta1 = {A#12,T#7} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {E#9} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> A#13[(app A#14[(app (letrec {E#9} in S#11) S#10)] T#15)], A#12 |-> A#13[(app A#14 T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: A#13[(app A#14[(app (letrec {E#9} in S#11) S#10)] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] <-cp-e1- A#13[(app A#14[(app (letrec {E#9} in S#11) S#10)] T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ................................................................................ A#13[(app A#14[(app (letrec {E#9} in S#11) S#10)] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] -SR,lapp1-> A#13[(app A#14[(letrec {E#9} in (app S#11 S#10))] T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ================================================================================ Critical Pair: ( (app (letrec E#9 in T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#10) , (letrec E#9 in (app T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#10) ) ) where Delta1 = {T#13,T#7} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {E#9} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> [.], T#7 |-> (app (letrec {E#9} in T#14) S#10), T#13 |-> (letrec {E#9} in T#14), S#11 |-> T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (app (letrec {E#9} in T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#10) <-cp-e1- (app (letrec {E#9} in T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#10) ................................................................................ (app (letrec {E#9} in T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#10) -SR,lapp1-> (letrec {E#9} in (app T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#10)) ================================================================================ Critical Pair: ( (app (letrec X#15= T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#17 in S#11 ) S#10) , (letrec X#15= T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#17 in (app S#11 S#10) ) ) where Delta1 = {T#13,T#7} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> [.], T#7 |-> (app (letrec {X#15=T#14;E#17} in S#11) S#10), T#13 |-> (letrec {X#15=T#14;E#17} in S#11), E#9 |-> {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17}, E#16 |-> {E#17}} and instantiated rules: (app (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in S#11) S#10) <-cp-e1- (app (letrec {X#15=T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in S#11) S#10) ................................................................................ (app (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in S#11) S#10) -SR,lapp1-> (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in (app S#11 S#10)) ================================================================================ Critical Pair: ( (app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#15} in S#11) S#10) , (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in (app S#11 S#10)) ) where Delta1 = {T#7} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#10,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> [.], T#7 |-> (app [.] S#10), T#13 |-> [.], S#6 |-> S#11, E#9 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15}, E#14 |-> {X#1=C#8[(var X#2)];E#15}, E#4 |-> {E#15}} and instantiated rules: (app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in S#11) S#10) <-cp-e1- (app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#15} in S#11) S#10) ................................................................................ (app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in S#11) S#10) -SR,lapp1-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in (app S#11 S#10)) ================================================================================ Critical Pair: ( (app (letrec {E#9} in S#11) T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) , (letrec E#9 in (app S#11 T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) ) ) where Delta1 = {T#7} Delta2 = {E#9} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#9} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ A#12[(app (letrec {E#9} in S#11) S#10)] -SR,lapp1-> A#12[(letrec {E#9} in (app S#11 S#10))] and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= A#12[(app (letrec {E#9} in S#11) S#10)]} Delta1= {} Delta2= {E#9} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#10,(letrec {E#9} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {A#12 |-> [.], T#7 |-> (app (letrec {E#9} in S#11) T#13), S#10 |-> T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (app (letrec {E#9} in S#11) T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) <-cp-e1- (app (letrec {E#9} in S#11) T#13[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ................................................................................ (app (letrec {E#9} in S#11) T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) -SR,lapp1-> (letrec {E#9} in (app S#11 T#13[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) ================================================================================ Critical Pair: ( (letrec E#9 in A#15[(app (letrec E#10 in T#18[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#11)] ) , (letrec E#9 in A#15[(letrec E#10 in (app T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#11) )] ) ) where Delta1 = {T#17,T#16,A#13,T#14,T#7,A#15} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in A#15[(app (letrec {E#10} in T#18) S#11)]), A#13 |-> A#15, T#14 |-> A#15[(app (letrec {E#10} in T#18) S#11)], T#16 |-> (app (letrec {E#10} in T#18) S#11), T#17 |-> (letrec {E#10} in T#18), S#12 |-> T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#9} in A#15[(app (letrec {E#10} in T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#11)]) <-cp-e1- (letrec {E#9} in A#15[(app (letrec {E#10} in T#18[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#11)]) ................................................................................ (letrec {E#9} in A#15[(app (letrec {E#10} in T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#11)]) -SR,lapp2-> (letrec {E#9} in A#15[(letrec {E#10} in (app T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#11))]) ================================================================================ Critical Pair: ( (letrec E#9 in A#15[(app (letrec X#19= T#18[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#21 in S#12 ) S#11)] ) , (letrec E#9 in A#15[(letrec X#19= T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#21 in (app S#12 S#11) )] ) ) where Delta1 = {T#17,T#16,A#13,T#14,T#7,A#15} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {X#19=T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#21} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in A#15[(app (letrec {X#19=T#18;E#21} in S#12) S#11)]), A#13 |-> A#15, T#14 |-> A#15[(app (letrec {X#19=T#18;E#21} in S#12) S#11)], T#16 |-> (app (letrec {X#19=T#18;E#21} in S#12) S#11), T#17 |-> (letrec {X#19=T#18;E#21} in S#12), E#10 |-> {X#19=T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {E#9} in A#15[(app (letrec {X#19=T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#21} in S#12) S#11)]) <-cp-e1- (letrec {E#9} in A#15[(app (letrec {X#19=T#18[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#21} in S#12) S#11)]) ................................................................................ (letrec {E#9} in A#15[(app (letrec {X#19=T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#21} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#15[(letrec {X#19=T#18[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#21} in (app S#12 S#11))]) ================================================================================ Critical Pair: ( (letrec E#9 in A#15[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#19} in S#12) S#11)] ) , (letrec E#9 in A#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#19} in (app S#12 S#11))] ) ) where Delta1 = {T#16,A#13,T#14,T#7,A#15} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#19} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in A#15[(app [.] S#11)]), A#13 |-> A#15, T#14 |-> A#15[(app [.] S#11)], T#16 |-> (app [.] S#11), T#17 |-> [.], S#6 |-> S#12, E#10 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#19}, E#18 |-> {X#1=C#8[(var X#2)];E#19}, E#4 |-> {E#19}} and instantiated rules: (letrec {E#9} in A#15[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#19} in S#12) S#11)]) <-cp-e1- (letrec {E#9} in A#15[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#19} in S#12) S#11)]) ................................................................................ (letrec {E#9} in A#15[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#19} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#19} in (app S#12 S#11))]) ================================================================================ Critical Pair: ( (letrec E#9 in A#15[(app (letrec {E#10} in S#12) T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec E#9 in A#15[(letrec E#10 in (app S#12 T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) )] ) ) where Delta1 = {T#16,A#13,T#14,T#7,A#15} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in A#15[(app (letrec {E#10} in S#12) T#17)]), A#13 |-> A#15, T#14 |-> A#15[(app (letrec {E#10} in S#12) T#17)], T#16 |-> (app (letrec {E#10} in S#12) T#17), S#11 |-> T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#9} in A#15[(app (letrec {E#10} in S#12) T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {E#9} in A#15[(app (letrec {E#10} in S#12) T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {E#9} in A#15[(app (letrec {E#10} in S#12) T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,lapp2-> (letrec {E#9} in A#15[(letrec {E#10} in (app S#12 T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]))]) ================================================================================ Critical Pair: ( (letrec E#9 in A#15[(app A#16[(app (letrec {E#10} in S#12) S#11)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec E#9 in A#15[(app A#16[(letrec {E#10} in (app S#12 S#11))] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#13,T#14,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in A#15[(app A#16[(app (letrec {E#10} in S#12) S#11)] T#17)]), T#14 |-> A#15[(app A#16[(app (letrec {E#10} in S#12) S#11)] T#17)], A#13 |-> A#15[(app A#16 T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {E#9} in A#15[(app A#16[(app (letrec {E#10} in S#12) S#11)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {E#9} in A#15[(app A#16[(app (letrec {E#10} in S#12) S#11)] T#17[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {E#9} in A#15[(app A#16[(app (letrec {E#10} in S#12) S#11)] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,lapp2-> (letrec {E#9} in A#15[(app A#16[(letrec {E#10} in (app S#12 S#11))] T#17[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec E#9 in (app (letrec E#10 in T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#11) ) , (letrec E#9 in (letrec E#10 in (app T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#11) ) ) ) where Delta1 = {T#15,T#14,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in (app (letrec {E#10} in T#16) S#11)), A#13 |-> [.], T#14 |-> (app (letrec {E#10} in T#16) S#11), T#15 |-> (letrec {E#10} in T#16), S#12 |-> T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#9} in (app (letrec {E#10} in T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#11)) <-cp-e1- (letrec {E#9} in (app (letrec {E#10} in T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#11)) ................................................................................ (letrec {E#9} in (app (letrec {E#10} in T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#11)) -SR,lapp2-> (letrec {E#9} in (letrec {E#10} in (app T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#11))) ================================================================================ Critical Pair: ( (letrec E#9 in (app (letrec X#17= T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 in S#12 ) S#11) ) , (letrec E#9 in (letrec X#17= T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 in (app S#12 S#11) ) ) ) where Delta1 = {T#15,T#14,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in (app (letrec {X#17=T#16;E#19} in S#12) S#11)), A#13 |-> [.], T#14 |-> (app (letrec {X#17=T#16;E#19} in S#12) S#11), T#15 |-> (letrec {X#17=T#16;E#19} in S#12), E#10 |-> {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {E#9} in (app (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in S#12) S#11)) <-cp-e1- (letrec {E#9} in (app (letrec {X#17=T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in S#12) S#11)) ................................................................................ (letrec {E#9} in (app (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in S#12) S#11)) -SR,lapp2-> (letrec {E#9} in (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19} in (app S#12 S#11))) ================================================================================ Critical Pair: ( (letrec E#9 in (app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#17} in S#12) S#11) ) , (letrec E#9 in (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in (app S#12 S#11)) ) ) where Delta1 = {T#14,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in (app [.] S#11)), A#13 |-> [.], T#14 |-> (app [.] S#11), T#15 |-> [.], S#6 |-> S#12, E#10 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17}, E#16 |-> {X#1=C#8[(var X#2)];E#17}, E#4 |-> {E#17}} and instantiated rules: (letrec {E#9} in (app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in S#12) S#11)) <-cp-e1- (letrec {E#9} in (app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#17} in S#12) S#11)) ................................................................................ (letrec {E#9} in (app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in S#12) S#11)) -SR,lapp2-> (letrec {E#9} in (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17} in (app S#12 S#11))) ================================================================================ Critical Pair: ( (letrec E#9 in (app (letrec {E#10} in S#12) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ) , (letrec E#9 in (letrec E#10 in (app S#12 T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) ) ) ) where Delta1 = {T#14,T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#9} in (app (letrec {E#10} in S#12) T#15)), A#13 |-> [.], T#14 |-> (app (letrec {E#10} in S#12) T#15), S#11 |-> T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {E#9} in (app (letrec {E#10} in S#12) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) <-cp-e1- (letrec {E#9} in (app (letrec {E#10} in S#12) T#15[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])) ................................................................................ (letrec {E#9} in (app (letrec {E#10} in S#12) T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])) -SR,lapp2-> (letrec {E#9} in (letrec {E#10} in (app S#12 T#15[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]))) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#17 in A#13[(app (letrec {E#10} in S#12) S#11)] ) , (letrec X#15= T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#17 in A#13[(letrec {E#10} in (app S#12 S#11))] ) ) where Delta1 = {T#7} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#15=T#14;E#17} in A#13[(app (letrec {E#10} in S#12) S#11)]), E#9 |-> {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(app (letrec {E#10} in S#12) S#11)]) <-cp-e1- (letrec {X#15=T#14[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(app (letrec {E#10} in S#12) S#11)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {X#15=T#14[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#17} in A#13[(letrec {E#10} in (app S#12 S#11))]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;E#15 in A#13[(app (letrec {E#10} in S#12) S#11)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;E#15 in A#13[(letrec {E#10} in (app S#12 S#11))] ) ) where Delta1 = {} Delta2 = {E#9,E#10} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#11,(letrec {E#10} in [.])), ((var X#2),C#8[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {E#9} in A#13[(letrec {E#10} in (app S#12 S#11))]) and constraints: E#9/= {}, E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#9} in A#13[(app (letrec {E#10} in S#12) S#11)])} Delta1= {} Delta2= {E#9,E#10} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#11,(letrec {E#10} in [.])),((var X#2),C#8[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#13[(app (letrec {E#10} in S#12) S#11)], E#9 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15}, E#14 |-> {X#1=C#8[(var X#2)];E#15}, E#4 |-> {E#15}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in A#13[(app (letrec {E#10} in S#12) S#11)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#15} in A#13[(app (letrec {E#10} in S#12) S#11)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in A#13[(app (letrec {E#10} in S#12) S#11)]) -SR,lapp2-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#15} in A#13[(letrec {E#10} in (app S#12 S#11))]) ================================================================================ Critical Pair: ( (letrec E#10 ;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)] in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) , (letrec E#10 ;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))] in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ) ) where Delta1 = {A#14,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]), ((var X#9),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19)]), T#16 |-> A#17[(app A#18[(var X#9)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) <-cp-e1- (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#17[(app A#18[(var X#9)] T#19[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 ;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#17= T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#19 ;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))] in A#14[(var X#9)] ) ) where Delta1 = {T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#17=T#16;E#19;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]), E#10 |-> {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19}, E#18 |-> {E#19;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#17=T#16[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#17=T#16[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#19;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app (letrec E#11 in T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#12)] ;E#10 in A#14[(var X#9)] ) , (letrec X#9= A#20[(letrec E#11 in (app T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12) )] ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#22,T#21,A#19,T#16,T#7,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app (letrec {E#11} in T#23) S#12)];E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> A#20, T#16 |-> A#20[(app (letrec {E#11} in T#23) S#12)], T#21 |-> (app (letrec {E#11} in T#23) S#12), T#22 |-> (letrec {E#11} in T#23), S#13 |-> T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=A#20[(app (letrec {E#11} in T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12)];E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app (letrec {E#11} in T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12)];E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app (letrec {E#11} in T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12)];E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=A#20[(letrec {E#11} in (app T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12))];E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app (letrec X#24= T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#26 in S#13 ) S#12)] ;E#10 in A#14[(var X#9)] ) , (letrec X#9= A#20[(letrec X#24= T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#26 in (app S#13 S#12) )] ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#22,T#21,A#19,T#16,T#7,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app (letrec {X#24=T#23;E#26} in S#13) S#12)];E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> A#20, T#16 |-> A#20[(app (letrec {X#24=T#23;E#26} in S#13) S#12)], T#21 |-> (app (letrec {X#24=T#23;E#26} in S#13) S#12), T#22 |-> (letrec {X#24=T#23;E#26} in S#13), E#11 |-> {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26}, E#25 |-> {E#26}} and instantiated rules: (letrec {X#9=A#20[(app (letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in S#13) S#12)];E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app (letrec {X#24=T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in S#13) S#12)];E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app (letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in S#13) S#12)];E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=A#20[(letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in (app S#13 S#12))];E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#24} in S#13) S#12)] ;E#10 in A#14[(var X#9)] ) , (letrec X#9= A#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in (app S#13 S#12))] ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#21,A#19,T#16,T#7,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app [.] S#12)];E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> A#20, T#16 |-> A#20[(app [.] S#12)], T#21 |-> (app [.] S#12), T#22 |-> [.], S#6 |-> S#13, E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24}, E#23 |-> {X#1=C#8[(var X#2)];E#24}, E#4 |-> {E#24}} and instantiated rules: (letrec {X#9=A#20[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in S#13) S#12)];E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#24} in S#13) S#12)];E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in S#13) S#12)];E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=A#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in (app S#13 S#12))];E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 in A#14[(var X#9)] ) , (letrec X#9= A#20[(letrec E#11 in (app S#13 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) )] ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#21,A#19,T#16,T#7,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app (letrec {E#11} in S#13) T#22)];E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> A#20, T#16 |-> A#20[(app (letrec {E#11} in S#13) T#22)], T#21 |-> (app (letrec {E#11} in S#13) T#22), S#12 |-> T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=A#20[(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=A#20[(letrec {E#11} in (app S#13 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]))];E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 in A#14[(var X#9)] ) , (letrec X#9= A#20[(app A#21[(letrec {E#11} in (app S#13 S#12))] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] T#22)];E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]}, X#17 |-> X#9, E#18 |-> {E#10}, T#16 |-> A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=A#20[(app A#21[(letrec {E#11} in (app S#13 S#12))] T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (app (letrec E#11 in T#21[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#12) ;E#10 in A#14[(var X#9)] ) , (letrec X#9= (letrec E#11 in (app T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12) ) ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#20,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(app (letrec {E#11} in T#21) S#12);E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> [.], T#16 |-> (app (letrec {E#11} in T#21) S#12), T#20 |-> (letrec {E#11} in T#21), S#13 |-> T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=(app (letrec {E#11} in T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12);E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=(app (letrec {E#11} in T#21[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12);E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=(app (letrec {E#11} in T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12);E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=(letrec {E#11} in (app T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12));E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (app (letrec X#22= T#21[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#24 in S#13 ) S#12) ;E#10 in A#14[(var X#9)] ) , (letrec X#9= (letrec X#22= T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#24 in (app S#13 S#12) ) ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#20,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#22=T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#24} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(app (letrec {X#22=T#21;E#24} in S#13) S#12);E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> [.], T#16 |-> (app (letrec {X#22=T#21;E#24} in S#13) S#12), T#20 |-> (letrec {X#22=T#21;E#24} in S#13), E#11 |-> {X#22=T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#9=(app (letrec {X#22=T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#24} in S#13) S#12);E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=(app (letrec {X#22=T#21[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#24} in S#13) S#12);E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=(app (letrec {X#22=T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#24} in S#13) S#12);E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=(letrec {X#22=T#21[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#24} in (app S#13 S#12));E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#22} in S#13) S#12) ;E#10 in A#14[(var X#9)] ) , (letrec X#9= (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#22} in (app S#13 S#12)) ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#22} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(app [.] S#12);E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> [.], T#16 |-> (app [.] S#12), T#20 |-> [.], S#6 |-> S#13, E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#22}, E#21 |-> {X#1=C#8[(var X#2)];E#22}, E#4 |-> {E#22}} and instantiated rules: (letrec {X#9=(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#22} in S#13) S#12);E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#22} in S#13) S#12);E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#22} in S#13) S#12);E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#22} in (app S#13 S#12));E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= (app (letrec {E#11} in S#13) T#20[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ;E#10 in A#14[(var X#9)] ) , (letrec X#9= (letrec E#11 in (app S#13 T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) ) ;E#10 in A#14[(var X#9)] ) ) where Delta1 = {T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=(app (letrec {E#11} in S#13) T#20);E#10} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#9, E#18 |-> {E#10}, A#19 |-> [.], T#16 |-> (app (letrec {E#11} in S#13) T#20), S#12 |-> T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#9=(app (letrec {E#11} in S#13) T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#10} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=(app (letrec {E#11} in S#13) T#20[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#10} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=(app (letrec {E#11} in S#13) T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#10} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=(letrec {E#11} in (app S#13 T#20[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]));E#10} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#9= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#21[X#20,(app (letrec {E#11} in S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#9= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#21[X#20,(letrec {E#11} in (app S#13 S#12))] in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#9=A#22[(app A#23[(var X#20)] T#24)];E#10;EE#21[X#20,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#21[X#20,[.2]]}, X#17 |-> X#9, E#18 |-> {E#10;EE#21[X#20,(app (letrec {E#11} in S#13) S#12)]}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#20,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#20,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#20,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#9=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#20,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#22[X#9,(var X#20)] ;EE#23[X#21,(app (letrec {E#11} in S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#22[X#9,(var X#20)] ;EE#23[X#21,(letrec {E#11} in (app S#13 S#12))] in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];E#10;EE#22[X#9,(var X#20)];EE#23[X#21,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {E#10;EE#22[X#9,(var X#20)];EE#23[X#21,(app (letrec {E#11} in S#13) S#12)]}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#22[X#9,(var X#20)];EE#23[X#21,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#22[X#9,(var X#20)];EE#23[X#21,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#22[X#9,(var X#20)];EE#23[X#21,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#22[X#9,(var X#20)];EE#23[X#21,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app (letrec E#11 in T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#12)] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(letrec E#11 in (app T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12) )] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#24,T#23,A#19,T#16,T#7,A#22} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app (letrec {E#11} in T#25) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[(app (letrec {E#11} in T#25) S#12)], T#23 |-> (app (letrec {E#11} in T#25) S#12), T#24 |-> (letrec {E#11} in T#25), S#13 |-> T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#20=A#22[(app (letrec {E#11} in T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app (letrec {E#11} in T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app (letrec {E#11} in T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=A#22[(letrec {E#11} in (app T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12))];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app (letrec X#26= T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#28 in S#13 ) S#12)] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(letrec X#26= T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#28 in (app S#13 S#12) )] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#24,T#23,A#19,T#16,T#7,A#22} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#26=T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#28} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app (letrec {X#26=T#25;E#28} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[(app (letrec {X#26=T#25;E#28} in S#13) S#12)], T#23 |-> (app (letrec {X#26=T#25;E#28} in S#13) S#12), T#24 |-> (letrec {X#26=T#25;E#28} in S#13), E#11 |-> {X#26=T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#28}, E#27 |-> {E#28}} and instantiated rules: (letrec {X#20=A#22[(app (letrec {X#26=T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#28} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app (letrec {X#26=T#25[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#28} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app (letrec {X#26=T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#28} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=A#22[(letrec {X#26=T#25[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#28} in (app S#13 S#12))];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#26} in S#13) S#12)] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#26} in (app S#13 S#12))] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#23,A#19,T#16,T#7,A#22} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#26} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app [.] S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[(app [.] S#12)], T#23 |-> (app [.] S#12), T#24 |-> [.], S#6 |-> S#13, E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#26}, E#25 |-> {X#1=C#8[(var X#2)];E#26}, E#4 |-> {E#26}} and instantiated rules: (letrec {X#20=A#22[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#26} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#26} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#26} in S#13) S#12)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=A#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#26} in (app S#13 S#12))];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app (letrec {E#11} in S#13) T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(letrec E#11 in (app S#13 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) )] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#23,A#19,T#16,T#7,A#22} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app (letrec {E#11} in S#13) T#24)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[(app (letrec {E#11} in S#13) T#24)], T#23 |-> (app (letrec {E#11} in S#13) T#24), S#12 |-> T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#20=A#22[(app (letrec {E#11} in S#13) T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app (letrec {E#11} in S#13) T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app (letrec {E#11} in S#13) T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=A#22[(letrec {E#11} in (app S#13 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]))];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(app (letrec {E#11} in S#13) S#12)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= A#22[(app A#23[(letrec {E#11} in (app S#13 S#12))] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])] ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {A#19,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=A#22[(app A#23[(app (letrec {E#11} in S#13) S#12)] T#24)];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, T#16 |-> A#22[(app A#23[(app (letrec {E#11} in S#13) S#12)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(app (letrec {E#11} in S#13) S#12)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=A#22[(app A#23[(app (letrec {E#11} in S#13) S#12)] T#24[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(app (letrec {E#11} in S#13) S#12)] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=A#22[(app A#23[(letrec {E#11} in (app S#13 S#12))] T#24[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)])];E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= (app (letrec E#11 in T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ) S#12) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= (letrec E#11 in (app T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12) ) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#22,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=(app (letrec {E#11} in T#23) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> [.], T#16 |-> (app (letrec {E#11} in T#23) S#12), T#22 |-> (letrec {E#11} in T#23), S#13 |-> T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#20=(app (letrec {E#11} in T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=(app (letrec {E#11} in T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=(app (letrec {E#11} in T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=(letrec {E#11} in (app T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] S#12));E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= (app (letrec X#24= T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#26 in S#13 ) S#12) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= (letrec X#24= T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] ;E#26 in (app S#13 S#12) ) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#22,T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=(app (letrec {X#24=T#23;E#26} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> [.], T#16 |-> (app (letrec {X#24=T#23;E#26} in S#13) S#12), T#22 |-> (letrec {X#24=T#23;E#26} in S#13), E#11 |-> {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26}, E#25 |-> {E#26}} and instantiated rules: (letrec {X#20=(app (letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=(app (letrec {X#24=T#23[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=(app (letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=(letrec {X#24=T#23[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)];E#26} in (app S#13 S#12));E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= (app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#24} in S#13) S#12) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in (app S#13 S#12)) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=(app [.] S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> [.], T#16 |-> (app [.] S#12), T#22 |-> [.], S#6 |-> S#13, E#11 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24}, E#23 |-> {X#1=C#8[(var X#2)];E#24}, E#4 |-> {E#24}} and instantiated rules: (letrec {X#20=(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=(app (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#24} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=(app (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in S#13) S#12);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#24} in (app S#13 S#12));E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#20= (app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) , (letrec X#20= (letrec E#11 in (app S#13 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]) ) ;E#10 ;EE#21[X#9,(var X#20)] in A#14[(var X#9)] ) ) where Delta1 = {T#16,T#7} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)],(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> (letrec {X#20=(app (letrec {E#11} in S#13) T#22);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {E#10;EE#21[X#9,(var X#20)]}, A#19 |-> [.], T#16 |-> (app (letrec {E#11} in S#13) T#22), S#12 |-> T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]} and instantiated rules: (letrec {X#20=(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#20=(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#20=(app (letrec {E#11} in S#13) T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]);E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#20=(letrec {E#11} in (app S#13 T#22[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)]));E#10;EE#21[X#9,(var X#20)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#8[(\ X#3.S#5)] ;X#2= (\ X#3.S#5) ;E#17 ;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#1= C#8[(var X#2)] ;X#2= (\ X#3.S#5) ;E#17 ;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))] in A#14[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8), (S#12,(letrec {E#11} in [.])), ((var X#2),C#8[[.]]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17}, E#16 |-> {X#1=C#8[(var X#2)];E#17}, E#4 |-> {E#17;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]}} and instantiated rules: (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#17;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app (letrec {E#11} in C#21[(\ X#3.S#5)]) S#12)] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(letrec {E#11} in (app C#21[(var X#2)] S#12))] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#20,C#19,A#17,C#8,A#18} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#18[(app (letrec {E#11} in C#21) S#12)]), ((var X#2),A#18[(app (letrec {E#11} in C#21) S#12)]), (S#5,A#18[(app (letrec {E#11} in C#21) S#12)]), (S#12,(letrec {E#11} in [.])), ((var X#2),A#18[(app (letrec {E#11} in C#21[[.]]) S#12)]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> A#18, C#8 |-> A#18[(app (letrec {E#11} in C#21) S#12)], C#19 |-> (app (letrec {E#11} in C#21) S#12), C#20 |-> (letrec {E#11} in C#21), S#13 |-> C#21[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {E#11} in C#21[(var X#2)]) S#12)];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {E#11} in C#21[(\ X#3.S#5)]) S#12)];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {E#11} in C#21[(var X#2)]) S#12)];E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(letrec {E#11} in (app C#21[(var X#2)] S#12))];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app (letrec {X#22=C#21[(\ X#3.S#5)];E#24} in S#13) S#12)] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(letrec {X#22=C#21[(var X#2)];E#24} in (app S#13 S#12))] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#20,C#19,A#17,C#8,A#18} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#18[(app (letrec {X#22=C#21;E#24} in S#13) S#12)]), ((var X#2),A#18[(app (letrec {X#22=C#21;E#24} in S#13) S#12)]), (S#5,A#18[(app (letrec {X#22=C#21;E#24} in S#13) S#12)]), (S#12,(letrec {X#22=C#21[(var X#2)];E#24} in [.])), ((var X#2),A#18[(app (letrec {X#22=C#21[[.]];E#24} in S#13) S#12)]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> A#18, C#8 |-> A#18[(app (letrec {X#22=C#21;E#24} in S#13) S#12)], C#19 |-> (app (letrec {X#22=C#21;E#24} in S#13) S#12), C#20 |-> (letrec {X#22=C#21;E#24} in S#13), E#11 |-> {X#22=C#21[(var X#2)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {X#22=C#21[(var X#2)];E#24} in S#13) S#12)];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {X#22=C#21[(\ X#3.S#5)];E#24} in S#13) S#12)];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {X#22=C#21[(var X#2)];E#24} in S#13) S#12)];E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(letrec {X#22=C#21[(var X#2)];E#24} in (app S#13 S#12))];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app (letrec {E#11} in S#13) C#20[(\ X#3.S#5)])] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(letrec {E#11} in (app S#13 C#20[(var X#2)]))] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#19,A#17,C#8,A#18} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#18[(app (letrec {E#11} in S#13) C#20)]), ((var X#2),A#18[(app (letrec {E#11} in S#13) C#20)]), (S#5,A#18[(app (letrec {E#11} in S#13) C#20)]), (C#20[(var X#2)],(letrec {E#11} in [.])), ((var X#2),A#18[(app (letrec {E#11} in S#13) C#20[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> A#18, C#8 |-> A#18[(app (letrec {E#11} in S#13) C#20)], C#19 |-> (app (letrec {E#11} in S#13) C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {E#11} in S#13) C#20[(var X#2)])];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {E#11} in S#13) C#20[(\ X#3.S#5)])];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app (letrec {E#11} in S#13) C#20[(var X#2)])];E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(letrec {E#11} in (app S#13 C#20[(var X#2)]))];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20[(\ X#3.S#5)])] ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#18[(app A#19[(letrec {E#11} in (app S#13 S#12))] C#20[(var X#2)])] ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20)]), ((var X#2),A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20)]), (S#5,A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20)]), (S#12,(letrec {E#11} in [.])), ((var X#2),A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] C#20[(var X#2)])]}, X#1 |-> X#9, E#4 |-> {E#16}, C#8 |-> A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20)], A#17 |-> A#18[(app A#19 C#20[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20[(var X#2)])];E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20[(\ X#3.S#5)])];E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(app (letrec {E#11} in S#13) S#12)] C#20[(var X#2)])];E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=A#18[(app A#19[(letrec {E#11} in (app S#13 S#12))] C#20[(var X#2)])];E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (app (letrec {E#11} in C#19[(\ X#3.S#5)]) S#12) ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in (app C#19[(var X#2)] S#12)) ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#18,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(app (letrec {E#11} in C#19) S#12)), ((var X#2),(app (letrec {E#11} in C#19) S#12)), (S#5,(app (letrec {E#11} in C#19) S#12)), (S#12,(letrec {E#11} in [.])), ((var X#2),(app (letrec {E#11} in C#19[[.]]) S#12)), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> [.], C#8 |-> (app (letrec {E#11} in C#19) S#12), C#18 |-> (letrec {E#11} in C#19), S#13 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {E#11} in C#19[(var X#2)]) S#12);E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {E#11} in C#19[(\ X#3.S#5)]) S#12);E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {E#11} in C#19[(var X#2)]) S#12);E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#11} in (app C#19[(var X#2)] S#12));E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (app (letrec {X#20=C#19[(\ X#3.S#5)];E#22} in S#13) S#12) ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {X#20=C#19[(var X#2)];E#22} in (app S#13 S#12)) ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#18,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(app (letrec {X#20=C#19;E#22} in S#13) S#12)), ((var X#2),(app (letrec {X#20=C#19;E#22} in S#13) S#12)), (S#5,(app (letrec {X#20=C#19;E#22} in S#13) S#12)), (S#12,(letrec {X#20=C#19[(var X#2)];E#22} in [.])), ((var X#2),(app (letrec {X#20=C#19[[.]];E#22} in S#13) S#12)), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> [.], C#8 |-> (app (letrec {X#20=C#19;E#22} in S#13) S#12), C#18 |-> (letrec {X#20=C#19;E#22} in S#13), E#11 |-> {X#20=C#19[(var X#2)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {X#20=C#19[(var X#2)];E#22} in S#13) S#12);E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {X#20=C#19[(\ X#3.S#5)];E#22} in S#13) S#12);E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {X#20=C#19[(var X#2)];E#22} in S#13) S#12);E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=(letrec {X#20=C#19[(var X#2)];E#22} in (app S#13 S#12));E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= (app (letrec {E#11} in S#13) C#18[(\ X#3.S#5)]) ;E#16 in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= (letrec {E#11} in (app S#13 C#18[(var X#2)])) ;E#16 in A#14[(var X#9)] ) ) where Delta1 = {C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(app (letrec {E#11} in S#13) C#18)), ((var X#2),(app (letrec {E#11} in S#13) C#18)), (S#5,(app (letrec {E#11} in S#13) C#18)), (C#18[(var X#2)],(letrec {E#11} in [.])), ((var X#2),(app (letrec {E#11} in S#13) C#18[[.]])), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {E#16}, A#17 |-> [.], C#8 |-> (app (letrec {E#11} in S#13) C#18), S#12 |-> C#18[(var X#2)]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {E#11} in S#13) C#18[(var X#2)]);E#16} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {E#11} in S#13) C#18[(\ X#3.S#5)]);E#16} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=(app (letrec {E#11} in S#13) C#18[(var X#2)]);E#16} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=(letrec {E#11} in (app S#13 C#18[(var X#2)]));E#16} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#3.S#5) ;X#9= A#20[(app A#21[(var X#18)] C#22[(\ X#3.S#5)])] ;E#16 ;EE#19[X#18,(app (letrec {E#11} in S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#2= (\ X#3.S#5) ;X#9= A#20[(app A#21[(var X#18)] C#22[(var X#2)])] ;E#16 ;EE#19[X#18,(letrec {E#11} in (app S#13 S#12))] in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app A#21[(var X#18)] C#22)]), ((var X#2),A#20[(app A#21[(var X#18)] C#22)]), (S#5,A#20[(app A#21[(var X#18)] C#22)]), (S#12,(letrec {E#11} in [.])), ((var X#2),A#20[(app A#21[(var X#18)] C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];EE#19[X#18,[.2]]}, X#1 |-> X#9, E#4 |-> {E#16;EE#19[X#18,(app (letrec {E#11} in S#13) S#12)]}, C#8 |-> A#20[(app A#21[(var X#18)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];E#16;EE#19[X#18,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(\ X#3.S#5)])];E#16;EE#19[X#18,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];E#16;EE#19[X#18,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#2=(\ X#3.S#5);X#9=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];E#16;EE#19[X#18,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#20[X#9,(var X#18)] ;EE#21[X#19,(app (letrec {E#11} in S#13) S#12)] in A#14[(var X#9)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(var X#2)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#20[X#9,(var X#18)] ;EE#21[X#19,(letrec {E#11} in (app S#13 S#12))] in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#22[(app A#23[(var X#19)] C#24)]), ((var X#2),A#22[(app A#23[(var X#19)] C#24)]), (S#5,A#22[(app A#23[(var X#19)] C#24)]), (S#12,(letrec {E#11} in [.])), ((var X#2),A#22[(app A#23[(var X#19)] C#24[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#1 |-> X#18, E#4 |-> {E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (letrec {E#11} in S#13) S#12)]}, C#8 |-> A#22[(app A#23[(var X#19)] C#24)], A#17 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(\ X#3.S#5)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#20[X#9,(var X#18)];EE#21[X#19,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#11} in C#23[(\ X#3.S#5)]) S#12)] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(letrec {E#11} in (app C#23[(var X#2)] S#12))] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#22,C#21,A#17,C#8,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app (letrec {E#11} in C#23) S#12)]), ((var X#2),A#20[(app (letrec {E#11} in C#23) S#12)]), (S#5,A#20[(app (letrec {E#11} in C#23) S#12)]), (S#12,(letrec {E#11} in [.])), ((var X#2),A#20[(app (letrec {E#11} in C#23[[.]]) S#12)]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[(app (letrec {E#11} in C#23) S#12)], C#21 |-> (app (letrec {E#11} in C#23) S#12), C#22 |-> (letrec {E#11} in C#23), S#13 |-> C#23[(var X#2)]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#11} in C#23[(var X#2)]) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app (letrec {E#11} in C#23[(\ X#3.S#5)]) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#11} in C#23[(var X#2)]) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#11} in (app C#23[(var X#2)] S#12))];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {X#24=C#23[(\ X#3.S#5)];E#26} in S#13) S#12)] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(letrec {X#24=C#23[(var X#2)];E#26} in (app S#13 S#12))] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#22,C#21,A#17,C#8,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app (letrec {X#24=C#23;E#26} in S#13) S#12)]), ((var X#2),A#20[(app (letrec {X#24=C#23;E#26} in S#13) S#12)]), (S#5,A#20[(app (letrec {X#24=C#23;E#26} in S#13) S#12)]), (S#12,(letrec {X#24=C#23[(var X#2)];E#26} in [.])), ((var X#2),A#20[(app (letrec {X#24=C#23[[.]];E#26} in S#13) S#12)]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[(app (letrec {X#24=C#23;E#26} in S#13) S#12)], C#21 |-> (app (letrec {X#24=C#23;E#26} in S#13) S#12), C#22 |-> (letrec {X#24=C#23;E#26} in S#13), E#11 |-> {X#24=C#23[(var X#2)];E#26}, E#25 |-> {E#26}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#24=C#23[(var X#2)];E#26} in S#13) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app (letrec {X#24=C#23[(\ X#3.S#5)];E#26} in S#13) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#24=C#23[(var X#2)];E#26} in S#13) S#12)];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#24=C#23[(var X#2)];E#26} in (app S#13 S#12))];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#11} in S#13) C#22[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(letrec {E#11} in (app S#13 C#22[(var X#2)]))] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#21,A#17,C#8,A#20} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app (letrec {E#11} in S#13) C#22)]), ((var X#2),A#20[(app (letrec {E#11} in S#13) C#22)]), (S#5,A#20[(app (letrec {E#11} in S#13) C#22)]), (C#22[(var X#2)],(letrec {E#11} in [.])), ((var X#2),A#20[(app (letrec {E#11} in S#13) C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> A#20, C#8 |-> A#20[(app (letrec {E#11} in S#13) C#22)], C#21 |-> (app (letrec {E#11} in S#13) C#22), S#12 |-> C#22[(var X#2)]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#11} in S#13) C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app (letrec {E#11} in S#13) C#22[(\ X#3.S#5)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#11} in S#13) C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#11} in (app S#13 C#22[(var X#2)]))];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22[(\ X#3.S#5)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= A#20[(app A#21[(letrec {E#11} in (app S#13 S#12))] C#22[(var X#2)])] ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {A#17,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22)]), ((var X#2),A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22)]), (S#5,A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22)]), (S#12,(letrec {E#11} in [.])), ((var X#2),A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22[[.]])]), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] C#22[(var X#2)])];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, C#8 |-> A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22[(\ X#3.S#5)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (letrec {E#11} in S#13) S#12)] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=A#20[(app A#21[(letrec {E#11} in (app S#13 S#12))] C#22[(var X#2)])];X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#11} in C#21[(\ X#3.S#5)]) S#12) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= (letrec {E#11} in (app C#21[(var X#2)] S#12)) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#20,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(app (letrec {E#11} in C#21) S#12)), ((var X#2),(app (letrec {E#11} in C#21) S#12)), (S#5,(app (letrec {E#11} in C#21) S#12)), (S#12,(letrec {E#11} in [.])), ((var X#2),(app (letrec {E#11} in C#21[[.]]) S#12)), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> [.], C#8 |-> (app (letrec {E#11} in C#21) S#12), C#20 |-> (letrec {E#11} in C#21), S#13 |-> C#21[(var X#2)]} and instantiated rules: (letrec {X#18=(app (letrec {E#11} in C#21[(var X#2)]) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=(app (letrec {E#11} in C#21[(\ X#3.S#5)]) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(app (letrec {E#11} in C#21[(var X#2)]) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=(letrec {E#11} in (app C#21[(var X#2)] S#12));X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {X#22=C#21[(\ X#3.S#5)];E#24} in S#13) S#12) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= (letrec {X#22=C#21[(var X#2)];E#24} in (app S#13 S#12)) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#20,C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(app (letrec {X#22=C#21;E#24} in S#13) S#12)), ((var X#2),(app (letrec {X#22=C#21;E#24} in S#13) S#12)), (S#5,(app (letrec {X#22=C#21;E#24} in S#13) S#12)), (S#12,(letrec {X#22=C#21[(var X#2)];E#24} in [.])), ((var X#2),(app (letrec {X#22=C#21[[.]];E#24} in S#13) S#12)), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> [.], C#8 |-> (app (letrec {X#22=C#21;E#24} in S#13) S#12), C#20 |-> (letrec {X#22=C#21;E#24} in S#13), E#11 |-> {X#22=C#21[(var X#2)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#18=(app (letrec {X#22=C#21[(var X#2)];E#24} in S#13) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=(app (letrec {X#22=C#21[(\ X#3.S#5)];E#24} in S#13) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(app (letrec {X#22=C#21[(var X#2)];E#24} in S#13) S#12);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=(letrec {X#22=C#21[(var X#2)];E#24} in (app S#13 S#12));X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#11} in S#13) C#20[(\ X#3.S#5)]) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) , (letrec X#18= (letrec {E#11} in (app S#13 C#20[(var X#2)])) ;X#2= (\ X#3.S#5) ;E#16 ;EE#19[X#9,(var X#18)] in A#14[(var X#9)] ) ) where Delta1 = {C#8} Delta2 = {E#11} Delta3 = {((\ X#3.S#5),(app (letrec {E#11} in S#13) C#20)), ((var X#2),(app (letrec {E#11} in S#13) C#20)), (S#5,(app (letrec {E#11} in S#13) C#20)), (C#20[(var X#2)],(letrec {E#11} in [.])), ((var X#2),(app (letrec {E#11} in S#13) C#20[[.]])), ((var X#9),A#14[[.]]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-e1-> with input rules: T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] <-cp-e1- T#7[(letrec {X#1=C#8[(\ X#3.S#5)];X#2=(\ X#3.S#5);E#4} in S#6)] and constraints: ((\ X#3.S#5),C#8), ((var X#2),C#8), (S#5,C#8) ................................................................................ (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {E#10;EE#15[X#9,(letrec {E#11} in (app S#13 S#12))]} in A#14[(var X#9)]) and constraints: E#11/= {}, (S#12,(letrec {E#11} in [.])) and letrec unification problem: Gamma ={ T#7[(letrec {X#1=C#8[(var X#2)];X#2=(\ X#3.S#5);E#4} in S#6)] =?= (letrec {E#10;EE#15[X#9,(app (letrec {E#11} in S#13) S#12)]} in A#14[(var X#9)])} Delta1= {} Delta2= {E#11} Delta3= {((\ X#3.S#5),C#8),((var X#2),C#8),(S#5,C#8),(S#12,(letrec {E#11} in [.])),((var X#2),C#8[[.]]),((var X#9),A#14[[.]]),((var X#9),A#14[[.]])} and found solution: Sol = {T#7 |-> [.], S#6 |-> A#14[(var X#9)], E#10 |-> {X#2=(\ X#3.S#5);E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {E#16;EE#19[X#9,(var X#18)]}, A#17 |-> [.], C#8 |-> (app (letrec {E#11} in S#13) C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#18=(app (letrec {E#11} in S#13) C#20[(var X#2)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) <-cp-e1- (letrec {X#18=(app (letrec {E#11} in S#13) C#20[(\ X#3.S#5)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(app (letrec {E#11} in S#13) C#20[(var X#2)]);X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) -SR,lapp3-> (letrec {X#18=(letrec {E#11} in (app S#13 C#20[(var X#2)]));X#2=(\ X#3.S#5);E#16;EE#19[X#9,(var X#18)]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] , A#11[(letrec {X#7=T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#9)] ) where Delta1 = {T#12,A#10,T#5,A#11} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#7.[.])), (T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#7=[.]} in S#9)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9)),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> A#11, T#5 |-> A#11[(app (\ X#7.S#9) T#13)], T#12 |-> (app (\ X#7.S#9) T#13), S#8 |-> T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] <-cp-in1- A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ................................................................................ A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] -SR,lbeta1-> A#11[(letrec {X#7=T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#9)] ================================================================================ Critical Pair: ( A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] , A#11[(app A#12[(letrec {X#7=S#8} in S#9)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) where Delta1 = {A#10,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13)], A#10 |-> A#11[(app A#12 T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] <-cp-in1- A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ................................................................................ A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] -SR,lbeta1-> A#11[(app A#12[(letrec {X#7=S#8} in S#9)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ================================================================================ Critical Pair: ( (app (\ X#7.S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) , (letrec {X#7=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#9) ) where Delta1 = {T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#7.[.])), (T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#7=[.]} in S#9)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9)),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> [.], T#5 |-> (app (\ X#7.S#9) T#11), S#8 |-> T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (app (\ X#7.S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) <-cp-in1- (app (\ X#7.S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ................................................................................ (app (\ X#7.S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) -SR,lbeta1-> (letrec {X#7=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#9) ================================================================================ Critical Pair: ( (letrec E#8 in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec E#8 in A#13[(letrec {X#7=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#10)] ) ) where Delta1 = {T#14,A#11,T#12,T#5,A#13} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#7.[.])), (T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15)]), A#11 |-> A#13, T#12 |-> A#13[(app (\ X#7.S#10) T#15)], T#14 |-> (app (\ X#7.S#10) T#15), S#9 |-> T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,lbeta2-> (letrec {E#8} in A#13[(letrec {X#7=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#10)]) ================================================================================ Critical Pair: ( (letrec E#8 in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec E#8 in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#11,T#12,T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15)]), T#12 |-> A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,lbeta2-> (letrec {E#8} in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec E#8 in (app (\ X#7.S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ) , (letrec E#8 in (letrec {X#7=T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#10) ) ) where Delta1 = {T#12,T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#7.[.])), (T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#8} in (app (\ X#7.S#10) T#13)), A#11 |-> [.], T#12 |-> (app (\ X#7.S#10) T#13), S#9 |-> T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) <-cp-in1- (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])) ................................................................................ (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) -SR,lbeta2-> (letrec {E#8} in (letrec {X#7=T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#10)) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#15 in A#11[(app (\ X#7.S#10) S#9)] ) , (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#15 in A#11[(letrec {X#7=S#9} in S#10)] ) ) where Delta1 = {T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#13=T#12;E#15} in A#11[(app (\ X#7.S#10) S#9)]), E#8 |-> {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in A#11[(app (\ X#7.S#10) S#9)]) <-cp-in1- (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#15} in A#11[(app (\ X#7.S#10) S#9)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in A#11[(letrec {X#7=S#9} in S#10)]) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.C#16[(\ X#2.S#4)]) S#9)]) , (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {X#7=S#9} in C#16[(var X#1)])]) ) where Delta1 = {C#15,C#14,A#11,C#6,A#13} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),A#13[(app (\ X#7.C#16) S#9)]), ((var X#1),A#13[(app (\ X#7.C#16) S#9)]), (S#4,A#13[(app (\ X#7.C#16) S#9)]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in C#16[(var X#1)])), ((var X#1),A#13[(app (\ X#7.C#16[[.]]) S#9)])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#8 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> A#13, C#6 |-> A#13[(app (\ X#7.C#16) S#9)], C#14 |-> (app (\ X#7.C#16) S#9), C#15 |-> (\ X#7.C#16), S#10 |-> C#16[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.C#16[(var X#1)]) S#9)]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.C#16[(\ X#2.S#4)]) S#9)]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.C#16[(var X#1)]) S#9)]) -SR,lbeta2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {X#7=S#9} in C#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.S#10) C#15[(\ X#2.S#4)])]) , (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {X#7=C#15[(var X#1)]} in S#10)]) ) where Delta1 = {C#14,A#11,C#6,A#13} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),A#13[(app (\ X#7.S#10) C#15)]), ((var X#1),A#13[(app (\ X#7.S#10) C#15)]), (S#4,A#13[(app (\ X#7.S#10) C#15)]), (C#15[(var X#1)],(\ X#7.[.])), (C#15[(var X#1)],(letrec {X#7=[.]} in S#10)), ((var X#1),A#13[(app (\ X#7.S#10) C#15[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#8 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> A#13, C#6 |-> A#13[(app (\ X#7.S#10) C#15)], C#14 |-> (app (\ X#7.S#10) C#15), S#9 |-> C#15[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.S#10) C#15[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.S#10) C#15[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (\ X#7.S#10) C#15[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {X#7=C#15[(var X#1)]} in S#10)]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] C#15[(var X#1)])] ) ) where Delta1 = {A#11,C#6} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15)]), ((var X#1),A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15)]), (S#4,A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15)]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#8 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, C#6 |-> A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15)], A#11 |-> A#13[(app A#14 C#15[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] C#15[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] C#15[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.C#14[(\ X#2.S#4)]) S#9)) , (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {X#7=S#9} in C#14[(var X#1)])) ) where Delta1 = {C#13,C#6} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),(app (\ X#7.C#14) S#9)), ((var X#1),(app (\ X#7.C#14) S#9)), (S#4,(app (\ X#7.C#14) S#9)), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in C#14[(var X#1)])), ((var X#1),(app (\ X#7.C#14[[.]]) S#9))} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#8 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> [.], C#6 |-> (app (\ X#7.C#14) S#9), C#13 |-> (\ X#7.C#14), S#10 |-> C#14[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.C#14[(var X#1)]) S#9)) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.C#14[(\ X#2.S#4)]) S#9)) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.C#14[(var X#1)]) S#9)) -SR,lbeta2-> (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {X#7=S#9} in C#14[(var X#1)])) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.S#10) C#13[(\ X#2.S#4)])) , (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {X#7=C#13[(var X#1)]} in S#10)) ) where Delta1 = {C#6} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),(app (\ X#7.S#10) C#13)), ((var X#1),(app (\ X#7.S#10) C#13)), (S#4,(app (\ X#7.S#10) C#13)), (C#13[(var X#1)],(\ X#7.[.])), (C#13[(var X#1)],(letrec {X#7=[.]} in S#10)), ((var X#1),(app (\ X#7.S#10) C#13[[.]]))} Delta4= {} from overlapping <-SR,lbeta2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#8 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> [.], C#6 |-> (app (\ X#7.S#10) C#13), S#9 |-> C#13[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.S#10) C#13[(var X#1)])) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.S#10) C#13[(\ X#2.S#4)])) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in (app (\ X#7.S#10) C#13[(var X#1)])) -SR,lbeta2-> (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {X#7=C#13[(var X#1)]} in S#10)) ================================================================================ Critical Pair: ( (letrec E#9 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec E#9 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#12,T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17)]), T#14 |-> A#15[(app A#16[(var X#7)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#17 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#17 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#15=T#14;E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), E#9 |-> {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17}, E#16 |-> {E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#9 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {X#8=T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11)] ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#5,A#18} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#8.[.])), (T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app (\ X#8.S#11) T#20)];E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#9}, A#17 |-> A#18, T#14 |-> A#18[(app (\ X#8.S#11) T#20)], T#19 |-> (app (\ X#8.S#11) T#20), S#10 |-> T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#18[(letrec {X#8=T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11)];E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#9 in A#12[(var X#7)] ) , (letrec X#7= A#18[(app A#19[(letrec {X#8=S#10} in S#11)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20)];E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]}, X#15 |-> X#7, E#16 |-> {E#9}, T#14 |-> A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#18[(app A#19[(letrec {X#8=S#10} in S#11)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (\ X#8.S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ;E#9 in A#12[(var X#7)] ) , (letrec X#7= (letrec {X#8=T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11) ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#8.[.])), (T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(app (\ X#8.S#11) T#18);E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#9}, A#17 |-> [.], T#14 |-> (app (\ X#8.S#11) T#18), S#10 |-> T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#9} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]);E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=(letrec {X#8=T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11);E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#9 ;EE#19[X#18,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#9 ;EE#19[X#18,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22)];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#19[X#18,[.2]]}, X#15 |-> X#7, E#16 |-> {E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#18,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#9 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#9 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {X#8=T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11)] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#5,A#20} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#8.[.])), (T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app (\ X#8.S#11) T#22)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (\ X#8.S#11) T#22)], T#21 |-> (app (\ X#8.S#11) T#22), S#10 |-> T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#20[(letrec {X#8=T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(app A#21[(letrec {X#8=S#10} in S#11)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, T#14 |-> A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#20[(app A#21[(letrec {X#8=S#10} in S#11)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {X#8=T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11) ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(\ X#8.[.])), (T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {X#8=[.]} in S#11)), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=(app (\ X#8.S#11) T#20);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (\ X#8.S#11) T#20), S#10 |-> T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=(letrec {X#8=T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} in S#11);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#14 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#15[(app A#16[(var X#7)] C#17[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;E#14 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#15[(app A#16[(var X#7)] C#17[(var X#1)])] ) ) where Delta1 = {A#12,C#6} Delta2 = {} Delta3 = {((\ X#2.S#4),A#15[(app A#16[(var X#7)] C#17)]), ((var X#1),A#15[(app A#16[(var X#7)] C#17)]), (S#4,A#15[(app A#16[(var X#7)] C#17)]), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),A#15[(app A#16[(var X#7)] C#17[[.]])]), ((var X#7),A#15[(app A#16[[.]] C#17[(var X#1)])]), ((var X#7),A#15[(app A#16[[.]] C#17[(var X#1)])])} Delta4= {} from overlapping <-SR,lbeta3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> [.], E#9 |-> {X#1=(\ X#2.S#4);E#14}, E#3 |-> {E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]}, C#6 |-> A#15[(app A#16[(var X#7)] C#17)], A#12 |-> A#15[(app A#16 C#17[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] C#17[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] C#17[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] C#17[(var X#1)])]) -SR,lbeta3-> (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#15[(app A#16[(var X#7)] C#17[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#10) ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec X#7= (\ X#8.S#10) ;E#9 in A#13[(app A#14[(\ X#8.S#10)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#11,T#12,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(\ X#8.S#10)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;X#7= (\ X#8.S#10) ;E#15 in A#11[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= (\ X#8.S#10) ;E#15 in A#11[(\ X#8.S#10)] ) ) where Delta1 = {T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#13=T#12;X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]), E#9 |-> {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15}, E#14 |-> {X#7=(\ X#8.S#10);E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) <-cp-in1- (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#10);E#15} in A#11[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) , (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) ) where Delta1 = {A#11,C#6,A#12} Delta2 = {} Delta3 = {((\ X#8.S#10),A#12[[.]]), ((var X#7),A#12[[.]]), (S#10,A#12[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#10, E#3 |-> {E#9}, A#11 |-> A#12, C#6 |-> A#12[[.]], C#13 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) , (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) ) where Delta1 = {A#11,C#6,A#12} Delta2 = {} Delta3 = {((\ X#8.S#10),A#12), ((var X#7),A#12), (S#10,A#12), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#10, E#3 |-> {E#9}, A#11 |-> A#12[[.]], C#6 |-> A#12, A#13 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#10) ;E#9 in A#12[(app A#13[(var X#7)] C#14[(\ X#8.S#10)])] ) , (letrec X#7= (\ X#8.S#10) ;E#9 in A#12[(app A#13[(\ X#8.S#10)] C#14[(var X#7)])] ) ) where Delta1 = {A#11,C#6} Delta2 = {} Delta3 = {((\ X#8.S#10),A#12[(app A#13[(var X#7)] C#14)]), ((var X#7),A#12[(app A#13[(var X#7)] C#14)]), (S#10,A#12[(app A#13[(var X#7)] C#14)]), ((var X#7),A#12[(app A#13[(var X#7)] C#14[[.]])]), ((var X#7),A#12[(app A#13[[.]] C#14[(var X#7)])])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#10, E#3 |-> {E#9}, C#6 |-> A#12[(app A#13[(var X#7)] C#14)], A#11 |-> A#12[(app A#13 C#14[(var X#7)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(app A#13[(var X#7)] C#14[(var X#7)])]) <-cp-in1- (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(app A#13[(var X#7)] C#14[(\ X#8.S#10)])]) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(app A#13[(var X#7)] C#14[(var X#7)])]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#12[(app A#13[(\ X#8.S#10)] C#14[(var X#7)])]) ================================================================================ Critical Pair: ( (letrec {X#7=(\ X#8.S#10);E#9} in (\ X#8.S#10)) , (letrec {X#7=(\ X#8.S#10);E#9} in (\ X#8.S#10)) ) where Delta1 = {} Delta2 = {} Delta3 = {((\ X#8.S#10),[.]), ((var X#7),[.]), (S#10,[.]), ((var X#7),[.]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#10, E#3 |-> {E#9}, C#6 |-> [.], A#11 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in (var X#7)) <-cp-in1- (letrec {X#7=(\ X#8.S#10);E#9} in (\ X#8.S#10)) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in (var X#7)) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in (\ X#8.S#10)) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#10) ;E#12 in A#13[(app A#14[(var X#7)] C#15[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#10) ;E#12 in A#13[(app A#14[(\ X#8.S#10)] C#15[(var X#1)])] ) ) where Delta1 = {A#11,C#6} Delta2 = {} Delta3 = {((\ X#2.S#4),A#13[(app A#14[(var X#7)] C#15)]), ((var X#1),A#13[(app A#14[(var X#7)] C#15)]), (S#4,A#13[(app A#14[(var X#7)] C#15)]), ((var X#1),A#13[(app A#14[(var X#7)] C#15[[.]])]), ((var X#7),A#13[(app A#14[[.]] C#15[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> [.], E#9 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {X#7=(\ X#8.S#10);E#12}, C#6 |-> A#13[(app A#14[(var X#7)] C#15)], A#11 |-> A#13[(app A#14 C#15[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#10);E#12} in A#13[(app A#14[(var X#7)] C#15[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#10);E#12} in A#13[(app A#14[(var X#7)] C#15[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#10);E#12} in A#13[(app A#14[(var X#7)] C#15[(var X#1)])]) -SR,cp-in1-> (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#10);E#12} in A#13[(app A#14[(\ X#8.S#10)] C#15[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(\ X#8.S#11)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#12,T#14,T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17)]), T#14 |-> A#15[(app A#16[(var X#9)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(\ X#8.S#11)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;X#7= (\ X#8.S#11) ;E#17 ;VV#13|X#9,(var X#7)| in A#12[(var X#9)] ) , (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= (\ X#8.S#11) ;E#17 ;VV#13|X#9,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {T#5} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#5 |-> (letrec {X#15=T#14;X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]), E#10 |-> {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17}, E#16 |-> {X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) <-cp-in1- (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#14[(app A#15[(var X#9)] C#16[(\ X#8.S#11)])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#14[(app A#15[(\ X#8.S#11)] C#16[(var X#7)])] ) ) where Delta1 = {A#12,C#6} Delta2 = {} Delta3 = {((\ X#8.S#11),A#14[(app A#15[(var X#9)] C#16)]), ((var X#7),A#14[(app A#15[(var X#9)] C#16)]), (S#11,A#14[(app A#15[(var X#9)] C#16)]), ((var X#7),A#14[(app A#15[(var X#9)] C#16[[.]])]), ((var X#7),[.]), ((var X#9),A#14[(app A#15[[.]] C#16[(var X#7)])]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#11, E#3 |-> {E#10;VV#13|X#9,(var X#7)|}, C#6 |-> A#14[(app A#15[(var X#9)] C#16)], A#12 |-> A#14[(app A#15 C#16[(var X#7)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#14[(app A#15[(var X#9)] C#16[(var X#7)])]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#14[(app A#15[(var X#9)] C#16[(\ X#8.S#11)])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#14[(app A#15[(var X#9)] C#16[(var X#7)])]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#14[(app A#15[(\ X#8.S#11)] C#16[(var X#7)])]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#11) ;E#14 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(var X#9)] C#17[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#11) ;E#14 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(\ X#8.S#11)] C#17[(var X#1)])] ) ) where Delta1 = {A#12,C#6} Delta2 = {} Delta3 = {((\ X#2.S#4),A#15[(app A#16[(var X#9)] C#17)]), ((var X#1),A#15[(app A#16[(var X#9)] C#17)]), (S#4,A#15[(app A#16[(var X#9)] C#17)]), ((var X#1),A#15[(app A#16[(var X#9)] C#17[[.]])]), ((var X#7),[.]), ((var X#9),A#15[(app A#16[[.]] C#17[(var X#1)])]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#5 |-> [.], E#10 |-> {X#1=(\ X#2.S#4);E#14}, E#3 |-> {X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|}, C#6 |-> A#15[(app A#16[(var X#9)] C#17)], A#12 |-> A#15[(app A#16 C#17[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] C#17[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] C#17[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] C#17[(var X#1)])]) -SR,cp-in2-> (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(\ X#8.S#11)] C#17[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(var X#7)]] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#13,T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18)]), T#15 |-> A#16[(app A#17[(var X#9)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;X#7= (\ X#8.S#11) ;E#18 ;EE#14[X#9,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#16= T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= (\ X#8.S#11) ;E#18 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#16=T#15;X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]), E#10 |-> {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#18}, E#17 |-> {X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) <-cp-in1- (letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {T#20,A#18,T#15,T#5,A#12,A#19} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#21[(app A#22[[.]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23)]];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#7)] T#23)]], T#20 |-> A#21[(app A#22[(var X#7)] T#23)], A#12 |-> A#21[(app A#22 T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];E#10} in A#13[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[A#12[(\ X#8.S#11)]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21)];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, T#15 |-> A#19[(app A#20[A#12[(var X#7)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#13[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(\ X#8.S#11)]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[(\ X#8.S#11)] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#19[(app A#20[[.]] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21)];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#7)] T#21)], A#12 |-> A#19[(app A#20 T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#13[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(\ X#8.S#11)] T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#10 ;EE#20[X#19,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#10 ;EE#20[X#19,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23)];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#20[X#19,[.2]]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#19,A#12[(var X#7)]]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#20[X#19,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) <-cp-in1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#8.S#11)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {T#22,A#18,T#15,T#5,A#12,A#21} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#23[(app A#24[[.]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25)]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#7)] T#25)]], T#22 |-> A#23[(app A#24[(var X#7)] T#25)], A#12 |-> A#23[(app A#24 T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cp-in1- (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#8.S#11)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[A#12[(\ X#8.S#11)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23)];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, T#15 |-> A#21[(app A#22[A#12[(var X#7)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cp-in1- (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[A#12[(\ X#8.S#11)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#5,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),A#21[(app A#22[[.]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#19=A#21[(app A#22[(var X#7)] T#23)];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#7)] T#23)], A#12 |-> A#21[(app A#22 T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cp-in1- (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(var X#7)]] in A#15[(app A#16[(var X#9)] C#17[(\ X#8.S#11)])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#15[(app A#16[(var X#9)] C#17[(var X#7)])] ) ) where Delta1 = {A#13,C#6,A#12} Delta2 = {} Delta3 = {((\ X#8.S#11),A#15[(app A#16[(var X#9)] C#17)]), ((var X#7),A#15[(app A#16[(var X#9)] C#17)]), (S#11,A#15[(app A#16[(var X#9)] C#17)]), ((var X#7),A#15[(app A#16[(var X#9)] C#17[[.]])]), ((var X#7),A#12[[.]]), ((var X#9),A#15[(app A#16[[.]] C#17[(var X#7)])]), ((var X#9),A#15[(app A#16[[.]] C#17[(var X#7)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#11, E#3 |-> {E#10;EE#14[X#9,A#12[(var X#7)]]}, C#6 |-> A#15[(app A#16[(var X#9)] C#17)], A#13 |-> A#15[(app A#16 C#17[(var X#7)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#15[(app A#16[(var X#9)] C#17[(var X#7)])]) <-cp-in1- (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#15[(app A#16[(var X#9)] C#17[(\ X#8.S#11)])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#15[(app A#16[(var X#9)] C#17[(var X#7)])]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#15[(app A#16[(var X#9)] C#17[(var X#7)])]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#11) ;E#15 ;EE#14[X#9,A#12[(var X#7)]] in A#16[(app A#17[(var X#9)] C#18[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#11) ;E#15 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#16[(app A#17[(var X#9)] C#18[(var X#1)])] ) ) where Delta1 = {A#13,C#6,A#12} Delta2 = {} Delta3 = {((\ X#2.S#4),A#16[(app A#17[(var X#9)] C#18)]), ((var X#1),A#16[(app A#17[(var X#9)] C#18)]), (S#4,A#16[(app A#17[(var X#9)] C#18)]), ((var X#1),A#16[(app A#17[(var X#9)] C#18[[.]])]), ((var X#7),A#12[[.]]), ((var X#9),A#16[(app A#17[[.]] C#18[(var X#1)])]), ((var X#9),A#16[(app A#17[[.]] C#18[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#5 |-> [.], E#10 |-> {X#1=(\ X#2.S#4);E#15}, E#3 |-> {X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]}, C#6 |-> A#16[(app A#17[(var X#9)] C#18)], A#13 |-> A#16[(app A#17 C#18[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] C#18[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] C#18[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] C#18[(var X#1)])]) -SR,cp-e1-> (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#16[(app A#17[(var X#9)] C#18[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#14,T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20)]), T#17 |-> A#18[(app A#19[(var X#9)] T#20)], A#14 |-> A#18[(app A#19 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#18= T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;X#7= (\ X#8.S#12) ;E#20 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= (\ X#8.S#12) ;E#20 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=T#17;X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), E#11 |-> {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#20}, E#19 |-> {X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#22,A#20,T#17,T#5,A#13,A#21} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#23[(app A#24[[.]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25)]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#21[[.2]]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#20 |-> A#21, T#17 |-> A#21[A#23[(app A#24[(var X#10)] T#25)]], T#22 |-> A#23[(app A#24[(var X#10)] T#25)], A#13 |-> A#23[(app A#24 T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[A#13[(\ X#8.S#12)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23)];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, T#17 |-> A#21[(app A#22[A#13[(var X#10)]] T#23)], A#20 |-> A#21[(app A#22 T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(\ X#8.S#12)]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[(\ X#8.S#12)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#21[(app A#22[[.]] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23)];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#20 |-> [.], T#17 |-> A#21[(app A#22[(var X#10)] T#23)], A#13 |-> A#21[(app A#22 T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(\ X#8.S#12)] T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#11 ;EE#22[X#21,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#11 ;EE#22[X#21,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25)];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#22[X#21,[.2]]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, T#17 |-> A#23[(app A#24[(var X#21)] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#11;EE#22[X#21,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#23[X#9,(var X#21)] ;EE#24[X#22,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#23[X#9,(var X#21)] ;EE#24[X#22,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27)];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, T#17 |-> A#25[(app A#26[(var X#22)] T#27)], A#20 |-> A#25[(app A#26 T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[A#25[(app A#26[(\ X#8.S#12)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#24,A#20,T#17,T#5,A#13,A#23} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#25[(app A#26[[.]] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27)]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, A#20 |-> A#23, T#17 |-> A#23[A#25[(app A#26[(var X#10)] T#27)]], T#24 |-> A#25[(app A#26[(var X#10)] T#27)], A#13 |-> A#25[(app A#26 T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[A#25[(app A#26[(\ X#8.S#12)] T#27[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[(app A#24[A#13[(\ X#8.S#12)]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25)];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, T#17 |-> A#23[(app A#24[A#13[(var X#10)]] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[(app A#24[A#13[(\ X#8.S#12)]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#17,T#5,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#23[(app A#24[[.]] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#21=A#23[(app A#24[(var X#10)] T#25)];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, A#20 |-> [.], T#17 |-> A#23[(app A#24[(var X#10)] T#25)], A#13 |-> A#23[(app A#24 T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-cp-in1- (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#17[(app A#18[(var X#9)] C#19[(\ X#8.S#12)])] ) , (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#17[(app A#18[(var X#9)] C#19[(var X#7)])] ) ) where Delta1 = {A#14,C#6,A#13} Delta2 = {} Delta3 = {((\ X#8.S#12),A#17[(app A#18[(var X#9)] C#19)]), ((var X#7),A#17[(app A#18[(var X#9)] C#19)]), (S#12,A#17[(app A#18[(var X#9)] C#19)]), ((var X#7),A#17[(app A#18[(var X#9)] C#19[[.]])]), ((var X#7),[.]), ((var X#9),A#17[(app A#18[[.]] C#19[(var X#7)])]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#17[(app A#18[[.]] C#19[(var X#7)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> [.], X#1 |-> X#7, X#2 |-> X#8, S#4 |-> S#12, E#3 |-> {E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, C#6 |-> A#17[(app A#18[(var X#9)] C#19)], A#14 |-> A#17[(app A#18 C#19[(var X#7)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#17[(app A#18[(var X#9)] C#19[(var X#7)])]) <-cp-in1- (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#17[(app A#18[(var X#9)] C#19[(\ X#8.S#12)])]) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#17[(app A#18[(var X#9)] C#19[(var X#7)])]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#17[(app A#18[(var X#9)] C#19[(var X#7)])]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] C#20[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] C#20[(var X#1)])] ) ) where Delta1 = {A#14,C#6,A#13} Delta2 = {} Delta3 = {((\ X#2.S#4),A#18[(app A#19[(var X#9)] C#20)]), ((var X#1),A#18[(app A#19[(var X#9)] C#20)]), (S#4,A#18[(app A#19[(var X#9)] C#20)]), ((var X#1),A#18[(app A#19[(var X#9)] C#20[[.]])]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] C#20[(var X#1)])]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] C#20[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#1),C#6[[.]]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#5 |-> [.], E#11 |-> {X#1=(\ X#2.S#4);E#17}, E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, C#6 |-> A#18[(app A#19[(var X#9)] C#20)], A#14 |-> A#18[(app A#19 C#20[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] C#20[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] C#20[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] C#20[(var X#1)])]) -SR,cp-e2-> (letrec {X#1=(\ X#2.S#4);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] C#20[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec E#7 in (letrec {E#8} in T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ) , (letrec {E#7;E#8} in T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) ) where Delta1 = {T#10,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), [{E#7},(letrec {E#8} in [.])], ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),[{E#7},(letrec {E#8} in [.])],((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in (letrec {E#8} in T#11)), T#10 |-> (letrec {E#8} in T#11), S#9 |-> T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) <-cp-in1- (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])) ................................................................................ (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) -SR,llet-in1-> (letrec {E#7;E#8} in T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec E#7 in (letrec X#12= T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#14 in S#9 ) ) , (letrec X#12= T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#14 ;E#7 in S#9 ) ) where Delta1 = {T#10,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), [{E#7},(letrec {X#12=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#14} in [.])], ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),[{E#7},(letrec {E#8} in [.])],((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in (letrec {X#12=T#11;E#14} in S#9)), T#10 |-> (letrec {X#12=T#11;E#14} in S#9), E#8 |-> {X#12=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#14} in S#9)) <-cp-in1- (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#14} in S#9)) ................................................................................ (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#14} in S#9)) -SR,llet-in1-> (letrec {X#12=T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#14;E#7} in S#9) ================================================================================ Critical Pair: ( (letrec {E#7} in (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])) , (letrec {X#1=(\ X#2.S#4);E#3;E#7} in C#6[(var X#1)]) ) where Delta1 = {T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), [{E#7},(letrec {X#1=(\ X#2.S#4);E#3} in [.])], ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),[{E#7},(letrec {E#8} in [.])],((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in [.]), T#10 |-> [.], S#9 |-> C#6[(var X#1)], E#8 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {E#7} in (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])) <-cp-in1- (letrec {E#7} in (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])) ................................................................................ (letrec {E#7} in (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])) -SR,llet-in1-> (letrec {X#1=(\ X#2.S#4);E#3;E#7} in C#6[(var X#1)]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#13 in (letrec {E#8} in S#9) ) , (letrec X#11= T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#13 ;E#8 in S#9 ) ) where Delta1 = {T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), [{X#11=T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#13},(letrec {E#8} in [.])], ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),[{E#7},(letrec {E#8} in [.])],((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#11=T#10;E#13} in (letrec {E#8} in S#9)), E#7 |-> {X#11=T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#13} in (letrec {E#8} in S#9)) <-cp-in1- (letrec {X#11=T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#13} in (letrec {E#8} in S#9)) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#13} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {X#11=T#10[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#13;E#8} in S#9) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {E#8} in C#11[(\ X#2.S#4)])) , (letrec {X#1=(\ X#2.S#4);E#10;E#8} in C#11[(var X#1)]) ) where Delta1 = {C#6} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),(letrec {E#8} in C#11)), ((var X#1),(letrec {E#8} in C#11)), (S#4,(letrec {E#8} in C#11)), [{X#1=(\ X#2.S#4);E#10},(letrec {E#8} in [.])], ((var X#1),(letrec {E#8} in C#11[[.]]))} Delta4= {} from overlapping <-SR,llet-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),[{E#7},(letrec {E#8} in [.])],((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#10}, E#3 |-> {E#10}, C#6 |-> (letrec {E#8} in C#11), S#9 |-> C#11[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {E#8} in C#11[(var X#1)])) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {E#8} in C#11[(\ X#2.S#4)])) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {E#8} in C#11[(var X#1)])) -SR,llet-in1-> (letrec {X#1=(\ X#2.S#4);E#10;E#8} in C#11[(var X#1)]) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {X#12=C#11[(\ X#2.S#4)];E#14} in S#9)) , (letrec {X#1=(\ X#2.S#4);X#12=C#11[(var X#1)];E#10;E#14} in S#9) ) where Delta1 = {C#6} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),(letrec {X#12=C#11;E#14} in S#9)), ((var X#1),(letrec {X#12=C#11;E#14} in S#9)), (S#4,(letrec {X#12=C#11;E#14} in S#9)), [{X#1=(\ X#2.S#4);E#10},(letrec {X#12=C#11[(var X#1)];E#14} in [.])], ((var X#1),(letrec {X#12=C#11[[.]];E#14} in S#9))} Delta4= {} from overlapping <-SR,llet-in1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),[{E#7},(letrec {E#8} in [.])],((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#10}, E#3 |-> {E#10}, C#6 |-> (letrec {X#12=C#11;E#14} in S#9), E#8 |-> {X#12=C#11[(var X#1)];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {X#12=C#11[(var X#1)];E#14} in S#9)) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {X#12=C#11[(\ X#2.S#4)];E#14} in S#9)) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#10} in (letrec {X#12=C#11[(var X#1)];E#14} in S#9)) -SR,llet-in1-> (letrec {X#1=(\ X#2.S#4);X#12=C#11[(var X#1)];E#10;E#14} in S#9) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#8} in S#10) ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec X#7= S#10 ;E#8 ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#11,T#12,T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#1),C#6[[.]]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),C#6[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#8} in T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ;E#9 in A#11[(var X#7)] ) , (letrec X#7= T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#8 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {T#12,T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#1),C#6[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),C#6[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {E#8} in T#15);E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> (letrec {E#8} in T#15), S#10 |-> T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#9} in A#11[(var X#7)]) <-cp-in1- (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#8;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec X#16= T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#18 in S#10 ) ;E#9 in A#11[(var X#7)] ) , (letrec X#16= T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= S#10 ;E#18 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {T#12,T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (A#11[(var X#7)],(letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#18} in [.])), [{E#9},(letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#18} in [.])], ((var X#1),C#6[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),C#6[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {X#16=T#15;E#18} in S#10);E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> (letrec {X#16=T#15;E#18} in S#10), E#8 |-> {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#18} in S#10);E#9} in A#11[(var X#7)]) <-cp-in1- (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#18} in S#10);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#18} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#16=T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=S#10;E#18;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) ;E#9 in A#11[(var X#7)] ) , (letrec {X#1=(\ X#2.S#4);X#7=C#6[(var X#1)];E#3;E#9} in A#11[(var X#7)]) ) where Delta1 = {T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (A#11[(var X#7)],(letrec {X#1=(\ X#2.S#4);E#3} in [.])), [{E#9},(letrec {X#1=(\ X#2.S#4);E#3} in [.])], ((var X#1),C#6[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),C#6[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=[.];E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> [.], S#10 |-> C#6[(var X#1)], E#8 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]);E#9} in A#11[(var X#7)]) <-cp-in1- (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#1=(\ X#2.S#4);X#7=C#6[(var X#1)];E#3;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;X#7= (letrec {E#8} in S#10) ;E#15 in A#11[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= S#10 ;E#15 ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#5} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15},(letrec {E#8} in [.])], ((var X#1),C#6[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),C#6[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#13=T#12;X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]), E#9 |-> {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15}, E#14 |-> {X#7=(letrec {E#8} in S#10);E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) <-cp-in1- (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=S#10;E#15;E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;X#7= (letrec {E#8} in S#10) ;E#12 in A#13[(app A#14[(var X#7)] C#15[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;X#7= S#10 ;E#12 ;E#8 in A#13[(app A#14[(var X#7)] C#15[(var X#1)])] ) ) where Delta1 = {A#11,C#6} Delta2 = {E#8} Delta3 = {((\ X#2.S#4),A#13[(app A#14[(var X#7)] C#15)]), ((var X#1),A#13[(app A#14[(var X#7)] C#15)]), (S#4,A#13[(app A#14[(var X#7)] C#15)]), (A#13[(app A#14[(var X#7)] C#15[(var X#1)])],(letrec {E#8} in [.])), [{X#1=(\ X#2.S#4);E#12},(letrec {E#8} in [.])], ((var X#1),A#13[(app A#14[(var X#7)] C#15[[.]])]), ((var X#7),A#13[(app A#14[[.]] C#15[(var X#1)])]), ((var X#7),A#13[(app A#14[[.]] C#15[(var X#1)])])} Delta4= {} from overlapping <-SR,llet-e1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),C#6[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#5 |-> [.], E#9 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {X#7=(letrec {E#8} in S#10);E#12}, C#6 |-> A#13[(app A#14[(var X#7)] C#15)], A#11 |-> A#13[(app A#14 C#15[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);X#7=(letrec {E#8} in S#10);E#12} in A#13[(app A#14[(var X#7)] C#15[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);X#7=(letrec {E#8} in S#10);E#12} in A#13[(app A#14[(var X#7)] C#15[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);X#7=(letrec {E#8} in S#10);E#12} in A#13[(app A#14[(var X#7)] C#15[(var X#1)])]) -SR,llet-e1-> (letrec {X#1=(\ X#2.S#4);X#7=S#10;E#12;E#8} in A#13[(app A#14[(var X#7)] C#15[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec X#7= S#11 ;E#10 ;E#9 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#12,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17)]), T#14 |-> A#15[(app A#16[(var X#8)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#7= T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#10 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {E#9} in T#17);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> (letrec {E#9} in T#17), S#11 |-> T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec X#18= T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#20 in S#11 ) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#18= T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= S#11 ;E#10 ;E#20 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#10;E#20;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#20} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#20} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {X#18=T#17;E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> (letrec {X#18=T#17;E#20} in S#11), E#9 |-> {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=S#11;E#10;E#20;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#1= (\ X#2.S#4) ;X#7= C#6[(var X#1)] ;E#10 ;E#3 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#1=(\ X#2.S#4);E#10;E#3;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {X#1=(\ X#2.S#4);E#3} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {X#1=(\ X#2.S#4);E#3} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=[.];E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> [.], S#11 |-> C#6[(var X#1)], E#9 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#1=(\ X#2.S#4);X#7=C#6[(var X#1)];E#10;E#3;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;X#7= (letrec {E#9} in S#11) ;E#17 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;X#7= S#11 ;E#17 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#15=T#14;X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), E#10 |-> {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17}, E#16 |-> {X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];X#7=S#11;E#17;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;X#8= A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#10 in A#12[(var X#8)] ) , (letrec X#7= S#11 ;X#8= A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#10 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;E#9} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20)];E#10} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]}, X#15 |-> X#8, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10}, T#14 |-> A#18[(app A#19[(var X#7)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#12[(var X#8)]) <-cp-in1- (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#10 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) , (letrec X#7= S#11 ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#10 ;E#9 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;E#9;EE#19[X#18,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#19[X#18,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22)];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#19[X#18,[.2]]}, X#15 |-> X#8, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#18,(var X#7)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;E#9;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,(var X#7)] in A#12[(var X#8)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= S#11 ;E#10 ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;E#9;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=S#11;E#10;E#9;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;X#7= S#11 ;E#10 ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), ((var X#7),(letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;E#9;EE#19[X#8,(var X#18)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#10;EE#19[X#8,(var X#18)]},(letrec {E#9} in [.])], ((var X#1),C#6[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22)];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]}, T#14 |-> A#20[(app A#21[(var X#7)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-cp-in1- (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];X#7=S#11;E#10;E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;X#7= (letrec {E#9} in S#11) ;E#14 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] C#17[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;X#7= S#11 ;E#14 ;E#9 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] C#17[(var X#1)])] ) ) where Delta1 = {A#12,C#6} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),A#15[(app A#16[(var X#8)] C#17)]), ((var X#1),A#15[(app A#16[(var X#8)] C#17)]), (S#4,A#15[(app A#16[(var X#8)] C#17)]), ((var X#7),(letrec {X#1=(\ X#2.S#4);E#14;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#15[(app A#16[(var X#8)] C#17[(var X#1)])],(letrec {E#9} in [.])), [{X#1=(\ X#2.S#4);E#14;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),A#15[(app A#16[(var X#8)] C#17[[.]])]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] C#17[(var X#1)])]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] C#17[(var X#1)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),C#6[[.]]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#5 |-> [.], E#10 |-> {X#1=(\ X#2.S#4);E#14}, E#3 |-> {X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]}, C#6 |-> A#15[(app A#16[(var X#8)] C#17)], A#12 |-> A#15[(app A#16 C#17[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] C#17[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] C#17[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] C#17[(var X#1)])]) -SR,llet-e2-> (letrec {X#1=(\ X#2.S#4);X#7=S#11;E#14;E#9;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] C#17[(var X#1)])]) ================================================================================ Critical Pair: ( A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#8)] , A#11[(letrec E#7 in (app T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#8) )] ) where Delta1 = {T#13,T#12,A#10,T#5,A#11} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {E#7} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> A#11, T#5 |-> A#11[(app (letrec {E#7} in T#14) S#8)], T#12 |-> (app (letrec {E#7} in T#14) S#8), T#13 |-> (letrec {E#7} in T#14), S#9 |-> T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#8)] <-cp-in1- A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#8)] ................................................................................ A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#8)] -SR,lapp1-> A#11[(letrec {E#7} in (app T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#17 in S#9 ) S#8)] , A#11[(letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#17 in (app S#9 S#8) )] ) where Delta1 = {T#13,T#12,A#10,T#5,A#11} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> A#11, T#5 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#9) S#8)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#9) S#8), T#13 |-> (letrec {X#15=T#14;E#17} in S#9), E#7 |-> {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17}, E#16 |-> {E#17}} and instantiated rules: A#11[(app (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in S#9) S#8)] <-cp-in1- A#11[(app (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#17} in S#9) S#8)] ................................................................................ A#11[(app (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in S#9) S#8)] -SR,lapp1-> A#11[(letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in (app S#9 S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#8)] , A#11[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#8))] ) where Delta1 = {T#12,A#10,T#5,A#11} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> A#11, T#5 |-> A#11[(app [.] S#8)], T#12 |-> (app [.] S#8), T#13 |-> [.], S#9 |-> C#6[(var X#1)], E#7 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: A#11[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#8)] <-cp-in1- A#11[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#8)] ................................................................................ A#11[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#8)] -SR,lapp1-> A#11[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] , A#11[(letrec E#7 in (app S#9 T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) )] ) where Delta1 = {T#12,A#10,T#5,A#11} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> A#11, T#5 |-> A#11[(app (letrec {E#7} in S#9) T#13)], T#12 |-> (app (letrec {E#7} in S#9) T#13), S#8 |-> T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] <-cp-in1- A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ................................................................................ A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] -SR,lapp1-> A#11[(letrec {E#7} in (app S#9 T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]))] ================================================================================ Critical Pair: ( A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] , A#11[(app A#12[(letrec {E#7} in (app S#9 S#8))] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) where Delta1 = {A#10,T#5} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {E#7} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13)], A#10 |-> A#11[(app A#12 T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] <-cp-in1- A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ................................................................................ A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] -SR,lapp1-> A#11[(app A#12[(letrec {E#7} in (app S#9 S#8))] T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ================================================================================ Critical Pair: ( (app (letrec {E#7} in T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#8) , (letrec E#7 in (app T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#8) ) ) where Delta1 = {T#11,T#5} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {E#7} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> [.], T#5 |-> (app (letrec {E#7} in T#12) S#8), T#11 |-> (letrec {E#7} in T#12), S#9 |-> T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (app (letrec {E#7} in T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#8) <-cp-in1- (app (letrec {E#7} in T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#8) ................................................................................ (app (letrec {E#7} in T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#8) -SR,lapp1-> (letrec {E#7} in (app T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#8)) ================================================================================ Critical Pair: ( (app (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#15 in S#9 ) S#8) , (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#15 in (app S#9 S#8) ) ) where Delta1 = {T#11,T#5} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> [.], T#5 |-> (app (letrec {X#13=T#12;E#15} in S#9) S#8), T#11 |-> (letrec {X#13=T#12;E#15} in S#9), E#7 |-> {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15}, E#14 |-> {E#15}} and instantiated rules: (app (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in S#9) S#8) <-cp-in1- (app (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#15} in S#9) S#8) ................................................................................ (app (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in S#9) S#8) -SR,lapp1-> (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in (app S#9 S#8)) ================================================================================ Critical Pair: ( (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#8) , (letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#8)) ) where Delta1 = {T#5} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#8,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> [.], T#5 |-> (app [.] S#8), T#11 |-> [.], S#9 |-> C#6[(var X#1)], E#7 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#8) <-cp-in1- (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#8) ................................................................................ (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#8) -SR,lapp1-> (letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#8)) ================================================================================ Critical Pair: ( (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) , (letrec E#7 in (app S#9 T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) ) ) where Delta1 = {T#5} Delta2 = {E#7} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#8,(letrec {E#7} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {A#10 |-> [.], T#5 |-> (app (letrec {E#7} in S#9) T#11), S#8 |-> T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) <-cp-in1- (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ................................................................................ (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) -SR,lapp1-> (letrec {E#7} in (app S#9 T#11[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#9)] ) , (letrec E#7 in A#13[(letrec E#8 in (app T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#9) )] ) ) where Delta1 = {T#15,T#14,A#11,T#12,T#5,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {E#8} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in A#13[(app (letrec {E#8} in T#16) S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {E#8} in T#16) S#9)], T#14 |-> (app (letrec {E#8} in T#16) S#9), T#15 |-> (letrec {E#8} in T#16), S#10 |-> T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#9)]) <-cp-in1- (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {E#8} in (app T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec X#17= T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#19 in S#10 ) S#9)] ) , (letrec E#7 in A#13[(letrec X#17= T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#19 in (app S#10 S#9) )] ) ) where Delta1 = {T#15,T#14,A#11,T#12,T#5,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {X#17=T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#19} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in A#13[(app (letrec {X#17=T#16;E#19} in S#10) S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {X#17=T#16;E#19} in S#10) S#9)], T#14 |-> (app (letrec {X#17=T#16;E#19} in S#10) S#9), T#15 |-> (letrec {X#17=T#16;E#19} in S#10), E#8 |-> {X#17=T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#19} in S#10) S#9)]) <-cp-in1- (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#19} in S#10) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#19} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {X#17=T#16[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#19} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#9)] ) , (letrec E#7 in A#13[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#9))] ) ) where Delta1 = {T#14,A#11,T#12,T#5,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in A#13[(app [.] S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app [.] S#9)], T#14 |-> (app [.] S#9), T#15 |-> [.], S#10 |-> C#6[(var X#1)], E#8 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#9)]) <-cp-in1- (letrec {E#7} in A#13[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec E#7 in A#13[(letrec E#8 in (app S#10 T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) )] ) ) where Delta1 = {T#14,A#11,T#12,T#5,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {E#8} in S#10) T#15)], T#14 |-> (app (letrec {E#8} in S#10) T#15), S#9 |-> T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {E#8} in (app S#10 T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec E#7 in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#11,T#12,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {E#8} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15)]), T#12 |-> A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,lapp2-> (letrec {E#7} in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] T#15[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {E#8} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#9) ) , (letrec E#7 in (letrec E#8 in (app T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#9) ) ) ) where Delta1 = {T#13,T#12,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {E#8} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in (app (letrec {E#8} in T#14) S#9)), A#11 |-> [.], T#12 |-> (app (letrec {E#8} in T#14) S#9), T#13 |-> (letrec {E#8} in T#14), S#10 |-> T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#9)) <-cp-in1- (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {E#8} in (app T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#9))) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#17 in S#10 ) S#9) ) , (letrec E#7 in (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#17 in (app S#10 S#9) ) ) ) where Delta1 = {T#13,T#12,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in (app (letrec {X#15=T#14;E#17} in S#10) S#9)), A#11 |-> [.], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#10) S#9), T#13 |-> (letrec {X#15=T#14;E#17} in S#10), E#8 |-> {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in S#10) S#9)) <-cp-in1- (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#17} in S#10) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in S#10) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17} in (app S#10 S#9))) ================================================================================ Critical Pair: ( (letrec {E#7} in (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#9)) , (letrec {E#7} in (letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#9))) ) where Delta1 = {T#12,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in (app [.] S#9)), A#11 |-> [.], T#12 |-> (app [.] S#9), T#13 |-> [.], S#10 |-> C#6[(var X#1)], E#8 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {E#7} in (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#9)) <-cp-in1- (letrec {E#7} in (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#9))) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ) , (letrec E#7 in (letrec E#8 in (app S#10 T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) ) ) ) where Delta1 = {T#12,T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#7} in (app (letrec {E#8} in S#10) T#13)), A#11 |-> [.], T#12 |-> (app (letrec {E#8} in S#10) T#13), S#9 |-> T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) <-cp-in1- (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])) ................................................................................ (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])) -SR,lapp2-> (letrec {E#7} in (letrec {E#8} in (app S#10 T#13[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]))) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#15 in A#11[(app (letrec {E#8} in S#10) S#9)] ) , (letrec X#13= T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#15 in A#11[(letrec {E#8} in (app S#10 S#9))] ) ) where Delta1 = {T#5} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#9,(letrec {E#8} in [.])), ((var X#1),C#6[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#13=T#12;E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]), E#7 |-> {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) <-cp-in1- (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {X#13=T#12[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#15} in A#11[(letrec {E#8} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app (letrec {E#8} in C#16[(\ X#2.S#4)]) S#9)] ) , (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(letrec {E#8} in (app C#16[(var X#1)] S#9))] ) ) where Delta1 = {C#15,C#14,A#11,C#6,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),A#13[(app (letrec {E#8} in C#16) S#9)]), ((var X#1),A#13[(app (letrec {E#8} in C#16) S#9)]), (S#4,A#13[(app (letrec {E#8} in C#16) S#9)]), (S#9,(letrec {E#8} in [.])), ((var X#1),A#13[(app (letrec {E#8} in C#16[[.]]) S#9)])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> A#13, C#6 |-> A#13[(app (letrec {E#8} in C#16) S#9)], C#14 |-> (app (letrec {E#8} in C#16) S#9), C#15 |-> (letrec {E#8} in C#16), S#10 |-> C#16[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {E#8} in C#16[(var X#1)]) S#9)]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {E#8} in C#16[(\ X#2.S#4)]) S#9)]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {E#8} in C#16[(var X#1)]) S#9)]) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {E#8} in (app C#16[(var X#1)] S#9))]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app (letrec {X#17=C#16[(\ X#2.S#4)];E#19} in S#10) S#9)] ) , (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(letrec {X#17=C#16[(var X#1)];E#19} in (app S#10 S#9))] ) ) where Delta1 = {C#15,C#14,A#11,C#6,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),A#13[(app (letrec {X#17=C#16;E#19} in S#10) S#9)]), ((var X#1),A#13[(app (letrec {X#17=C#16;E#19} in S#10) S#9)]), (S#4,A#13[(app (letrec {X#17=C#16;E#19} in S#10) S#9)]), (S#9,(letrec {X#17=C#16[(var X#1)];E#19} in [.])), ((var X#1),A#13[(app (letrec {X#17=C#16[[.]];E#19} in S#10) S#9)])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> A#13, C#6 |-> A#13[(app (letrec {X#17=C#16;E#19} in S#10) S#9)], C#14 |-> (app (letrec {X#17=C#16;E#19} in S#10) S#9), C#15 |-> (letrec {X#17=C#16;E#19} in S#10), E#8 |-> {X#17=C#16[(var X#1)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {X#17=C#16[(var X#1)];E#19} in S#10) S#9)]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {X#17=C#16[(\ X#2.S#4)];E#19} in S#10) S#9)]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {X#17=C#16[(var X#1)];E#19} in S#10) S#9)]) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {X#17=C#16[(var X#1)];E#19} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app (letrec {E#8} in S#10) C#15[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(letrec {E#8} in (app S#10 C#15[(var X#1)]))] ) ) where Delta1 = {C#14,A#11,C#6,A#13} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),A#13[(app (letrec {E#8} in S#10) C#15)]), ((var X#1),A#13[(app (letrec {E#8} in S#10) C#15)]), (S#4,A#13[(app (letrec {E#8} in S#10) C#15)]), (C#15[(var X#1)],(letrec {E#8} in [.])), ((var X#1),A#13[(app (letrec {E#8} in S#10) C#15[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> A#13, C#6 |-> A#13[(app (letrec {E#8} in S#10) C#15)], C#14 |-> (app (letrec {E#8} in S#10) C#15), S#9 |-> C#15[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {E#8} in S#10) C#15[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {E#8} in S#10) C#15[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app (letrec {E#8} in S#10) C#15[(var X#1)])]) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(letrec {E#8} in (app S#10 C#15[(var X#1)]))]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;E#12 in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] C#15[(var X#1)])] ) ) where Delta1 = {A#11,C#6} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15)]), ((var X#1),A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15)]), (S#4,A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15)]), (S#9,(letrec {E#8} in [.])), ((var X#1),A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, C#6 |-> A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15)], A#11 |-> A#13[(app A#14 C#15[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] C#15[(var X#1)])]) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] C#15[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in C#14[(\ X#2.S#4)]) S#9)) , (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {E#8} in (app C#14[(var X#1)] S#9))) ) where Delta1 = {C#13,C#6} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),(app (letrec {E#8} in C#14) S#9)), ((var X#1),(app (letrec {E#8} in C#14) S#9)), (S#4,(app (letrec {E#8} in C#14) S#9)), (S#9,(letrec {E#8} in [.])), ((var X#1),(app (letrec {E#8} in C#14[[.]]) S#9))} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> [.], C#6 |-> (app (letrec {E#8} in C#14) S#9), C#13 |-> (letrec {E#8} in C#14), S#10 |-> C#14[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in C#14[(var X#1)]) S#9)) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in C#14[(\ X#2.S#4)]) S#9)) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in C#14[(var X#1)]) S#9)) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {E#8} in (app C#14[(var X#1)] S#9))) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in (app (letrec {X#15=C#14[(\ X#2.S#4)];E#17} in S#10) S#9) ) , (letrec X#1= (\ X#2.S#4) ;E#12 in (letrec {X#15=C#14[(var X#1)];E#17} in (app S#10 S#9)) ) ) where Delta1 = {C#13,C#6} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),(app (letrec {X#15=C#14;E#17} in S#10) S#9)), ((var X#1),(app (letrec {X#15=C#14;E#17} in S#10) S#9)), (S#4,(app (letrec {X#15=C#14;E#17} in S#10) S#9)), (S#9,(letrec {X#15=C#14[(var X#1)];E#17} in [.])), ((var X#1),(app (letrec {X#15=C#14[[.]];E#17} in S#10) S#9))} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> [.], C#6 |-> (app (letrec {X#15=C#14;E#17} in S#10) S#9), C#13 |-> (letrec {X#15=C#14;E#17} in S#10), E#8 |-> {X#15=C#14[(var X#1)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {X#15=C#14[(var X#1)];E#17} in S#10) S#9)) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {X#15=C#14[(\ X#2.S#4)];E#17} in S#10) S#9)) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {X#15=C#14[(var X#1)];E#17} in S#10) S#9)) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {X#15=C#14[(var X#1)];E#17} in (app S#10 S#9))) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#12 in (app (letrec {E#8} in S#10) C#13[(\ X#2.S#4)]) ) , (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {E#8} in (app S#10 C#13[(var X#1)]))) ) where Delta1 = {C#6} Delta2 = {E#7,E#8} Delta3 = {((\ X#2.S#4),(app (letrec {E#8} in S#10) C#13)), ((var X#1),(app (letrec {E#8} in S#10) C#13)), (S#4,(app (letrec {E#8} in S#10) C#13)), (C#13[(var X#1)],(letrec {E#8} in [.])), ((var X#1),(app (letrec {E#8} in S#10) C#13[[.]]))} Delta4= {} from overlapping <-SR,lapp2- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#9,(letrec {E#8} in [.])),((var X#1),C#6[[.]])} and found solution: Sol = {T#5 |-> [.], E#7 |-> {X#1=(\ X#2.S#4);E#12}, E#3 |-> {E#12}, A#11 |-> [.], C#6 |-> (app (letrec {E#8} in S#10) C#13), S#9 |-> C#13[(var X#1)]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in S#10) C#13[(var X#1)])) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in S#10) C#13[(\ X#2.S#4)])) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#12} in (app (letrec {E#8} in S#10) C#13[(var X#1)])) -SR,lapp2-> (letrec {X#1=(\ X#2.S#4);E#12} in (letrec {E#8} in (app S#10 C#13[(var X#1)]))) ================================================================================ Critical Pair: ( (letrec E#8 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ) , (letrec E#8 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ) ) where Delta1 = {A#12,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17)]), T#14 |-> A#15[(app A#16[(var X#7)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) <-cp-in1- (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])]) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#17 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#17 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#15=T#14;E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), E#8 |-> {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17}, E#16 |-> {E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=T#14[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#17;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec E#9 in (app T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#19,A#17,T#14,T#5,A#18} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app (letrec {E#9} in T#21) S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {E#9} in T#21) S#10)], T#19 |-> (app (letrec {E#9} in T#21) S#10), T#20 |-> (letrec {E#9} in T#21), S#11 |-> T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10)];E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {E#9} in (app T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec X#22= T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#24 in S#11 ) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec X#22= T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#24 in (app S#11 S#10) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#19,A#17,T#14,T#5,A#18} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app (letrec {X#22=T#21;E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#11) S#10)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#11) S#10), T#20 |-> (letrec {X#22=T#21;E#24} in S#11), E#9 |-> {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in (app S#11 S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10))] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#5,A#18} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app [.] S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app [.] S#10)], T#19 |-> (app [.] S#10), T#20 |-> [.], S#11 |-> C#6[(var X#1)], E#9 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {X#7=A#18[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10)];E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec E#9 in (app S#11 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#5,A#18} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {E#9} in S#11) T#20)], T#19 |-> (app (letrec {E#9} in S#11) T#20), S#10 |-> T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {E#9} in (app S#11 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(app A#19[(letrec {E#9} in (app S#11 S#10))] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]}, X#15 |-> X#7, E#16 |-> {E#8}, T#14 |-> A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(app A#19[(letrec {E#9} in (app S#11 S#10))] T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {E#9} in T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec E#9 in (app T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#18,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(app (letrec {E#9} in T#19) S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in T#19) S#10), T#18 |-> (letrec {E#9} in T#19), S#11 |-> T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10);E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {E#9} in (app T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec X#20= T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#22 in S#11 ) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec X#20= T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#22 in (app S#11 S#10) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#18,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#20=T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#22} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(app (letrec {X#20=T#19;E#22} in S#11) S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {X#20=T#19;E#22} in S#11) S#10), T#18 |-> (letrec {X#20=T#19;E#22} in S#11), E#9 |-> {X#20=T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {X#20=T#19[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#22} in (app S#11 S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10)) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(app [.] S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app [.] S#10), T#18 |-> [.], S#11 |-> C#6[(var X#1)], E#9 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {X#7=(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10);E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {E#9} in S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec E#9 in (app S#11 T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=(app (letrec {E#9} in S#11) T#18);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in S#11) T#18), S#10 |-> T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#8} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {E#9} in (app S#11 T#18[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#8 ;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#8 ;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22)];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#19[X#18,[.2]]}, X#15 |-> X#7, E#16 |-> {E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#8 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#8 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec E#9 in (app T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#22,T#21,A#17,T#14,T#5,A#20} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app (letrec {E#9} in T#23) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {E#9} in T#23) S#10)], T#21 |-> (app (letrec {E#9} in T#23) S#10), T#22 |-> (letrec {E#9} in T#23), S#11 |-> T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#9} in (app T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec X#24= T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#26 in S#11 ) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec X#24= T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#26 in (app S#11 S#10) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#22,T#21,A#17,T#14,T#5,A#20} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#24=T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#26} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app (letrec {X#24=T#23;E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {X#24=T#23;E#26} in S#11) S#10)], T#21 |-> (app (letrec {X#24=T#23;E#26} in S#11) S#10), T#22 |-> (letrec {X#24=T#23;E#26} in S#11), E#9 |-> {X#24=T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#26}, E#25 |-> {E#26}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#24=T#23[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#26} in (app S#11 S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10))] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#5,A#20} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app [.] S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app [.] S#10)], T#21 |-> (app [.] S#10), T#22 |-> [.], S#11 |-> C#6[(var X#1)], E#9 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec E#9 in (app S#11 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#5,A#20} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {E#9} in S#11) T#22)], T#21 |-> (app (letrec {E#9} in S#11) T#22), S#10 |-> T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#9} in (app S#11 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(app A#21[(letrec {E#9} in (app S#11 S#10))] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, T#14 |-> A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(app A#21[(letrec {E#9} in (app S#11 S#10))] T#22[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec E#9 in (app T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=(app (letrec {E#9} in T#21) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in T#21) S#10), T#20 |-> (letrec {E#9} in T#21), S#11 |-> T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {E#9} in (app T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec X#22= T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] ;E#24 in S#11 ) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec X#22= T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] ;E#24 in (app S#11 S#10) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=(app (letrec {X#22=T#21;E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {X#22=T#21;E#24} in S#11) S#10), T#20 |-> (letrec {X#22=T#21;E#24} in S#11), E#9 |-> {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {X#22=T#21[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])];E#24} in (app S#11 S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10)) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (S#10,(letrec {X#1=(\ X#2.S#4);E#3} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=(app [.] S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app [.] S#10), T#20 |-> [.], S#11 |-> C#6[(var X#1)], E#9 |-> {X#1=(\ X#2.S#4);E#3}} and instantiated rules: (letrec {X#18=(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {X#1=(\ X#2.S#4);E#3} in (app C#6[(var X#1)] S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec E#9 in (app S#11 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#5} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6), (T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])],(letrec {E#9} in [.])), ((var X#1),C#6[[.]]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> (letrec {X#18=(app (letrec {E#9} in S#11) T#20);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in S#11) T#20), S#10 |-> T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]} and instantiated rules: (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-cp-in1- (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {E#9} in (app S#11 T#20[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])]));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (\ X#2.S#4) ;E#14 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#15[(app A#16[(var X#7)] C#17[(\ X#2.S#4)])] ) , (letrec X#1= (\ X#2.S#4) ;E#14 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#15[(app A#16[(var X#7)] C#17[(var X#1)])] ) ) where Delta1 = {A#12,C#6} Delta2 = {E#9} Delta3 = {((\ X#2.S#4),A#15[(app A#16[(var X#7)] C#17)]), ((var X#1),A#15[(app A#16[(var X#7)] C#17)]), (S#4,A#15[(app A#16[(var X#7)] C#17)]), (S#10,(letrec {E#9} in [.])), ((var X#1),A#15[(app A#16[(var X#7)] C#17[[.]])]), ((var X#7),A#15[(app A#16[[.]] C#17[(var X#1)])]), ((var X#7),A#15[(app A#16[[.]] C#17[(var X#1)])])} Delta4= {} from overlapping <-SR,lapp3- . -cp-in1-> with input rules: T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] <-cp-in1- T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(\ X#2.S#4)])] and constraints: ((\ X#2.S#4),C#6), ((var X#1),C#6), (S#4,C#6) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#5[(letrec {X#1=(\ X#2.S#4);E#3} in C#6[(var X#1)])] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {((\ X#2.S#4),C#6),((var X#1),C#6),(S#4,C#6),(S#10,(letrec {E#9} in [.])),((var X#1),C#6[[.]]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#5 |-> [.], E#8 |-> {X#1=(\ X#2.S#4);E#14}, E#3 |-> {E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]}, C#6 |-> A#15[(app A#16[(var X#7)] C#17)], A#12 |-> A#15[(app A#16 C#17[(var X#1)])]} and instantiated rules: (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] C#17[(var X#1)])]) <-cp-in1- (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] C#17[(\ X#2.S#4)])]) ................................................................................ (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] C#17[(var X#1)])]) -SR,lapp3-> (letrec {X#1=(\ X#2.S#4);E#14;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#15[(app A#16[(var X#7)] C#17[(var X#1)])]) ================================================================================ Critical Pair: ( A#9[(app (\ X#5.S#7) T#11[(letrec {X#1=S#2} in S#3)])] , A#9[(letrec {X#5=T#11[(app (\ X#1.S#3) S#2)]} in S#7)] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (T#11[(app (\ X#1.S#3) S#2)],(\ X#5.[.])), (T#11[(app (\ X#1.S#3) S#2)],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (\ X#5.S#7) T#11)], T#10 |-> (app (\ X#5.S#7) T#11), S#6 |-> T#11[(app (\ X#1.S#3) S#2)]} and instantiated rules: A#9[(app (\ X#5.S#7) T#11[(app (\ X#1.S#3) S#2)])] <-lbeta1- A#9[(app (\ X#5.S#7) T#11[(letrec {X#1=S#2} in S#3)])] ................................................................................ A#9[(app (\ X#5.S#7) T#11[(app (\ X#1.S#3) S#2)])] -SR,lbeta1-> A#9[(letrec {X#5=T#11[(app (\ X#1.S#3) S#2)]} in S#7)] ================================================================================ Critical Pair: ( A#9[(letrec {X#5=S#6} in S#7)] , A#9[(letrec {X#5=S#6} in S#7)] ) where Delta1 = {A#8,T#4,A#9} Delta2 = {} Delta3 = {(S#6,(\ X#5.[.])), (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[[.]], T#10 |-> [.], S#2 |-> S#6, X#1 |-> X#5, S#3 |-> S#7} and instantiated rules: A#9[(app (\ X#5.S#7) S#6)] <-lbeta1- A#9[(letrec {X#5=S#6} in S#7)] ................................................................................ A#9[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#9[(letrec {X#5=S#6} in S#7)] ================================================================================ Critical Pair: ( A#9[(letrec {X#1=S#2} in S#3)] , A#9[(letrec {X#1=S#2} in S#3)] ) where Delta1 = {A#8,T#4,A#9} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3))} Delta4= {} from overlapping <-SR,lbeta1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> A#9[[.]], T#4 |-> A#9, A#10 |-> [.], S#6 |-> S#2, X#5 |-> X#1, S#7 |-> S#3} and instantiated rules: A#9[(app (\ X#1.S#3) S#2)] <-lbeta1- A#9[(letrec {X#1=S#2} in S#3)] ................................................................................ A#9[(app (\ X#1.S#3) S#2)] -SR,lbeta1-> A#9[(letrec {X#1=S#2} in S#3)] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {X#1=S#2} in S#3)])] , A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(app (\ X#1.S#3) S#2)])] ) where Delta1 = {A#8,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(app (\ X#1.S#3) S#2)])]} and instantiated rules: A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(app (\ X#1.S#3) S#2)])] <-lbeta1- A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {X#1=S#2} in S#3)])] ................................................................................ A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(app (\ X#1.S#3) S#2)])] -SR,lbeta1-> A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(app (\ X#1.S#3) S#2)])] ================================================================================ Critical Pair: ( (app (\ X#5.S#7) T#9[(letrec {X#1=S#2} in S#3)]) , (letrec {X#5=T#9[(app (\ X#1.S#3) S#2)]} in S#7) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (T#9[(app (\ X#1.S#3) S#2)],(\ X#5.[.])), (T#9[(app (\ X#1.S#3) S#2)],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (\ X#5.S#7) T#9), S#6 |-> T#9[(app (\ X#1.S#3) S#2)]} and instantiated rules: (app (\ X#5.S#7) T#9[(app (\ X#1.S#3) S#2)]) <-lbeta1- (app (\ X#5.S#7) T#9[(letrec {X#1=S#2} in S#3)]) ................................................................................ (app (\ X#5.S#7) T#9[(app (\ X#1.S#3) S#2)]) -SR,lbeta1-> (letrec {X#5=T#9[(app (\ X#1.S#3) S#2)]} in S#7) ================================================================================ Critical Pair: ( (letrec {X#1=S#2} in S#3) , (letrec {X#1=S#2} in S#3) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3))} Delta4= {} from overlapping <-SR,lbeta1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {T#4 |-> [.], A#8 |-> [.], S#6 |-> S#2, X#5 |-> X#1, S#7 |-> S#3} and instantiated rules: (app (\ X#1.S#3) S#2) <-lbeta1- (letrec {X#1=S#2} in S#3) ................................................................................ (app (\ X#1.S#3) S#2) -SR,lbeta1-> (letrec {X#1=S#2} in S#3) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {X#1=S#2} in S#3)])]) , (letrec {E#6} in A#11[(letrec {X#5=T#13[(app (\ X#1.S#3) S#2)]} in S#8)]) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (T#13[(app (\ X#1.S#3) S#2)],(\ X#5.[.])), (T#13[(app (\ X#1.S#3) S#2)],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (\ X#5.S#8) T#13)], T#12 |-> (app (\ X#5.S#8) T#13), S#7 |-> T#13[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(app (\ X#1.S#3) S#2)])]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#5=T#13[(app (\ X#1.S#3) S#2)]} in S#8)]) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(letrec {X#5=S#7} in S#8)]) , (letrec {E#6} in A#11[(letrec {X#5=S#7} in S#8)]) ) where Delta1 = {A#9,T#10,T#4,A#11} Delta2 = {E#6} Delta3 = {(S#7,(\ X#5.[.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[[.]]), A#9 |-> A#11, T#10 |-> A#11[[.]], T#12 |-> [.], S#2 |-> S#7, X#1 |-> X#5, S#3 |-> S#8} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#5.S#8) S#7)]) <-lbeta1- (letrec {E#6} in A#11[(letrec {X#5=S#7} in S#8)]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(letrec {X#1=S#2} in S#3)]) , (letrec {E#6} in A#11[(letrec {X#1=S#2} in S#3)]) ) where Delta1 = {A#9,T#10,T#4,A#11} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11), A#9 |-> A#11[[.]], T#10 |-> A#11, A#12 |-> [.], S#7 |-> S#2, X#5 |-> X#1, S#8 |-> S#3} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#1.S#3) S#2)]) <-lbeta1- (letrec {E#6} in A#11[(letrec {X#1=S#2} in S#3)]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#1.S#3) S#2)]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#1=S#2} in S#3)]) ================================================================================ Critical Pair: ( (letrec E#6 in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {X#1=S#2} in S#3)])] ) , (letrec E#6 in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(app (\ X#1.S#3) S#2)])]) -SR,lbeta2-> (letrec {E#6} in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {X#1=S#2} in S#3)])) , (letrec {E#6} in (letrec {X#5=T#11[(app (\ X#1.S#3) S#2)]} in S#8)) ) where Delta1 = {T#10,T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (T#11[(app (\ X#1.S#3) S#2)],(\ X#5.[.])), (T#11[(app (\ X#1.S#3) S#2)],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (\ X#5.S#8) T#11)), A#9 |-> [.], T#10 |-> (app (\ X#5.S#8) T#11), S#7 |-> T#11[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#6} in (app (\ X#5.S#8) T#11[(app (\ X#1.S#3) S#2)])) <-lbeta1- (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {X#1=S#2} in S#3)])) ................................................................................ (letrec {E#6} in (app (\ X#5.S#8) T#11[(app (\ X#1.S#3) S#2)])) -SR,lbeta2-> (letrec {E#6} in (letrec {X#5=T#11[(app (\ X#1.S#3) S#2)]} in S#8)) ================================================================================ Critical Pair: ( (letrec {E#6} in (letrec {X#1=S#2} in S#3)) , (letrec {E#6} in (letrec {X#1=S#2} in S#3)) ) where Delta1 = {T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in [.]), T#10 |-> [.], A#9 |-> [.], S#7 |-> S#2, X#5 |-> X#1, S#8 |-> S#3} and instantiated rules: (letrec {E#6} in (app (\ X#1.S#3) S#2)) <-lbeta1- (letrec {E#6} in (letrec {X#1=S#2} in S#3)) ................................................................................ (letrec {E#6} in (app (\ X#1.S#3) S#2)) -SR,lbeta2-> (letrec {E#6} in (letrec {X#1=S#2} in S#3)) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=S#2} in S#3)] ;E#13 in A#9[(app (\ X#5.S#8) S#7)] ) , (letrec X#11= T#10[(app (\ X#1.S#3) S#2)] ;E#13 in A#9[(letrec {X#5=S#7} in S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (\ X#5.S#8) S#7)]), E#6 |-> {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) <-lbeta1- (letrec {X#11=T#10[(letrec {X#1=S#2} in S#3)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in A#9[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in S#3)])] ) , (letrec E#7 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])]), ((var X#5),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#2} in S#3)] ;E#15 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(app (\ X#1.S#3) S#2)] ;E#15 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), E#7 |-> {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in S#3)])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#6=T#18[(app (\ X#1.S#3) S#2)]} in S#9)] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (T#18[(app (\ X#1.S#3) S#2)],(\ X#6.[.])), (T#18[(app (\ X#1.S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (\ X#6.S#9) T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16, T#12 |-> A#16[(app (\ X#6.S#9) T#18)], T#17 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(app (\ X#1.S#3) S#2)])];E#7} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in S#3)])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(app (\ X#1.S#3) S#2)])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#6=T#18[(app (\ X#1.S#3) S#2)]} in S#9)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(letrec {X#6=S#8} in S#9)];E#7} in A#10[(var X#5)]) , (letrec {X#5=A#16[(letrec {X#6=S#8} in S#9)];E#7} in A#10[(var X#5)]) ) where Delta1 = {A#15,T#12,T#4,A#16} Delta2 = {} Delta3 = {(S#8,(\ X#6.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[[.]];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16, T#12 |-> A#16[[.]], T#17 |-> [.], S#2 |-> S#8, X#1 |-> X#6, S#3 |-> S#9} and instantiated rules: (letrec {X#5=A#16[(app (\ X#6.S#9) S#8)];E#7} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(letrec {X#6=S#8} in S#9)];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#6.S#9) S#8)];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#6=S#8} in S#9)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(letrec {X#1=S#2} in S#3)];E#7} in A#10[(var X#5)]) , (letrec {X#5=A#16[(letrec {X#1=S#2} in S#3)];E#7} in A#10[(var X#5)]) ) where Delta1 = {A#15,T#12,T#4,A#16} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16;E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16[[.]], T#12 |-> A#16, A#17 |-> [.], S#8 |-> S#2, X#6 |-> X#1, S#9 |-> S#3} and instantiated rules: (letrec {X#5=A#16[(app (\ X#1.S#3) S#2)];E#7} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(letrec {X#1=S#2} in S#3)];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#1.S#3) S#2)];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#1=S#2} in S#3)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {X#1=S#2} in S#3)])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(app (\ X#1.S#3) S#2)])] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(app (\ X#1.S#3) S#2)])]}, X#13 |-> X#5, E#14 |-> {E#7}, T#12 |-> A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(app (\ X#1.S#3) S#2)])];E#7} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {X#1=S#2} in S#3)])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(app (\ X#1.S#3) S#2)])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(app (\ X#1.S#3) S#2)])];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (\ X#6.S#9) T#16[(letrec {X#1=S#2} in S#3)]) ;E#7 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#6=T#16[(app (\ X#1.S#3) S#2)]} in S#9) ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (T#16[(app (\ X#1.S#3) S#2)],(\ X#6.[.])), (T#16[(app (\ X#1.S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (\ X#6.S#9) T#16);E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#16), S#8 |-> T#16[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=(app (\ X#6.S#9) T#16[(app (\ X#1.S#3) S#2)]);E#7} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {X#1=S#2} in S#3)]);E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (\ X#6.S#9) T#16[(app (\ X#1.S#3) S#2)]);E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=(letrec {X#6=T#16[(app (\ X#1.S#3) S#2)]} in S#9);E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {X#1=S#2} in S#3);E#7} in A#10[(var X#5)]) , (letrec {X#5=(letrec {X#1=S#2} in S#3);E#7} in A#10[(var X#5)]) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=[.];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#7}, T#12 |-> [.], A#15 |-> [.], S#8 |-> S#2, X#6 |-> X#1, S#9 |-> S#3} and instantiated rules: (letrec {X#5=(app (\ X#1.S#3) S#2);E#7} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=(letrec {X#1=S#2} in S#3);E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (\ X#1.S#3) S#2);E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=(letrec {X#1=S#2} in S#3);E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in S#3)])] ;E#7 ;EE#17[X#16,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])] ;E#7 ;EE#17[X#16,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in S#3)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#16,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in S#3)])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in S#3)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (\ X#6.S#9) T#20[(letrec {X#1=S#2} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#6=T#20[(app (\ X#1.S#3) S#2)]} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (T#20[(app (\ X#1.S#3) S#2)],(\ X#6.[.])), (T#20[(app (\ X#1.S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (\ X#6.S#9) T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (\ X#6.S#9) T#20)], T#19 |-> (app (\ X#6.S#9) T#20), S#8 |-> T#20[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {X#1=S#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#6=T#20[(app (\ X#1.S#3) S#2)]} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(letrec {X#6=S#8} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#6=S#8} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4,A#18} Delta2 = {} Delta3 = {(S#8,(\ X#6.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[[.]];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[[.]], T#19 |-> [.], S#2 |-> S#8, X#1 |-> X#6, S#3 |-> S#9} and instantiated rules: (letrec {X#16=A#18[(app (\ X#6.S#9) S#8)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(letrec {X#6=S#8} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#6.S#9) S#8)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#6=S#8} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(letrec {X#1=S#2} in S#3)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#1=S#2} in S#3)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4,A#18} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18;E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18[[.]], T#12 |-> A#18, A#19 |-> [.], S#8 |-> S#2, X#6 |-> X#1, S#9 |-> S#3} and instantiated rules: (letrec {X#16=A#18[(app (\ X#1.S#3) S#2)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(letrec {X#1=S#2} in S#3)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#1.S#3) S#2)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#1=S#2} in S#3)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {X#1=S#2} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(app (\ X#1.S#3) S#2)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(app (\ X#1.S#3) S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {X#1=S#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(app (\ X#1.S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in S#3)]) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#6=T#18[(app (\ X#1.S#3) S#2)]} in S#9) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (T#18[(app (\ X#1.S#3) S#2)],(\ X#6.[.])), (T#18[(app (\ X#1.S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (\ X#6.S#9) T#18);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#16=(app (\ X#6.S#9) T#18[(app (\ X#1.S#3) S#2)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in S#3)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (\ X#6.S#9) T#18[(app (\ X#1.S#3) S#2)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=(letrec {X#6=T#18[(app (\ X#1.S#3) S#2)]} in S#9);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (letrec {X#1=S#2} in S#3) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#1=S#2} in S#3) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), (S#2,(\ X#1.[.])), (S#2,(letrec {X#1=[.]} in S#3)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=[.];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, T#12 |-> [.], A#15 |-> [.], S#8 |-> S#2, X#6 |-> X#1, S#9 |-> S#3} and instantiated rules: (letrec {X#16=(app (\ X#1.S#3) S#2);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=(letrec {X#1=S#2} in S#3);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (\ X#1.S#3) S#2);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=(letrec {X#1=S#2} in S#3);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(\ X#6.S#8)] T#13[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#11[(app A#12[[.]] T#13[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,cp-in1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(\ X#6.S#8)] T#13[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=S#2} in S#3)] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(app (\ X#1.S#3) S#2)] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(\ X#6.S#8)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13}, E#12 |-> {X#5=(\ X#6.S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) <-lbeta1- (letrec {X#11=T#10[(letrec {X#1=S#2} in S#3)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#8);E#13} in A#9[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(\ X#6.S#9)] T#15[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(app (\ X#1.S#3) S#2)])]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(\ X#6.S#9)] T#15[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#2} in S#3)] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(var X#7)] ) , (letrec X#13= T#12[(app (\ X#1.S#3) S#2)] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(\ X#6.S#9)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#10[[.]]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]), E#8 |-> {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15}, E#14 |-> {X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|}} and instantiated rules: (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) <-lbeta1- (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(var X#5)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#14[(app A#15[(var X#7)] T#16[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#11,T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#10[[.]]), ((var X#7),A#14[(app A#15[[.]] T#16[(app (\ X#1.S#3) S#2)])]), ((var X#7),A#14[(app A#15[[.]] T#16[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(app (\ X#1.S#3) S#2)])]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#14[(app A#15[(var X#7)] T#16[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=S#2} in S#3)] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#14= T#13[(app (\ X#1.S#3) S#2)] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]), E#8 |-> {X#14=T#13[(app (\ X#1.S#3) S#2)];E#16}, E#15 |-> {X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]}} and instantiated rules: (letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) <-lbeta1- (letrec {X#14=T#13[(letrec {X#1=S#2} in S#3)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in S#3)])]] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(app (\ X#1.S#3) S#2)])]] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#10,A#17} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#19[(app A#20[[.]] T#21[(app (\ X#1.S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21)]];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> A#17, T#13 |-> A#17[A#19[(app A#20[(var X#5)] T#21)]], T#18 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(app (\ X#1.S#3) S#2)])]];E#8} in A#11[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in S#3)])]];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(app (\ X#1.S#3) S#2)])]];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(app (\ X#1.S#3) S#2)])]];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {X#1=S#2} in S#3)])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(app (\ X#1.S#3) S#2)])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(app (\ X#1.S#3) S#2)])]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, T#13 |-> A#17[(app A#18[A#10[(var X#5)]] T#19)], A#16 |-> A#17[(app A#18 T#19[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(app (\ X#1.S#3) S#2)])];E#8} in A#11[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {X#1=S#2} in S#3)])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(app (\ X#1.S#3) S#2)])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(app (\ X#1.S#3) S#2)])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(var X#5)] T#19[(letrec {X#1=S#2} in S#3)])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(\ X#6.S#9)] T#19[(app (\ X#1.S#3) S#2)])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#17[(app A#18[[.]] T#19[(app (\ X#1.S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> [.], T#13 |-> A#17[(app A#18[(var X#5)] T#19)], A#10 |-> A#17[(app A#18 T#19[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(app (\ X#1.S#3) S#2)])];E#8} in A#11[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {X#1=S#2} in S#3)])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(app (\ X#1.S#3) S#2)])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(\ X#6.S#9)] T#19[(app (\ X#1.S#3) S#2)])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in S#3)])] ;E#8 ;EE#18[X#17,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(app (\ X#1.S#3) S#2)])] ;E#8 ;EE#18[X#17,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(app (\ X#1.S#3) S#2)])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#17,A#10[(var X#5)]]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(app (\ X#1.S#3) S#2)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in S#3)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(app (\ X#1.S#3) S#2)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(app (\ X#1.S#3) S#2)])];E#8;EE#18[X#17,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(app (\ X#1.S#3) S#2)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(app (\ X#1.S#3) S#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) <-lbeta1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {X#1=S#2} in S#3)])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(app (\ X#1.S#3) S#2)])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#10,A#19} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#21[(app A#22[[.]] T#23[(app (\ X#1.S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23)]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[A#21[(app A#22[(var X#5)] T#23)]], T#20 |-> A#21[(app A#22[(var X#5)] T#23)], A#10 |-> A#21[(app A#22 T#23[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(app (\ X#1.S#3) S#2)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-lbeta1- (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {X#1=S#2} in S#3)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(app (\ X#1.S#3) S#2)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(app (\ X#1.S#3) S#2)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {X#1=S#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(app (\ X#1.S#3) S#2)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(app (\ X#1.S#3) S#2)])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[A#10[(var X#5)]] T#21)], A#16 |-> A#19[(app A#20 T#21[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-lbeta1- (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {X#1=S#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(\ X#6.S#9)] T#21[(app (\ X#1.S#3) S#2)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),A#19[(app A#20[[.]] T#21[(app (\ X#1.S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(var X#5)] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> [.], T#13 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-lbeta1- (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[(\ X#6.S#9)] T#21[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {X#1=S#2} in S#3)])] ) , (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#12,T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(app (\ X#1.S#3) S#2)])]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18)]), T#15 |-> A#16[(app A#17[(var X#7)] T#18)], A#12 |-> A#16[(app A#17 T#18[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(app (\ X#1.S#3) S#2)])]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=S#2} in S#3)] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#16= T#15[(app (\ X#1.S#3) S#2)] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=T#15;X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), E#9 |-> {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18}, E#17 |-> {X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}} and instantiated rules: (letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#16=T#15[(letrec {X#1=S#2} in S#3)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in S#3)])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(app (\ X#1.S#3) S#2)])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#20,A#18,T#15,T#4,A#11,A#19} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(app (\ X#1.S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23)]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#8)] T#23)]], T#20 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(app (\ X#1.S#3) S#2)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in S#3)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(app (\ X#1.S#3) S#2)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(app (\ X#1.S#3) S#2)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {X#1=S#2} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(app (\ X#1.S#3) S#2)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(app (\ X#1.S#3) S#2)])]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, T#15 |-> A#19[(app A#20[A#11[(var X#8)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(app (\ X#1.S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {X#1=S#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(app (\ X#1.S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(app (\ X#1.S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=S#2} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(\ X#6.S#10)] T#21[(app (\ X#1.S#3) S#2)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#19[(app A#20[[.]] T#21[(app (\ X#1.S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#11 |-> A#19[(app A#20 T#21[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(app (\ X#1.S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=S#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(app (\ X#1.S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(\ X#6.S#10)] T#21[(app (\ X#1.S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in S#3)])] ;E#9 ;EE#20[X#19,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(app (\ X#1.S#3) S#2)])] ;E#9 ;EE#20[X#19,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(app (\ X#1.S#3) S#2)])];EE#20[X#19,[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(app (\ X#1.S#3) S#2)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in S#3)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(app (\ X#1.S#3) S#2)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(app (\ X#1.S#3) S#2)])];E#9;EE#20[X#19,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(app (\ X#1.S#3) S#2)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(app (\ X#1.S#3) S#2)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {X#1=S#2} in S#3)])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(app (\ X#1.S#3) S#2)])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#22,A#18,T#15,T#4,A#11,A#21} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#23[(app A#24[[.]] T#25[(app (\ X#1.S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25)]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#8)] T#25)]], T#22 |-> A#23[(app A#24[(var X#8)] T#25)], A#11 |-> A#23[(app A#24 T#25[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(app (\ X#1.S#3) S#2)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {X#1=S#2} in S#3)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(app (\ X#1.S#3) S#2)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(app (\ X#1.S#3) S#2)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {X#1=S#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(app (\ X#1.S#3) S#2)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(app (\ X#1.S#3) S#2)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[A#11[(var X#8)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {X#1=S#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[(\ X#6.S#10)] T#23[(app (\ X#1.S#3) S#2)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(app (\ X#1.S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {(S#2,(\ X#1.[.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lbeta1- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[(\ X#6.S#10)] T#23[(app (\ X#1.S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#6} in T#9[(letrec {X#1=S#2} in S#3)])) , (letrec {E#5;E#6} in T#9[(app (\ X#1.S#3) S#2)]) ) where Delta1 = {T#8,T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), [{E#5},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {E#6} in T#9)), T#8 |-> (letrec {E#6} in T#9), S#7 |-> T#9[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#5} in (letrec {E#6} in T#9[(app (\ X#1.S#3) S#2)])) <-lbeta1- (letrec {E#5} in (letrec {E#6} in T#9[(letrec {X#1=S#2} in S#3)])) ................................................................................ (letrec {E#5} in (letrec {E#6} in T#9[(app (\ X#1.S#3) S#2)])) -SR,llet-in1-> (letrec {E#5;E#6} in T#9[(app (\ X#1.S#3) S#2)]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {X#10=T#9[(letrec {X#1=S#2} in S#3)];E#12} in S#7)) , (letrec {X#10=T#9[(app (\ X#1.S#3) S#2)];E#12;E#5} in S#7) ) where Delta1 = {T#8,T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), [{E#5},(letrec {X#10=T#9[(app (\ X#1.S#3) S#2)];E#12} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {X#10=T#9;E#12} in S#7)), T#8 |-> (letrec {X#10=T#9;E#12} in S#7), E#6 |-> {X#10=T#9[(app (\ X#1.S#3) S#2)];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {E#5} in (letrec {X#10=T#9[(app (\ X#1.S#3) S#2)];E#12} in S#7)) <-lbeta1- (letrec {E#5} in (letrec {X#10=T#9[(letrec {X#1=S#2} in S#3)];E#12} in S#7)) ................................................................................ (letrec {E#5} in (letrec {X#10=T#9[(app (\ X#1.S#3) S#2)];E#12} in S#7)) -SR,llet-in1-> (letrec {X#10=T#9[(app (\ X#1.S#3) S#2)];E#12;E#5} in S#7) ================================================================================ Critical Pair: ( (letrec {X#9=T#8[(letrec {X#1=S#2} in S#3)];E#11} in (letrec {E#6} in S#7)) , (letrec {X#9=T#8[(app (\ X#1.S#3) S#2)];E#11;E#6} in S#7) ) where Delta1 = {T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), [{X#9=T#8[(app (\ X#1.S#3) S#2)];E#11},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {X#9=T#8;E#11} in (letrec {E#6} in S#7)), E#5 |-> {X#9=T#8[(app (\ X#1.S#3) S#2)];E#11}, E#10 |-> {E#11}} and instantiated rules: (letrec {X#9=T#8[(app (\ X#1.S#3) S#2)];E#11} in (letrec {E#6} in S#7)) <-lbeta1- (letrec {X#9=T#8[(letrec {X#1=S#2} in S#3)];E#11} in (letrec {E#6} in S#7)) ................................................................................ (letrec {X#9=T#8[(app (\ X#1.S#3) S#2)];E#11} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {X#9=T#8[(app (\ X#1.S#3) S#2)];E#11;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in S#3)])] ) , (letrec X#5= S#8 ;E#6 ;E#7 in A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#11[(app A#12[[.]] T#13[(app (\ X#1.S#3) S#2)])]), ((var X#5),A#11[(app A#12[[.]] T#13[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,llet-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#11[(app A#12[(var X#5)] T#13[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in T#13[(letrec {X#1=S#2} in S#3)]) ;E#7 in A#9[(var X#5)] ) , (letrec {X#5=T#13[(app (\ X#1.S#3) S#2)];E#6;E#7} in A#9[(var X#5)]) ) where Delta1 = {T#10,T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in T#13);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=(letrec {E#6} in T#13[(app (\ X#1.S#3) S#2)]);E#7} in A#9[(var X#5)]) <-lbeta1- (letrec {X#5=(letrec {E#6} in T#13[(letrec {X#1=S#2} in S#3)]);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#6} in T#13[(app (\ X#1.S#3) S#2)]);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=T#13[(app (\ X#1.S#3) S#2)];E#6;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#14=T#13[(letrec {X#1=S#2} in S#3)];E#16} in S#8) ;E#7 in A#9[(var X#5)] ) , (letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];X#5=S#8;E#16;E#7} in A#9[(var X#5)]) ) where Delta1 = {T#10,T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (A#9[(var X#5)],(letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];E#16} in [.])), [{E#7},(letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];E#16} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#14=T#13;E#16} in S#8);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(app (\ X#1.S#3) S#2)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#5=(letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];E#16} in S#8);E#7} in A#9[(var X#5)]) <-lbeta1- (letrec {X#5=(letrec {X#14=T#13[(letrec {X#1=S#2} in S#3)];E#16} in S#8);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];E#16} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#14=T#13[(app (\ X#1.S#3) S#2)];X#5=S#8;E#16;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=S#2} in S#3)] ;X#5= (letrec {E#6} in S#8) ;E#13 in A#9[(var X#5)] ) , (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=S#8;E#13;E#6} in A#9[(var X#5)]) ) where Delta1 = {T#4} Delta2 = {E#6} Delta3 = {(S#2,(\ X#1.[.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#11=T#10[(app (\ X#1.S#3) S#2)];E#13},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {(S#2,(\ X#1.[.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13}, E#12 |-> {X#5=(letrec {E#6} in S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) <-lbeta1- (letrec {X#11=T#10[(letrec {X#1=S#2} in S#3)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];X#5=S#8;E#13;E#6} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in S#3)])] ) , (letrec X#5= S#9 ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#13[(app A#14[(var X#6)] T#15[(app (\ X#1.S#3) S#2)])],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])]), ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15)]), T#12 |-> A#13[(app A#14[(var X#6)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(app (\ X#1.S#3) S#2)])]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in T#15[(letrec {X#1=S#2} in S#3)]) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= T#15[(app (\ X#1.S#3) S#2)] ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in T#15);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=(letrec {E#7} in T#15[(app (\ X#1.S#3) S#2)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-lbeta1- (letrec {X#5=(letrec {E#7} in T#15[(letrec {X#1=S#2} in S#3)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in T#15[(app (\ X#1.S#3) S#2)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=T#15[(app (\ X#1.S#3) S#2)];E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#16=T#15[(letrec {X#1=S#2} in S#3)];E#18} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= T#15[(app (\ X#1.S#3) S#2)] ;X#5= S#9 ;E#18 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#16=T#15;E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#5=(letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-lbeta1- (letrec {X#5=(letrec {X#16=T#15[(letrec {X#1=S#2} in S#3)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=T#15[(app (\ X#1.S#3) S#2)];X#5=S#9;E#18;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#2} in S#3)] ;X#5= (letrec {E#7} in S#9) ;E#15 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#13= T#12[(app (\ X#1.S#3) S#2)] ;X#5= S#9 ;E#15 ;E#7 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;E#7;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), E#8 |-> {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15}, E#14 |-> {X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]}} and instantiated rules: (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-lbeta1- (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];X#5=S#9;E#15;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in S#3)])] ;E#8 in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#16[(app A#17[(var X#5)] T#18[(app (\ X#1.S#3) S#2)])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {X#6=A#16[(app A#17[(var X#5)] T#18[(app (\ X#1.S#3) S#2)])];E#7;E#8} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#16[(app A#17[(var X#5)] T#18[(app (\ X#1.S#3) S#2)])];E#8},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18)];E#8} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(app (\ X#1.S#3) S#2)])]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8}, T#12 |-> A#16[(app A#17[(var X#5)] T#18)], A#15 |-> A#16[(app A#17 T#18[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(app (\ X#1.S#3) S#2)])];E#8} in A#10[(var X#6)]) <-lbeta1- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in S#3)])];E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(app (\ X#1.S#3) S#2)])];E#8} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#16[(app A#17[(var X#5)] T#18[(app (\ X#1.S#3) S#2)])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in S#3)])] ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])] ;E#7 ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {X#6=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#7;E#8;EE#17[X#16,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#8;EE#17[X#16,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20)];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#16,(var X#5)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) <-lbeta1- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in S#3)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#7;E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in S#3)])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])] ;X#5= S#9 ;E#7 ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) <-lbeta1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];X#5=S#9;E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in S#3)])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(app (\ X#1.S#3) S#2)])] ;X#5= S#9 ;E#7 ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), ((var X#5),(letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (\ X#1.S#3) S#2)])];E#7;E#8;EE#17[X#6,(var X#16)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#18[(app A#19[(var X#5)] T#20[(app (\ X#1.S#3) S#2)])];E#8;EE#17[X#6,(var X#16)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20)];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(app (\ X#1.S#3) S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]}, T#12 |-> A#18[(app A#19[(var X#5)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (\ X#1.S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-lbeta1- (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (\ X#1.S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (\ X#1.S#3) S#2)])];X#5=S#9;E#7;E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in T#12[(letrec {X#1=S#2} in S#3)]) S#6)] , A#9[(letrec {E#5} in (app T#12[(app (\ X#1.S#3) S#2)] S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in T#12) S#6)], T#10 |-> (app (letrec {E#5} in T#12) S#6), T#11 |-> (letrec {E#5} in T#12), S#7 |-> T#12[(app (\ X#1.S#3) S#2)]} and instantiated rules: A#9[(app (letrec {E#5} in T#12[(app (\ X#1.S#3) S#2)]) S#6)] <-lbeta1- A#9[(app (letrec {E#5} in T#12[(letrec {X#1=S#2} in S#3)]) S#6)] ................................................................................ A#9[(app (letrec {E#5} in T#12[(app (\ X#1.S#3) S#2)]) S#6)] -SR,lapp1-> A#9[(letrec {E#5} in (app T#12[(app (\ X#1.S#3) S#2)] S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];E#15} in S#7) S#6)] , A#9[(letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in (app S#7 S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (S#6,(letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {X#13=T#12;E#15} in S#7) S#6)], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#7) S#6), T#11 |-> (letrec {X#13=T#12;E#15} in S#7), E#5 |-> {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15}, E#14 |-> {E#15}} and instantiated rules: A#9[(app (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in S#7) S#6)] <-lbeta1- A#9[(app (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];E#15} in S#7) S#6)] ................................................................................ A#9[(app (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in S#7) T#11[(letrec {X#1=S#2} in S#3)])] , A#9[(letrec {E#5} in (app S#7 T#11[(app (\ X#1.S#3) S#2)]))] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (T#11[(app (\ X#1.S#3) S#2)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in S#7) T#11)], T#10 |-> (app (letrec {E#5} in S#7) T#11), S#6 |-> T#11[(app (\ X#1.S#3) S#2)]} and instantiated rules: A#9[(app (letrec {E#5} in S#7) T#11[(app (\ X#1.S#3) S#2)])] <-lbeta1- A#9[(app (letrec {E#5} in S#7) T#11[(letrec {X#1=S#2} in S#3)])] ................................................................................ A#9[(app (letrec {E#5} in S#7) T#11[(app (\ X#1.S#3) S#2)])] -SR,lapp1-> A#9[(letrec {E#5} in (app S#7 T#11[(app (\ X#1.S#3) S#2)]))] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {X#1=S#2} in S#3)])] , A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(app (\ X#1.S#3) S#2)])] ) where Delta1 = {A#8,T#4} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(app (\ X#1.S#3) S#2)])]} and instantiated rules: A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(app (\ X#1.S#3) S#2)])] <-lbeta1- A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {X#1=S#2} in S#3)])] ................................................................................ A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(app (\ X#1.S#3) S#2)])] -SR,lapp1-> A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(app (\ X#1.S#3) S#2)])] ================================================================================ Critical Pair: ( (app (letrec {E#5} in T#10[(letrec {X#1=S#2} in S#3)]) S#6) , (letrec {E#5} in (app T#10[(app (\ X#1.S#3) S#2)] S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in T#10) S#6), T#9 |-> (letrec {E#5} in T#10), S#7 |-> T#10[(app (\ X#1.S#3) S#2)]} and instantiated rules: (app (letrec {E#5} in T#10[(app (\ X#1.S#3) S#2)]) S#6) <-lbeta1- (app (letrec {E#5} in T#10[(letrec {X#1=S#2} in S#3)]) S#6) ................................................................................ (app (letrec {E#5} in T#10[(app (\ X#1.S#3) S#2)]) S#6) -SR,lapp1-> (letrec {E#5} in (app T#10[(app (\ X#1.S#3) S#2)] S#6)) ================================================================================ Critical Pair: ( (app (letrec {X#11=T#10[(letrec {X#1=S#2} in S#3)];E#13} in S#7) S#6) , (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in (app S#7 S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (S#6,(letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {X#11=T#10;E#13} in S#7) S#6), T#9 |-> (letrec {X#11=T#10;E#13} in S#7), E#5 |-> {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13}, E#12 |-> {E#13}} and instantiated rules: (app (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in S#7) S#6) <-lbeta1- (app (letrec {X#11=T#10[(letrec {X#1=S#2} in S#3)];E#13} in S#7) S#6) ................................................................................ (app (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in S#7) S#6) -SR,lapp1-> (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in (app S#7 S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#5} in S#7) T#9[(letrec {X#1=S#2} in S#3)]) , (letrec {E#5} in (app S#7 T#9[(app (\ X#1.S#3) S#2)])) ) where Delta1 = {T#4} Delta2 = {E#5} Delta3 = {(S#2,(\ X#1.[.])), (T#9[(app (\ X#1.S#3) S#2)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {(S#2,(\ X#1.[.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in S#7) T#9), S#6 |-> T#9[(app (\ X#1.S#3) S#2)]} and instantiated rules: (app (letrec {E#5} in S#7) T#9[(app (\ X#1.S#3) S#2)]) <-lbeta1- (app (letrec {E#5} in S#7) T#9[(letrec {X#1=S#2} in S#3)]) ................................................................................ (app (letrec {E#5} in S#7) T#9[(app (\ X#1.S#3) S#2)]) -SR,lapp1-> (letrec {E#5} in (app S#7 T#9[(app (\ X#1.S#3) S#2)])) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {E#6} in T#14[(letrec {X#1=S#2} in S#3)]) S#7)] ) , (letrec {E#5} in A#11[(letrec {E#6} in (app T#14[(app (\ X#1.S#3) S#2)] S#7))]) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in T#14) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in T#14) S#7)], T#12 |-> (app (letrec {E#6} in T#14) S#7), T#13 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(app (\ X#1.S#3) S#2)]) S#7)]) <-lbeta1- (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {X#1=S#2} in S#3)]) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(app (\ X#1.S#3) S#2)]) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app T#14[(app (\ X#1.S#3) S#2)] S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#2} in S#3)];E#17} in S#8) S#7)] ) , (letrec E#5 in A#11[(letrec {X#15=T#14[(app (\ X#1.S#3) S#2)];E#17} in (app S#8 S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(letrec {X#15=T#14[(app (\ X#1.S#3) S#2)];E#17} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#8) S#7), T#13 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(app (\ X#1.S#3) S#2)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(app (\ X#1.S#3) S#2)];E#17} in S#8) S#7)]) <-lbeta1- (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#2} in S#3)];E#17} in S#8) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(app (\ X#1.S#3) S#2)];E#17} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {X#15=T#14[(app (\ X#1.S#3) S#2)];E#17} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {X#1=S#2} in S#3)])] ) , (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 T#13[(app (\ X#1.S#3) S#2)]))]) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (T#13[(app (\ X#1.S#3) S#2)],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in S#8) T#13)], T#12 |-> (app (letrec {E#6} in S#8) T#13), S#7 |-> T#13[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(app (\ X#1.S#3) S#2)])]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 T#13[(app (\ X#1.S#3) S#2)]))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {X#1=S#2} in S#3)])] ) , (letrec E#5 in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(app (\ X#1.S#3) S#2)])]) -SR,lapp2-> (letrec {E#5} in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {X#1=S#2} in S#3)]) S#7)) , (letrec {E#5} in (letrec {E#6} in (app T#12[(app (\ X#1.S#3) S#2)] S#7))) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in T#12) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in T#12) S#7), T#11 |-> (letrec {E#6} in T#12), S#8 |-> T#12[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in T#12[(app (\ X#1.S#3) S#2)]) S#7)) <-lbeta1- (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {X#1=S#2} in S#3)]) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in T#12[(app (\ X#1.S#3) S#2)]) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app T#12[(app (\ X#1.S#3) S#2)] S#7))) ================================================================================ Critical Pair: ( (letrec E#5 in (app (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];E#15} in S#8) S#7) ) , (letrec E#5 in (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in (app S#8 S#7)) ) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {X#13=T#12;E#15} in S#8) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#8) S#7), T#11 |-> (letrec {X#13=T#12;E#15} in S#8), E#6 |-> {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#5} in (app (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in S#8) S#7)) <-lbeta1- (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];E#15} in S#8) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in S#8) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {X#1=S#2} in S#3)])) , (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(app (\ X#1.S#3) S#2)]))) ) where Delta1 = {T#10,T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (T#11[(app (\ X#1.S#3) S#2)],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in S#8) T#11)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in S#8) T#11), S#7 |-> T#11[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(app (\ X#1.S#3) S#2)])) <-lbeta1- (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {X#1=S#2} in S#3)])) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(app (\ X#1.S#3) S#2)])) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(app (\ X#1.S#3) S#2)]))) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=S#2} in S#3)] ;E#13 in A#9[(app (letrec {E#6} in S#8) S#7)] ) , (letrec X#11= T#10[(app (\ X#1.S#3) S#2)] ;E#13 in A#9[(letrec {E#6} in (app S#8 S#7))] ) ) where Delta1 = {T#4} Delta2 = {E#5,E#6} Delta3 = {(S#2,(\ X#1.[.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {(S#2,(\ X#1.[.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]), E#5 |-> {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) <-lbeta1- (letrec {X#11=T#10[(letrec {X#1=S#2} in S#3)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {X#11=T#10[(app (\ X#1.S#3) S#2)];E#13} in A#9[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec E#6 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in S#3)])] ) , (letrec E#6 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])]), ((var X#5),A#13[(app A#14[[.]] T#15[(app (\ X#1.S#3) S#2)])])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])]) <-lbeta1- (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in S#3)])]) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#13[(app A#14[(var X#5)] T#15[(app (\ X#1.S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=S#2} in S#3)] ;E#15 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(app (\ X#1.S#3) S#2)] ;E#15 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), E#6 |-> {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#13=T#12[(letrec {X#1=S#2} in S#3)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#13=T#12[(app (\ X#1.S#3) S#2)];E#15;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in S#3)]) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app T#19[(app (\ X#1.S#3) S#2)] S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in T#19) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in T#19) S#8)], T#17 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(app (\ X#1.S#3) S#2)]) S#8)];E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in S#3)]) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(app (\ X#1.S#3) S#2)]) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app T#19[(app (\ X#1.S#3) S#2)] S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {X#20=T#19[(letrec {X#1=S#2} in S#3)];E#22} in S#9) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in (app S#9 S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)], T#17 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {X#1=S#2} in S#3)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in S#3)])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app S#9 T#18[(app (\ X#1.S#3) S#2)]))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (T#18[(app (\ X#1.S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in S#9) T#18)], T#17 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(app (\ X#1.S#3) S#2)])];E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in S#3)])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(app (\ X#1.S#3) S#2)])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app S#9 T#18[(app (\ X#1.S#3) S#2)]))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {X#1=S#2} in S#3)])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(app (\ X#1.S#3) S#2)])] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(app (\ X#1.S#3) S#2)])]}, X#13 |-> X#5, E#14 |-> {E#6}, T#12 |-> A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(app (\ X#1.S#3) S#2)])];E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {X#1=S#2} in S#3)])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(app (\ X#1.S#3) S#2)])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(app (\ X#1.S#3) S#2)])];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in T#17[(letrec {X#1=S#2} in S#3)]) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app T#17[(app (\ X#1.S#3) S#2)] S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in T#17) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#17) S#8), T#16 |-> (letrec {E#7} in T#17), S#9 |-> T#17[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in T#17[(app (\ X#1.S#3) S#2)]) S#8);E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {X#1=S#2} in S#3)]) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in T#17[(app (\ X#1.S#3) S#2)]) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app T#17[(app (\ X#1.S#3) S#2)] S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {X#18=T#17[(letrec {X#1=S#2} in S#3)];E#20} in S#9) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#18=T#17[(app (\ X#1.S#3) S#2)];E#20} in (app S#9 S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {X#18=T#17[(app (\ X#1.S#3) S#2)];E#20} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {X#18=T#17;E#20} in S#9) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {X#18=T#17;E#20} in S#9) S#8), T#16 |-> (letrec {X#18=T#17;E#20} in S#9), E#7 |-> {X#18=T#17[(app (\ X#1.S#3) S#2)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#5=(app (letrec {X#18=T#17[(app (\ X#1.S#3) S#2)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=(app (letrec {X#18=T#17[(letrec {X#1=S#2} in S#3)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {X#18=T#17[(app (\ X#1.S#3) S#2)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {X#18=T#17[(app (\ X#1.S#3) S#2)];E#20} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in S#9) T#16[(letrec {X#1=S#2} in S#3)]) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app S#9 T#16[(app (\ X#1.S#3) S#2)])) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (T#16[(app (\ X#1.S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in S#9) T#16);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#16), S#8 |-> T#16[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(app (\ X#1.S#3) S#2)]);E#6} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {X#1=S#2} in S#3)]);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(app (\ X#1.S#3) S#2)]);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app S#9 T#16[(app (\ X#1.S#3) S#2)]));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in S#3)])] ;E#6 ;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])] ;E#6 ;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in S#3)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in S#3)])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in S#3)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (\ X#1.S#3) S#2)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in T#21[(letrec {X#1=S#2} in S#3)]) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app T#21[(app (\ X#1.S#3) S#2)] S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in T#21) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in T#21) S#8)], T#19 |-> (app (letrec {E#7} in T#21) S#8), T#20 |-> (letrec {E#7} in T#21), S#9 |-> T#21[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(app (\ X#1.S#3) S#2)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {X#1=S#2} in S#3)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(app (\ X#1.S#3) S#2)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app T#21[(app (\ X#1.S#3) S#2)] S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#2} in S#3)];E#24} in S#9) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#22=T#21[(app (\ X#1.S#3) S#2)];E#24} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {X#22=T#21[(app (\ X#1.S#3) S#2)];E#24} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#9) S#8), T#20 |-> (letrec {X#22=T#21;E#24} in S#9), E#7 |-> {X#22=T#21[(app (\ X#1.S#3) S#2)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {X#22=T#21[(app (\ X#1.S#3) S#2)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#2} in S#3)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {X#22=T#21[(app (\ X#1.S#3) S#2)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {X#22=T#21[(app (\ X#1.S#3) S#2)];E#24} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in S#9) T#20[(letrec {X#1=S#2} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app S#9 T#20[(app (\ X#1.S#3) S#2)]))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (T#20[(app (\ X#1.S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in S#9) T#20)], T#19 |-> (app (letrec {E#7} in S#9) T#20), S#8 |-> T#20[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {X#1=S#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app S#9 T#20[(app (\ X#1.S#3) S#2)]))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {X#1=S#2} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(app (\ X#1.S#3) S#2)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(app (\ X#1.S#3) S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (\ X#1.S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {X#1=S#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(app (\ X#1.S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in T#19[(letrec {X#1=S#2} in S#3)]) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app T#19[(app (\ X#1.S#3) S#2)] S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in T#19) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in T#19[(app (\ X#1.S#3) S#2)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in S#3)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in T#19[(app (\ X#1.S#3) S#2)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app T#19[(app (\ X#1.S#3) S#2)] S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {X#20=T#19[(letrec {X#1=S#2} in S#3)];E#22} in S#9) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in (app S#9 S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (S#8,(letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {X#20=T#19;E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#16=(app (letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=(app (letrec {X#20=T#19[(letrec {X#1=S#2} in S#3)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {X#20=T#19[(app (\ X#1.S#3) S#2)];E#22} in (app S#9 S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in S#3)]) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app S#9 T#18[(app (\ X#1.S#3) S#2)])) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#7} Delta3 = {(S#2,(\ X#1.[.])), (T#18[(app (\ X#1.S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lbeta1-> with input rules: T#4[(app (\ X#1.S#3) S#2)] <-lbeta1- T#4[(letrec {X#1=S#2} in S#3)] and constraints: (S#2,(\ X#1.[.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (\ X#1.S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {(S#2,(\ X#1.[.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in S#9) T#18);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(app (\ X#1.S#3) S#2)]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(app (\ X#1.S#3) S#2)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lbeta1- (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in S#3)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(app (\ X#1.S#3) S#2)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app S#9 T#18[(app (\ X#1.S#3) S#2)]));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( A#9[(app (\ X#5.S#7) T#11[(letrec {E#1} in (app S#3 S#2))])] , A#9[(letrec {X#5=T#11[(app (letrec {E#1} in S#3) S#2)]} in S#7)] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#11[(app (letrec {E#1} in S#3) S#2)],(\ X#5.[.])), (T#11[(app (letrec {E#1} in S#3) S#2)],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (\ X#5.S#7) T#11)], T#10 |-> (app (\ X#5.S#7) T#11), S#6 |-> T#11[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: A#9[(app (\ X#5.S#7) T#11[(app (letrec {E#1} in S#3) S#2)])] <-lapp1- A#9[(app (\ X#5.S#7) T#11[(letrec {E#1} in (app S#3 S#2))])] ................................................................................ A#9[(app (\ X#5.S#7) T#11[(app (letrec {E#1} in S#3) S#2)])] -SR,lbeta1-> A#9[(letrec {X#5=T#11[(app (letrec {E#1} in S#3) S#2)]} in S#7)] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1} in (app S#3 S#2))])] , A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(app (letrec {E#1} in S#3) S#2)])] ) where Delta1 = {A#8,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(app (letrec {E#1} in S#3) S#2)])] <-lapp1- A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1} in (app S#3 S#2))])] ................................................................................ A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(app (letrec {E#1} in S#3) S#2)])] -SR,lbeta1-> A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(app (letrec {E#1} in S#3) S#2)])] ================================================================================ Critical Pair: ( (app (\ X#5.S#7) T#9[(letrec {E#1} in (app S#3 S#2))]) , (letrec {X#5=T#9[(app (letrec {E#1} in S#3) S#2)]} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#9[(app (letrec {E#1} in S#3) S#2)],(\ X#5.[.])), (T#9[(app (letrec {E#1} in S#3) S#2)],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (\ X#5.S#7) T#9), S#6 |-> T#9[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (app (\ X#5.S#7) T#9[(app (letrec {E#1} in S#3) S#2)]) <-lapp1- (app (\ X#5.S#7) T#9[(letrec {E#1} in (app S#3 S#2))]) ................................................................................ (app (\ X#5.S#7) T#9[(app (letrec {E#1} in S#3) S#2)]) -SR,lbeta1-> (letrec {X#5=T#9[(app (letrec {E#1} in S#3) S#2)]} in S#7) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1} in (app S#3 S#2))])]) , (letrec E#6 in A#11[(letrec {X#5=T#13[(app (letrec {E#1} in S#3) S#2)]} in S#8)] ) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#13[(app (letrec {E#1} in S#3) S#2)],(\ X#5.[.])), (T#13[(app (letrec {E#1} in S#3) S#2)],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (\ X#5.S#8) T#13)], T#12 |-> (app (\ X#5.S#8) T#13), S#7 |-> T#13[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(app (letrec {E#1} in S#3) S#2)])]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#5=T#13[(app (letrec {E#1} in S#3) S#2)]} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#6 in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec E#6 in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(app (letrec {E#1} in S#3) S#2)])]) -SR,lbeta2-> (letrec {E#6} in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1} in (app S#3 S#2))])) , (letrec {E#6} in (letrec {X#5=T#11[(app (letrec {E#1} in S#3) S#2)]} in S#8)) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#11[(app (letrec {E#1} in S#3) S#2)],(\ X#5.[.])), (T#11[(app (letrec {E#1} in S#3) S#2)],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (\ X#5.S#8) T#11)), A#9 |-> [.], T#10 |-> (app (\ X#5.S#8) T#11), S#7 |-> T#11[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#6} in (app (\ X#5.S#8) T#11[(app (letrec {E#1} in S#3) S#2)])) <-lapp1- (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1} in (app S#3 S#2))])) ................................................................................ (letrec {E#6} in (app (\ X#5.S#8) T#11[(app (letrec {E#1} in S#3) S#2)])) -SR,lbeta2-> (letrec {E#6} in (letrec {X#5=T#11[(app (letrec {E#1} in S#3) S#2)]} in S#8)) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in (app S#3 S#2))] ;E#13 in A#9[(app (\ X#5.S#8) S#7)] ) , (letrec X#11= T#10[(app (letrec {E#1} in S#3) S#2)] ;E#13 in A#9[(letrec {X#5=S#7} in S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (\ X#5.S#8) S#7)]), E#6 |-> {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) <-lapp1- (letrec {X#11=T#10[(letrec {E#1} in (app S#3 S#2))];E#13} in A#9[(app (\ X#5.S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in A#9[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec E#7 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in (app S#3 S#2))] ;E#15 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(app (letrec {E#1} in S#3) S#2)] ;E#15 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), E#7 |-> {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (\ X#6.S#9) T#18[(letrec {E#1} in (app S#3 S#2))])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#6=T#18[(app (letrec {E#1} in S#3) S#2)]} in S#9)] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#18[(app (letrec {E#1} in S#3) S#2)],(\ X#6.[.])), (T#18[(app (letrec {E#1} in S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (\ X#6.S#9) T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16, T#12 |-> A#16[(app (\ X#6.S#9) T#18)], T#17 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(app (letrec {E#1} in S#3) S#2)])];E#7} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1} in (app S#3 S#2))])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(app (letrec {E#1} in S#3) S#2)])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#6=T#18[(app (letrec {E#1} in S#3) S#2)]} in S#9)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1} in (app S#3 S#2))])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(app (letrec {E#1} in S#3) S#2)])] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(app (letrec {E#1} in S#3) S#2)])]}, X#13 |-> X#5, E#14 |-> {E#7}, T#12 |-> A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#7} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1} in (app S#3 S#2))])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (\ X#6.S#9) T#16[(letrec {E#1} in (app S#3 S#2))]) ;E#7 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#6=T#16[(app (letrec {E#1} in S#3) S#2)]} in S#9) ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#16[(app (letrec {E#1} in S#3) S#2)],(\ X#6.[.])), (T#16[(app (letrec {E#1} in S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (\ X#6.S#9) T#16);E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#16), S#8 |-> T#16[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=(app (\ X#6.S#9) T#16[(app (letrec {E#1} in S#3) S#2)]);E#7} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1} in (app S#3 S#2))]);E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (\ X#6.S#9) T#16[(app (letrec {E#1} in S#3) S#2)]);E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=(letrec {X#6=T#16[(app (letrec {E#1} in S#3) S#2)]} in S#9);E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#7 ;EE#17[X#16,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])] ;E#7 ;EE#17[X#16,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (app S#3 S#2))])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#16,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (app S#3 S#2))])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (app S#3 S#2))])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (\ X#6.S#9) T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#6=T#20[(app (letrec {E#1} in S#3) S#2)]} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#20[(app (letrec {E#1} in S#3) S#2)],(\ X#6.[.])), (T#20[(app (letrec {E#1} in S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (\ X#6.S#9) T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (\ X#6.S#9) T#20)], T#19 |-> (app (\ X#6.S#9) T#20), S#8 |-> T#20[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1} in (app S#3 S#2))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#6=T#20[(app (letrec {E#1} in S#3) S#2)]} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(app (letrec {E#1} in S#3) S#2)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(app (letrec {E#1} in S#3) S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1} in (app S#3 S#2))])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (\ X#6.S#9) T#18[(letrec {E#1} in (app S#3 S#2))]) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#6=T#18[(app (letrec {E#1} in S#3) S#2)]} in S#9) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#18[(app (letrec {E#1} in S#3) S#2)],(\ X#6.[.])), (T#18[(app (letrec {E#1} in S#3) S#2)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (\ X#6.S#9) T#18);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#16=(app (\ X#6.S#9) T#18[(app (letrec {E#1} in S#3) S#2)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1} in (app S#3 S#2))]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (\ X#6.S#9) T#18[(app (letrec {E#1} in S#3) S#2)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=(letrec {X#6=T#18[(app (letrec {E#1} in S#3) S#2)]} in S#9);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(\ X#6.S#8)] T#13[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#11[(app A#12[[.]] T#13[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,cp-in1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(\ X#6.S#8)] T#13[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in (app S#3 S#2))] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(app (letrec {E#1} in S#3) S#2)] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(\ X#6.S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13}, E#12 |-> {X#5=(\ X#6.S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) <-lapp1- (letrec {X#11=T#10[(letrec {E#1} in (app S#3 S#2))];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#8);E#13} in A#9[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(\ X#6.S#9)] T#15[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(app (letrec {E#1} in S#3) S#2)])]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(\ X#6.S#9)] T#15[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in (app S#3 S#2))] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(var X#7)] ) , (letrec X#13= T#12[(app (letrec {E#1} in S#3) S#2)] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(\ X#6.S#9)] ) ) where Delta1 = {T#4} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#10[[.]]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]), E#8 |-> {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15}, E#14 |-> {X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|}} and instantiated rules: (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) <-lapp1- (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(var X#5)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#14[(app A#15[(var X#7)] T#16[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#11,T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#7),A#14[(app A#15[[.]] T#16[(app (letrec {E#1} in S#3) S#2)])]), ((var X#7),A#14[(app A#15[[.]] T#16[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(app (letrec {E#1} in S#3) S#2)])]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#14[(app A#15[(var X#7)] T#16[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#1} in (app S#3 S#2))] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#14= T#13[(app (letrec {E#1} in S#3) S#2)] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]), E#8 |-> {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];E#16}, E#15 |-> {X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]}} and instantiated rules: (letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) <-lapp1- (letrec {X#14=T#13[(letrec {E#1} in (app S#3 S#2))];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (app S#3 S#2))])]] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(app (letrec {E#1} in S#3) S#2)])]] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#10,A#17} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#19[(app A#20[[.]] T#21[(app (letrec {E#1} in S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21)]];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> A#17, T#13 |-> A#17[A#19[(app A#20[(var X#5)] T#21)]], T#18 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(app (letrec {E#1} in S#3) S#2)])]];E#8} in A#11[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (app S#3 S#2))])]];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(app (letrec {E#1} in S#3) S#2)])]];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(app (letrec {E#1} in S#3) S#2)])]];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1} in (app S#3 S#2))])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(app (letrec {E#1} in S#3) S#2)])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(app (letrec {E#1} in S#3) S#2)])]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, T#13 |-> A#17[(app A#18[A#10[(var X#5)]] T#19)], A#16 |-> A#17[(app A#18 T#19[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#11[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1} in (app S#3 S#2))])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(var X#5)] T#19[(letrec {E#1} in (app S#3 S#2))])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(\ X#6.S#9)] T#19[(app (letrec {E#1} in S#3) S#2)])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#17[(app A#18[[.]] T#19[(app (letrec {E#1} in S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> [.], T#13 |-> A#17[(app A#18[(var X#5)] T#19)], A#10 |-> A#17[(app A#18 T#19[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#11[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1} in (app S#3 S#2))])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(\ X#6.S#9)] T#19[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (app S#3 S#2))])] ;E#8 ;EE#18[X#17,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(app (letrec {E#1} in S#3) S#2)])] ;E#8 ;EE#18[X#17,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(app (letrec {E#1} in S#3) S#2)])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#17,A#10[(var X#5)]]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in (app S#3 S#2))])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#18[X#17,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(app (letrec {E#1} in S#3) S#2)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(app (letrec {E#1} in S#3) S#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) <-lapp1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in (app S#3 S#2))])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1} in (app S#3 S#2))])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(app (letrec {E#1} in S#3) S#2)])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#10,A#19} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#21[(app A#22[[.]] T#23[(app (letrec {E#1} in S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23)]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[A#21[(app A#22[(var X#5)] T#23)]], T#20 |-> A#21[(app A#22[(var X#5)] T#23)], A#10 |-> A#21[(app A#22 T#23[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(app (letrec {E#1} in S#3) S#2)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-lapp1- (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1} in (app S#3 S#2))])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(app (letrec {E#1} in S#3) S#2)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(app (letrec {E#1} in S#3) S#2)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(app (letrec {E#1} in S#3) S#2)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(app (letrec {E#1} in S#3) S#2)])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[A#10[(var X#5)]] T#21)], A#16 |-> A#19[(app A#20 T#21[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-lapp1- (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1} in (app S#3 S#2))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(\ X#6.S#9)] T#21[(app (letrec {E#1} in S#3) S#2)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),A#19[(app A#20[[.]] T#21[(app (letrec {E#1} in S#3) S#2)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(var X#5)] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> [.], T#13 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-lapp1- (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in (app S#3 S#2))])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[(\ X#6.S#9)] T#21[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#12,T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(app (letrec {E#1} in S#3) S#2)])]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18)]), T#15 |-> A#16[(app A#17[(var X#7)] T#18)], A#12 |-> A#16[(app A#17 T#18[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(app (letrec {E#1} in S#3) S#2)])]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {E#1} in (app S#3 S#2))] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#16= T#15[(app (letrec {E#1} in S#3) S#2)] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=T#15;X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), E#9 |-> {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18}, E#17 |-> {X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}} and instantiated rules: (letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#16=T#15[(letrec {E#1} in (app S#3 S#2))];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (app S#3 S#2))])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(app (letrec {E#1} in S#3) S#2)])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#20,A#18,T#15,T#4,A#11,A#19} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23)]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#8)] T#23)]], T#20 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(app (letrec {E#1} in S#3) S#2)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (app S#3 S#2))])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(app (letrec {E#1} in S#3) S#2)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(app (letrec {E#1} in S#3) S#2)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1} in (app S#3 S#2))])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(app (letrec {E#1} in S#3) S#2)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(app (letrec {E#1} in S#3) S#2)])]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, T#15 |-> A#19[(app A#20[A#11[(var X#8)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(app (letrec {E#1} in S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1} in (app S#3 S#2))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(app (letrec {E#1} in S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(app (letrec {E#1} in S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(var X#8)] T#21[(letrec {E#1} in (app S#3 S#2))])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(\ X#6.S#10)] T#21[(app (letrec {E#1} in S#3) S#2)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#19[(app A#20[[.]] T#21[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#11 |-> A#19[(app A#20 T#21[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(app (letrec {E#1} in S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1} in (app S#3 S#2))])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(app (letrec {E#1} in S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(\ X#6.S#10)] T#21[(app (letrec {E#1} in S#3) S#2)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (app S#3 S#2))])] ;E#9 ;EE#20[X#19,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(app (letrec {E#1} in S#3) S#2)])] ;E#9 ;EE#20[X#19,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(app (letrec {E#1} in S#3) S#2)])];EE#20[X#19,[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(app (letrec {E#1} in S#3) S#2)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in (app S#3 S#2))])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(app (letrec {E#1} in S#3) S#2)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(app (letrec {E#1} in S#3) S#2)])];E#9;EE#20[X#19,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(app (letrec {E#1} in S#3) S#2)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(app (letrec {E#1} in S#3) S#2)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in (app S#3 S#2))])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1} in (app S#3 S#2))])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(app (letrec {E#1} in S#3) S#2)])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#22,A#18,T#15,T#4,A#11,A#21} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#23[(app A#24[[.]] T#25[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25)]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#8)] T#25)]], T#22 |-> A#23[(app A#24[(var X#8)] T#25)], A#11 |-> A#23[(app A#24 T#25[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(app (letrec {E#1} in S#3) S#2)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1} in (app S#3 S#2))])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(app (letrec {E#1} in S#3) S#2)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(app (letrec {E#1} in S#3) S#2)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(app (letrec {E#1} in S#3) S#2)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(app (letrec {E#1} in S#3) S#2)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[A#11[(var X#8)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1} in (app S#3 S#2))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[(\ X#6.S#10)] T#23[(app (letrec {E#1} in S#3) S#2)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-lapp1- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in (app S#3 S#2))])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[(\ X#6.S#10)] T#23[(app (letrec {E#1} in S#3) S#2)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1} in (app S#3 S#2))])) , (letrec {E#5;E#6} in T#9[(app (letrec {E#1} in S#3) S#2)]) ) where Delta1 = {T#8,T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), [{E#5},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {E#6} in T#9)), T#8 |-> (letrec {E#6} in T#9), S#7 |-> T#9[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#5} in (letrec {E#6} in T#9[(app (letrec {E#1} in S#3) S#2)])) <-lapp1- (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1} in (app S#3 S#2))])) ................................................................................ (letrec {E#5} in (letrec {E#6} in T#9[(app (letrec {E#1} in S#3) S#2)])) -SR,llet-in1-> (letrec {E#5;E#6} in T#9[(app (letrec {E#1} in S#3) S#2)]) ================================================================================ Critical Pair: ( (letrec E#5 in (letrec {X#10=T#9[(letrec {E#1} in (app S#3 S#2))];E#12} in S#7) ) , (letrec {X#10=T#9[(app (letrec {E#1} in S#3) S#2)];E#12;E#5} in S#7) ) where Delta1 = {T#8,T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), [{E#5},(letrec {X#10=T#9[(app (letrec {E#1} in S#3) S#2)];E#12} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {X#10=T#9;E#12} in S#7)), T#8 |-> (letrec {X#10=T#9;E#12} in S#7), E#6 |-> {X#10=T#9[(app (letrec {E#1} in S#3) S#2)];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {E#5} in (letrec {X#10=T#9[(app (letrec {E#1} in S#3) S#2)];E#12} in S#7)) <-lapp1- (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1} in (app S#3 S#2))];E#12} in S#7)) ................................................................................ (letrec {E#5} in (letrec {X#10=T#9[(app (letrec {E#1} in S#3) S#2)];E#12} in S#7)) -SR,llet-in1-> (letrec {X#10=T#9[(app (letrec {E#1} in S#3) S#2)];E#12;E#5} in S#7) ================================================================================ Critical Pair: ( (letrec X#9= T#8[(letrec {E#1} in (app S#3 S#2))] ;E#11 in (letrec {E#6} in S#7) ) , (letrec {X#9=T#8[(app (letrec {E#1} in S#3) S#2)];E#11;E#6} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), [{X#9=T#8[(app (letrec {E#1} in S#3) S#2)];E#11},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {X#9=T#8;E#11} in (letrec {E#6} in S#7)), E#5 |-> {X#9=T#8[(app (letrec {E#1} in S#3) S#2)];E#11}, E#10 |-> {E#11}} and instantiated rules: (letrec {X#9=T#8[(app (letrec {E#1} in S#3) S#2)];E#11} in (letrec {E#6} in S#7)) <-lapp1- (letrec {X#9=T#8[(letrec {E#1} in (app S#3 S#2))];E#11} in (letrec {E#6} in S#7)) ................................................................................ (letrec {X#9=T#8[(app (letrec {E#1} in S#3) S#2)];E#11} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {X#9=T#8[(app (letrec {E#1} in S#3) S#2)];E#11;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec X#5= S#8 ;E#6 ;E#7 in A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#11[(app A#12[[.]] T#13[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),A#11[(app A#12[[.]] T#13[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,llet-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#11[(app A#12[(var X#5)] T#13[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in T#13[(letrec {E#1} in (app S#3 S#2))]) ;E#7 in A#9[(var X#5)] ) , (letrec {X#5=T#13[(app (letrec {E#1} in S#3) S#2)];E#6;E#7} in A#9[(var X#5)]) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in T#13);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=(letrec {E#6} in T#13[(app (letrec {E#1} in S#3) S#2)]);E#7} in A#9[(var X#5)]) <-lapp1- (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1} in (app S#3 S#2))]);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#6} in T#13[(app (letrec {E#1} in S#3) S#2)]);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=T#13[(app (letrec {E#1} in S#3) S#2)];E#6;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#14=T#13[(letrec {E#1} in (app S#3 S#2))];E#16} in S#8) ;E#7 in A#9[(var X#5)] ) , (letrec X#14= T#13[(app (letrec {E#1} in S#3) S#2)] ;X#5= S#8 ;E#16 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#9[(var X#5)],(letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];E#16} in [.])), [{E#7},(letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];E#16} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#14=T#13;E#16} in S#8);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#5=(letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];E#16} in S#8);E#7} in A#9[(var X#5)]) <-lapp1- (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1} in (app S#3 S#2))];E#16} in S#8);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];E#16} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#14=T#13[(app (letrec {E#1} in S#3) S#2)];X#5=S#8;E#16;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in (app S#3 S#2))] ;X#5= (letrec {E#6} in S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(app (letrec {E#1} in S#3) S#2)] ;X#5= S#8 ;E#13 ;E#6 in A#9[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13}, E#12 |-> {X#5=(letrec {E#6} in S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) <-lapp1- (letrec {X#11=T#10[(letrec {E#1} in (app S#3 S#2))];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];X#5=S#8;E#13;E#6} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec X#5= S#9 ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#13[(app A#14[(var X#6)] T#15[(app (letrec {E#1} in S#3) S#2)])],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15)]), T#12 |-> A#13[(app A#14[(var X#6)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(app (letrec {E#1} in S#3) S#2)])]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in T#15[(letrec {E#1} in (app S#3 S#2))]) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= T#15[(app (letrec {E#1} in S#3) S#2)] ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in T#15);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=(letrec {E#7} in T#15[(app (letrec {E#1} in S#3) S#2)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-lapp1- (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1} in (app S#3 S#2))]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in T#15[(app (letrec {E#1} in S#3) S#2)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=T#15[(app (letrec {E#1} in S#3) S#2)];E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#16=T#15[(letrec {E#1} in (app S#3 S#2))];E#18} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= T#15[(app (letrec {E#1} in S#3) S#2)] ;X#5= S#9 ;E#18 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#16=T#15;E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#5=(letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-lapp1- (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1} in (app S#3 S#2))];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=T#15[(app (letrec {E#1} in S#3) S#2)];X#5=S#9;E#18;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in (app S#3 S#2))] ;X#5= (letrec {E#7} in S#9) ;E#15 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#13= T#12[(app (letrec {E#1} in S#3) S#2)] ;X#5= S#9 ;E#15 ;E#7 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;E#7;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), E#8 |-> {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15}, E#14 |-> {X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]}} and instantiated rules: (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-lapp1- (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];X#5=S#9;E#15;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (app S#3 S#2))])] ;E#8 in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#16[(app A#17[(var X#5)] T#18[(app (letrec {E#1} in S#3) S#2)])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {X#6=A#16[(app A#17[(var X#5)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#7;E#8} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#16[(app A#17[(var X#5)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#8},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18)];E#8} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(app (letrec {E#1} in S#3) S#2)])]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8}, T#12 |-> A#16[(app A#17[(var X#5)] T#18)], A#15 |-> A#16[(app A#17 T#18[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#10[(var X#6)]) <-lapp1- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in (app S#3 S#2))])];E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#8} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#16[(app A#17[(var X#5)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])] ;E#7 ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {X#6=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;E#8;EE#17[X#16,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#17[X#16,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20)];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#16,(var X#5)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) <-lapp1- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (app S#3 S#2))])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])] ;X#5= S#9 ;E#7 ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) <-lapp1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (app S#3 S#2))])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];X#5=S#9;E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (app S#3 S#2))])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(app (letrec {E#1} in S#3) S#2)])] ;X#5= S#9 ;E#7 ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#5),(letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#7;E#8;EE#17[X#6,(var X#16)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#18[(app A#19[(var X#5)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#8;EE#17[X#6,(var X#16)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20)];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(app (letrec {E#1} in S#3) S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]}, T#12 |-> A#18[(app A#19[(var X#5)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (letrec {E#1} in S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-lapp1- (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in (app S#3 S#2))])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (letrec {E#1} in S#3) S#2)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(app (letrec {E#1} in S#3) S#2)])];X#5=S#9;E#7;E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in T#12[(letrec {E#1} in (app S#3 S#2))]) S#6)] , A#9[(letrec {E#5} in (app T#12[(app (letrec {E#1} in S#3) S#2)] S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in T#12) S#6)], T#10 |-> (app (letrec {E#5} in T#12) S#6), T#11 |-> (letrec {E#5} in T#12), S#7 |-> T#12[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: A#9[(app (letrec {E#5} in T#12[(app (letrec {E#1} in S#3) S#2)]) S#6)] <-lapp1- A#9[(app (letrec {E#5} in T#12[(letrec {E#1} in (app S#3 S#2))]) S#6)] ................................................................................ A#9[(app (letrec {E#5} in T#12[(app (letrec {E#1} in S#3) S#2)]) S#6)] -SR,lapp1-> A#9[(letrec {E#5} in (app T#12[(app (letrec {E#1} in S#3) S#2)] S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];E#15} in S#7) S#6)] , A#9[(letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in (app S#7 S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {X#13=T#12;E#15} in S#7) S#6)], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#7) S#6), T#11 |-> (letrec {X#13=T#12;E#15} in S#7), E#5 |-> {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15}, E#14 |-> {E#15}} and instantiated rules: A#9[(app (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in S#7) S#6)] <-lapp1- A#9[(app (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];E#15} in S#7) S#6)] ................................................................................ A#9[(app (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1} in (app S#3 S#2))])] , A#9[(letrec {E#5} in (app S#7 T#11[(app (letrec {E#1} in S#3) S#2)]))] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#11[(app (letrec {E#1} in S#3) S#2)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in S#7) T#11)], T#10 |-> (app (letrec {E#5} in S#7) T#11), S#6 |-> T#11[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: A#9[(app (letrec {E#5} in S#7) T#11[(app (letrec {E#1} in S#3) S#2)])] <-lapp1- A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1} in (app S#3 S#2))])] ................................................................................ A#9[(app (letrec {E#5} in S#7) T#11[(app (letrec {E#1} in S#3) S#2)])] -SR,lapp1-> A#9[(letrec {E#5} in (app S#7 T#11[(app (letrec {E#1} in S#3) S#2)]))] ================================================================================ Critical Pair: ( A#9[(letrec {E#5} in (app S#7 S#6))] , A#9[(letrec {E#5} in (app S#7 S#6))] ) where Delta1 = {A#8,T#4,A#9} Delta2 = {E#1,E#5} Delta3 = {(S#6,(letrec {E#5} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[[.]], T#10 |-> [.], S#2 |-> S#6, S#3 |-> S#7, E#1 |-> {E#5}} and instantiated rules: A#9[(app (letrec {E#5} in S#7) S#6)] <-lapp1- A#9[(letrec {E#5} in (app S#7 S#6))] ................................................................................ A#9[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {E#5} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(letrec {E#1} in (app S#3 S#2))] , A#9[(letrec {E#1} in (app S#3 S#2))] ) where Delta1 = {A#8,T#4,A#9} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9[[.]], T#4 |-> A#9, A#10 |-> [.], S#6 |-> S#2, S#7 |-> S#3, E#5 |-> {E#1}} and instantiated rules: A#9[(app (letrec {E#1} in S#3) S#2)] <-lapp1- A#9[(letrec {E#1} in (app S#3 S#2))] ................................................................................ A#9[(app (letrec {E#1} in S#3) S#2)] -SR,lapp1-> A#9[(letrec {E#1} in (app S#3 S#2))] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1} in (app S#3 S#2))])] , A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(app (letrec {E#1} in S#3) S#2)])] ) where Delta1 = {A#8,T#4} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(app (letrec {E#1} in S#3) S#2)])] <-lapp1- A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1} in (app S#3 S#2))])] ................................................................................ A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(app (letrec {E#1} in S#3) S#2)])] -SR,lapp1-> A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(app (letrec {E#1} in S#3) S#2)])] ================================================================================ Critical Pair: ( (app (letrec {E#5} in T#10[(letrec {E#1} in (app S#3 S#2))]) S#6) , (letrec {E#5} in (app T#10[(app (letrec {E#1} in S#3) S#2)] S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in T#10) S#6), T#9 |-> (letrec {E#5} in T#10), S#7 |-> T#10[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (app (letrec {E#5} in T#10[(app (letrec {E#1} in S#3) S#2)]) S#6) <-lapp1- (app (letrec {E#5} in T#10[(letrec {E#1} in (app S#3 S#2))]) S#6) ................................................................................ (app (letrec {E#5} in T#10[(app (letrec {E#1} in S#3) S#2)]) S#6) -SR,lapp1-> (letrec {E#5} in (app T#10[(app (letrec {E#1} in S#3) S#2)] S#6)) ================================================================================ Critical Pair: ( (app (letrec {X#11=T#10[(letrec {E#1} in (app S#3 S#2))];E#13} in S#7) S#6) , (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in (app S#7 S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {X#11=T#10;E#13} in S#7) S#6), T#9 |-> (letrec {X#11=T#10;E#13} in S#7), E#5 |-> {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13}, E#12 |-> {E#13}} and instantiated rules: (app (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in S#7) S#6) <-lapp1- (app (letrec {X#11=T#10[(letrec {E#1} in (app S#3 S#2))];E#13} in S#7) S#6) ................................................................................ (app (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in S#7) S#6) -SR,lapp1-> (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in (app S#7 S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#5} in S#7) T#9[(letrec {E#1} in (app S#3 S#2))]) , (letrec {E#5} in (app S#7 T#9[(app (letrec {E#1} in S#3) S#2)])) ) where Delta1 = {T#4} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#9[(app (letrec {E#1} in S#3) S#2)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in S#7) T#9), S#6 |-> T#9[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (app (letrec {E#5} in S#7) T#9[(app (letrec {E#1} in S#3) S#2)]) <-lapp1- (app (letrec {E#5} in S#7) T#9[(letrec {E#1} in (app S#3 S#2))]) ................................................................................ (app (letrec {E#5} in S#7) T#9[(app (letrec {E#1} in S#3) S#2)]) -SR,lapp1-> (letrec {E#5} in (app S#7 T#9[(app (letrec {E#1} in S#3) S#2)])) ================================================================================ Critical Pair: ( (letrec {E#1} in (app S#3 S#2)) , (letrec {E#1} in (app S#3 S#2)) ) where Delta1 = {} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#4 |-> [.], A#8 |-> [.], S#6 |-> S#2, S#7 |-> S#3, E#5 |-> {E#1}} and instantiated rules: (app (letrec {E#1} in S#3) S#2) <-lapp1- (letrec {E#1} in (app S#3 S#2)) ................................................................................ (app (letrec {E#1} in S#3) S#2) -SR,lapp1-> (letrec {E#1} in (app S#3 S#2)) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {E#6} in T#14[(letrec {E#1} in (app S#3 S#2))]) S#7)] ) , (letrec E#5 in A#11[(letrec {E#6} in (app T#14[(app (letrec {E#1} in S#3) S#2)] S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in T#14) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in T#14) S#7)], T#12 |-> (app (letrec {E#6} in T#14) S#7), T#13 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(app (letrec {E#1} in S#3) S#2)]) S#7)]) <-lapp1- (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1} in (app S#3 S#2))]) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(app (letrec {E#1} in S#3) S#2)]) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app T#14[(app (letrec {E#1} in S#3) S#2)] S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {X#15=T#14[(letrec {E#1} in (app S#3 S#2))];E#17} in S#8) S#7)] ) , (letrec E#5 in A#11[(letrec {X#15=T#14[(app (letrec {E#1} in S#3) S#2)];E#17} in (app S#8 S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {X#15=T#14[(app (letrec {E#1} in S#3) S#2)];E#17} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#8) S#7), T#13 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(app (letrec {E#1} in S#3) S#2)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(app (letrec {E#1} in S#3) S#2)];E#17} in S#8) S#7)]) <-lapp1- (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1} in (app S#3 S#2))];E#17} in S#8) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(app (letrec {E#1} in S#3) S#2)];E#17} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {X#15=T#14[(app (letrec {E#1} in S#3) S#2)];E#17} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec E#5 in A#11[(letrec {E#6} in (app S#8 T#13[(app (letrec {E#1} in S#3) S#2)]))] ) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#13[(app (letrec {E#1} in S#3) S#2)],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in S#8) T#13)], T#12 |-> (app (letrec {E#6} in S#8) T#13), S#7 |-> T#13[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(app (letrec {E#1} in S#3) S#2)])]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 T#13[(app (letrec {E#1} in S#3) S#2)]))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 S#7))]) , (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 S#7))]) ) where Delta1 = {A#9,T#10,T#4,A#11} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#7,(letrec {E#6} in [.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[[.]]), A#9 |-> A#11, T#10 |-> A#11[[.]], T#12 |-> [.], S#2 |-> S#7, S#3 |-> S#8, E#1 |-> {E#6}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) S#7)]) <-lapp1- (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 S#7))]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(letrec {E#1} in (app S#3 S#2))]) , (letrec {E#5} in A#11[(letrec {E#1} in (app S#3 S#2))]) ) where Delta1 = {A#9,T#10,T#4,A#11} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11), A#9 |-> A#11[[.]], T#10 |-> A#11, A#12 |-> [.], S#7 |-> S#2, S#8 |-> S#3, E#6 |-> {E#1}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#1} in S#3) S#2)]) <-lapp1- (letrec {E#5} in A#11[(letrec {E#1} in (app S#3 S#2))]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#1} in S#3) S#2)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#1} in (app S#3 S#2))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec E#5 in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(app (letrec {E#1} in S#3) S#2)])]) -SR,lapp2-> (letrec {E#5} in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec E#5 in (app (letrec {E#6} in T#12[(letrec {E#1} in (app S#3 S#2))]) S#7) ) , (letrec E#5 in (letrec {E#6} in (app T#12[(app (letrec {E#1} in S#3) S#2)] S#7)) ) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in T#12) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in T#12) S#7), T#11 |-> (letrec {E#6} in T#12), S#8 |-> T#12[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in T#12[(app (letrec {E#1} in S#3) S#2)]) S#7)) <-lapp1- (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1} in (app S#3 S#2))]) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in T#12[(app (letrec {E#1} in S#3) S#2)]) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app T#12[(app (letrec {E#1} in S#3) S#2)] S#7))) ================================================================================ Critical Pair: ( (letrec E#5 in (app (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];E#15} in S#8) S#7) ) , (letrec E#5 in (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in (app S#8 S#7)) ) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {X#13=T#12;E#15} in S#8) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#8) S#7), T#11 |-> (letrec {X#13=T#12;E#15} in S#8), E#6 |-> {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#5} in (app (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in S#8) S#7)) <-lapp1- (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];E#15} in S#8) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in S#8) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (letrec E#5 in (app (letrec {E#6} in S#8) T#11[(letrec {E#1} in (app S#3 S#2))]) ) , (letrec E#5 in (letrec {E#6} in (app S#8 T#11[(app (letrec {E#1} in S#3) S#2)])) ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#11[(app (letrec {E#1} in S#3) S#2)],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in S#8) T#11)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in S#8) T#11), S#7 |-> T#11[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(app (letrec {E#1} in S#3) S#2)])) <-lapp1- (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1} in (app S#3 S#2))])) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(app (letrec {E#1} in S#3) S#2)])) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(app (letrec {E#1} in S#3) S#2)]))) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#1} in (app S#3 S#2))) , (letrec {E#5} in (letrec {E#1} in (app S#3 S#2))) ) where Delta1 = {T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in [.]), T#10 |-> [.], A#9 |-> [.], S#7 |-> S#2, S#8 |-> S#3, E#6 |-> {E#1}} and instantiated rules: (letrec {E#5} in (app (letrec {E#1} in S#3) S#2)) <-lapp1- (letrec {E#5} in (letrec {E#1} in (app S#3 S#2))) ................................................................................ (letrec {E#5} in (app (letrec {E#1} in S#3) S#2)) -SR,lapp2-> (letrec {E#5} in (letrec {E#1} in (app S#3 S#2))) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in (app S#3 S#2))] ;E#13 in A#9[(app (letrec {E#6} in S#8) S#7)] ) , (letrec X#11= T#10[(app (letrec {E#1} in S#3) S#2)] ;E#13 in A#9[(letrec {E#6} in (app S#8 S#7))] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#5,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#5,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]), E#5 |-> {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) <-lapp1- (letrec {X#11=T#10[(letrec {E#1} in (app S#3 S#2))];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {X#11=T#10[(app (letrec {E#1} in S#3) S#2)];E#13} in A#9[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec E#6 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (app S#3 S#2))])] ) , (letrec E#6 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])]), ((var X#5),A#13[(app A#14[[.]] T#15[(app (letrec {E#1} in S#3) S#2)])])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])]) <-lapp1- (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in (app S#3 S#2))])]) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#13[(app A#14[(var X#5)] T#15[(app (letrec {E#1} in S#3) S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in (app S#3 S#2))] ;E#15 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(app (letrec {E#1} in S#3) S#2)] ;E#15 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), E#6 |-> {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#13=T#12[(letrec {E#1} in (app S#3 S#2))];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#13=T#12[(app (letrec {E#1} in S#3) S#2)];E#15;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in T#19[(letrec {E#1} in (app S#3 S#2))]) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app T#19[(app (letrec {E#1} in S#3) S#2)] S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in T#19) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in T#19) S#8)], T#17 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(app (letrec {E#1} in S#3) S#2)]) S#8)];E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1} in (app S#3 S#2))]) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(app (letrec {E#1} in S#3) S#2)]) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app T#19[(app (letrec {E#1} in S#3) S#2)] S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {X#20=T#19[(letrec {E#1} in (app S#3 S#2))];E#22} in S#9) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in (app S#9 S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)], T#17 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1} in (app S#3 S#2))];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (app S#3 S#2))])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app S#9 T#18[(app (letrec {E#1} in S#3) S#2)]))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#18[(app (letrec {E#1} in S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in S#9) T#18)], T#17 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(app (letrec {E#1} in S#3) S#2)])];E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (app S#3 S#2))])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(app (letrec {E#1} in S#3) S#2)])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app S#9 T#18[(app (letrec {E#1} in S#3) S#2)]))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(letrec {E#7} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) , (letrec {X#5=A#16[(letrec {E#7} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ) where Delta1 = {A#15,T#12,T#4,A#16} Delta2 = {E#1,E#7} Delta3 = {(S#8,(letrec {E#7} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[[.]];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[[.]], T#17 |-> [.], S#2 |-> S#8, S#3 |-> S#9, E#1 |-> {E#7}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(letrec {E#7} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(letrec {E#1} in (app S#3 S#2))];E#6} in A#10[(var X#5)]) , (letrec {X#5=A#16[(letrec {E#1} in (app S#3 S#2))];E#6} in A#10[(var X#5)]) ) where Delta1 = {A#15,T#12,T#4,A#16} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16;E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16[[.]], T#12 |-> A#16, A#17 |-> [.], S#8 |-> S#2, S#9 |-> S#3, E#7 |-> {E#1}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#1} in S#3) S#2)];E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(letrec {E#1} in (app S#3 S#2))];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#1} in S#3) S#2)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#1} in (app S#3 S#2))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1} in (app S#3 S#2))])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(app (letrec {E#1} in S#3) S#2)])] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(app (letrec {E#1} in S#3) S#2)])]}, X#13 |-> X#5, E#14 |-> {E#6}, T#12 |-> A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1} in (app S#3 S#2))])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(app (letrec {E#1} in S#3) S#2)])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(app (letrec {E#1} in S#3) S#2)])];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in T#17[(letrec {E#1} in (app S#3 S#2))]) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app T#17[(app (letrec {E#1} in S#3) S#2)] S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in T#17) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#17) S#8), T#16 |-> (letrec {E#7} in T#17), S#9 |-> T#17[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in T#17[(app (letrec {E#1} in S#3) S#2)]) S#8);E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1} in (app S#3 S#2))]) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in T#17[(app (letrec {E#1} in S#3) S#2)]) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app T#17[(app (letrec {E#1} in S#3) S#2)] S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {X#18=T#17[(letrec {E#1} in (app S#3 S#2))];E#20} in S#9) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#18=T#17[(app (letrec {E#1} in S#3) S#2)];E#20} in (app S#9 S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {X#18=T#17[(app (letrec {E#1} in S#3) S#2)];E#20} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {X#18=T#17;E#20} in S#9) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {X#18=T#17;E#20} in S#9) S#8), T#16 |-> (letrec {X#18=T#17;E#20} in S#9), E#7 |-> {X#18=T#17[(app (letrec {E#1} in S#3) S#2)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#5=(app (letrec {X#18=T#17[(app (letrec {E#1} in S#3) S#2)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1} in (app S#3 S#2))];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {X#18=T#17[(app (letrec {E#1} in S#3) S#2)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {X#18=T#17[(app (letrec {E#1} in S#3) S#2)];E#20} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in S#9) T#16[(letrec {E#1} in (app S#3 S#2))]) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app S#9 T#16[(app (letrec {E#1} in S#3) S#2)])) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#16[(app (letrec {E#1} in S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in S#9) T#16);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#16), S#8 |-> T#16[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(app (letrec {E#1} in S#3) S#2)]);E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1} in (app S#3 S#2))]);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(app (letrec {E#1} in S#3) S#2)]);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app S#9 T#16[(app (letrec {E#1} in S#3) S#2)]));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#1} in (app S#3 S#2));E#6} in A#10[(var X#5)]) , (letrec {X#5=(letrec {E#1} in (app S#3 S#2));E#6} in A#10[(var X#5)]) ) where Delta1 = {T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=[.];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, T#12 |-> [.], A#15 |-> [.], S#8 |-> S#2, S#9 |-> S#3, E#7 |-> {E#1}} and instantiated rules: (letrec {X#5=(app (letrec {E#1} in S#3) S#2);E#6} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=(letrec {E#1} in (app S#3 S#2));E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#1} in S#3) S#2);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#1} in (app S#3 S#2));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#6 ;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])] ;E#6 ;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in (app S#3 S#2))])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (app S#3 S#2))])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in (app S#3 S#2))])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in T#21[(letrec {E#1} in (app S#3 S#2))]) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app T#21[(app (letrec {E#1} in S#3) S#2)] S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in T#21) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in T#21) S#8)], T#19 |-> (app (letrec {E#7} in T#21) S#8), T#20 |-> (letrec {E#7} in T#21), S#9 |-> T#21[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(app (letrec {E#1} in S#3) S#2)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1} in (app S#3 S#2))]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(app (letrec {E#1} in S#3) S#2)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app T#21[(app (letrec {E#1} in S#3) S#2)] S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {X#22=T#21[(letrec {E#1} in (app S#3 S#2))];E#24} in S#9) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#22=T#21[(app (letrec {E#1} in S#3) S#2)];E#24} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {X#22=T#21[(app (letrec {E#1} in S#3) S#2)];E#24} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#9) S#8), T#20 |-> (letrec {X#22=T#21;E#24} in S#9), E#7 |-> {X#22=T#21[(app (letrec {E#1} in S#3) S#2)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {X#22=T#21[(app (letrec {E#1} in S#3) S#2)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1} in (app S#3 S#2))];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {X#22=T#21[(app (letrec {E#1} in S#3) S#2)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {X#22=T#21[(app (letrec {E#1} in S#3) S#2)];E#24} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app S#9 T#20[(app (letrec {E#1} in S#3) S#2)]))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#20[(app (letrec {E#1} in S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in S#9) T#20)], T#19 |-> (app (letrec {E#7} in S#9) T#20), S#8 |-> T#20[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1} in (app S#3 S#2))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app S#9 T#20[(app (letrec {E#1} in S#3) S#2)]))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(letrec {E#7} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4,A#18} Delta2 = {E#1,E#7} Delta3 = {(S#8,(letrec {E#7} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[[.]];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[[.]], T#19 |-> [.], S#2 |-> S#8, S#3 |-> S#9, E#1 |-> {E#7}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(letrec {E#7} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(letrec {E#1} in (app S#3 S#2))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#1} in (app S#3 S#2))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4,A#18} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18;E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18[[.]], T#12 |-> A#18, A#19 |-> [.], S#8 |-> S#2, S#9 |-> S#3, E#7 |-> {E#1}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#1} in S#3) S#2)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(letrec {E#1} in (app S#3 S#2))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#1} in S#3) S#2)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#1} in (app S#3 S#2))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1} in (app S#3 S#2))])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(app (letrec {E#1} in S#3) S#2)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(app (letrec {E#1} in S#3) S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(app (letrec {E#1} in S#3) S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1} in (app S#3 S#2))])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(app (letrec {E#1} in S#3) S#2)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in T#19[(letrec {E#1} in (app S#3 S#2))]) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app T#19[(app (letrec {E#1} in S#3) S#2)] S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in T#19) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in T#19[(app (letrec {E#1} in S#3) S#2)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1} in (app S#3 S#2))]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in T#19[(app (letrec {E#1} in S#3) S#2)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app T#19[(app (letrec {E#1} in S#3) S#2)] S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {X#20=T#19[(letrec {E#1} in (app S#3 S#2))];E#22} in S#9) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in (app S#9 S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#8,(letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {X#20=T#19;E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#16=(app (letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1} in (app S#3 S#2))];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {X#20=T#19[(app (letrec {E#1} in S#3) S#2)];E#22} in (app S#9 S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (app S#3 S#2))]) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app S#9 T#18[(app (letrec {E#1} in S#3) S#2)])) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#18[(app (letrec {E#1} in S#3) S#2)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in S#9) T#18);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(app (letrec {E#1} in S#3) S#2)]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(app (letrec {E#1} in S#3) S#2)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in (app S#3 S#2))]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(app (letrec {E#1} in S#3) S#2)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app S#9 T#18[(app (letrec {E#1} in S#3) S#2)]));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (letrec {E#1} in (app S#3 S#2)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#1} in (app S#3 S#2)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#7} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#2,(letrec {E#1} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -lapp1-> with input rules: T#4[(app (letrec {E#1} in S#3) S#2)] <-lapp1- T#4[(letrec {E#1} in (app S#3 S#2))] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(app (letrec {E#1} in S#3) S#2)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#7} Delta3= {(S#2,(letrec {E#1} in [.])),(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=[.];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, T#12 |-> [.], A#15 |-> [.], S#8 |-> S#2, S#9 |-> S#3, E#7 |-> {E#1}} and instantiated rules: (letrec {X#16=(app (letrec {E#1} in S#3) S#2);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-lapp1- (letrec {X#16=(letrec {E#1} in (app S#3 S#2));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#1} in S#3) S#2);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#1} in (app S#3 S#2));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( A#10[(app (\ X#6.S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] , A#10[(letrec {X#6=T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#8)] ) where Delta1 = {T#11,A#9,T#4,A#10} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#6.[.])), (T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#6=[.]} in S#8)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (\ X#6.S#8) S#7)] -SR,lbeta1-> A#9[(letrec {X#6=S#7} in S#8)] and constraints: (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (\ X#6.S#8) S#7)]} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(\ X#6.[.])),(S#7,(letrec {X#6=[.]} in S#8)),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (\ X#6.S#8) T#12)], T#11 |-> (app (\ X#6.S#8) T#12), S#7 |-> T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: A#10[(app (\ X#6.S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] <-cpx-in1- A#10[(app (\ X#6.S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ................................................................................ A#10[(app (\ X#6.S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] -SR,lbeta1-> A#10[(letrec {X#6=T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#8)] ================================================================================ Critical Pair: ( A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] , A#10[(app A#11[(letrec {X#6=S#7} in S#8)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) where Delta1 = {A#9,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (\ X#6.S#8) S#7)] -SR,lbeta1-> A#9[(letrec {X#6=S#7} in S#8)] and constraints: (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (\ X#6.S#8) S#7)]} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(\ X#6.[.])),(S#7,(letrec {X#6=[.]} in S#8)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12)], A#9 |-> A#10[(app A#11 T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] <-cpx-in1- A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ................................................................................ A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] -SR,lbeta1-> A#10[(app A#11[(letrec {X#6=S#7} in S#8)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ================================================================================ Critical Pair: ( (app (\ X#6.S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) , (letrec {X#6=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#8) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#6.[.])), (T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#6=[.]} in S#8)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (\ X#6.S#8) S#7)] -SR,lbeta1-> A#9[(letrec {X#6=S#7} in S#8)] and constraints: (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (\ X#6.S#8) S#7)]} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(\ X#6.[.])),(S#7,(letrec {X#6=[.]} in S#8)),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (\ X#6.S#8) T#10), S#7 |-> T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (app (\ X#6.S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) <-cpx-in1- (app (\ X#6.S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ................................................................................ (app (\ X#6.S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) -SR,lbeta1-> (letrec {X#6=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#8) ================================================================================ Critical Pair: ( (letrec E#7 in A#12[(app (\ X#6.S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec E#7 in A#12[(letrec {X#6=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#9)] ) ) where Delta1 = {T#13,A#10,T#11,T#4,A#12} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#6.[.])), (T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14)]), A#10 |-> A#12, T#11 |-> A#12[(app (\ X#6.S#9) T#14)], T#13 |-> (app (\ X#6.S#9) T#14), S#8 |-> T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,lbeta2-> (letrec {E#7} in A#12[(letrec {X#6=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#9)]) ================================================================================ Critical Pair: ( (letrec E#7 in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec E#7 in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)]), T#11 |-> A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,lbeta2-> (letrec {E#7} in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec E#7 in (app (\ X#6.S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ) , (letrec E#7 in (letrec {X#6=T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#9) ) ) where Delta1 = {T#11,T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#6.[.])), (T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7} in (app (\ X#6.S#9) T#12)), A#10 |-> [.], T#11 |-> (app (\ X#6.S#9) T#12), S#8 |-> T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) <-cpx-in1- (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])) ................................................................................ (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) -SR,lbeta2-> (letrec {E#7} in (letrec {X#6=T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#9)) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#14 in A#10[(app (\ X#6.S#9) S#8)] ) , (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#14 in A#10[(letrec {X#6=S#8} in S#9)] ) ) where Delta1 = {T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;E#14} in A#10[(app (\ X#6.S#9) S#8)]), E#7 |-> {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in A#10[(app (\ X#6.S#9) S#8)]) <-cpx-in1- (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#14} in A#10[(app (\ X#6.S#9) S#8)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in A#10[(letrec {X#6=S#8} in S#9)]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.C#15[(var X#2)]) S#8)]) , (letrec {X#1=(var X#2);E#11} in A#12[(letrec {X#6=S#8} in C#15[(var X#1)])]) ) where Delta1 = {C#14,C#13,A#10,C#5,A#12} Delta2 = {E#7} Delta3 = {((var X#1),A#12[(app (\ X#6.C#15) S#8)]), ((var X#2),A#12[(app (\ X#6.C#15) S#8)]), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in C#15[(var X#1)])), ((var X#1),A#12[(app (\ X#6.C#15[[.]]) S#8)])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> A#12, C#5 |-> A#12[(app (\ X#6.C#15) S#8)], C#13 |-> (app (\ X#6.C#15) S#8), C#14 |-> (\ X#6.C#15), S#9 |-> C#15[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.C#15[(var X#1)]) S#8)]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.C#15[(var X#2)]) S#8)]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.C#15[(var X#1)]) S#8)]) -SR,lbeta2-> (letrec {X#1=(var X#2);E#11} in A#12[(letrec {X#6=S#8} in C#15[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.S#9) C#14[(var X#2)])]) , (letrec {X#1=(var X#2);E#11} in A#12[(letrec {X#6=C#14[(var X#1)]} in S#9)]) ) where Delta1 = {C#13,A#10,C#5,A#12} Delta2 = {E#7} Delta3 = {((var X#1),A#12[(app (\ X#6.S#9) C#14)]), ((var X#2),A#12[(app (\ X#6.S#9) C#14)]), (C#14[(var X#1)],(\ X#6.[.])), (C#14[(var X#1)],(letrec {X#6=[.]} in S#9)), ((var X#1),A#12[(app (\ X#6.S#9) C#14[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> A#12, C#5 |-> A#12[(app (\ X#6.S#9) C#14)], C#13 |-> (app (\ X#6.S#9) C#14), S#8 |-> C#14[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.S#9) C#14[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.S#9) C#14[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app (\ X#6.S#9) C#14[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=(var X#2);E#11} in A#12[(letrec {X#6=C#14[(var X#1)]} in S#9)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#11 in A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14[(var X#2)])] ) , (letrec X#1= (var X#2) ;E#11 in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] C#14[(var X#1)])] ) ) where Delta1 = {A#10,C#5} Delta2 = {E#7} Delta3 = {((var X#1),A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14)]), ((var X#2),A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14)]), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, C#5 |-> A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14)], A#10 |-> A#12[(app A#13 C#14[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] C#14[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] C#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#11} in (app (\ X#6.C#13[(var X#2)]) S#8)) , (letrec {X#1=(var X#2);E#11} in (letrec {X#6=S#8} in C#13[(var X#1)])) ) where Delta1 = {C#12,C#5} Delta2 = {E#7} Delta3 = {((var X#1),(app (\ X#6.C#13) S#8)), ((var X#2),(app (\ X#6.C#13) S#8)), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in C#13[(var X#1)])), ((var X#1),(app (\ X#6.C#13[[.]]) S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> [.], C#5 |-> (app (\ X#6.C#13) S#8), C#12 |-> (\ X#6.C#13), S#9 |-> C#13[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in (app (\ X#6.C#13[(var X#1)]) S#8)) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in (app (\ X#6.C#13[(var X#2)]) S#8)) ................................................................................ (letrec {X#1=(var X#2);E#11} in (app (\ X#6.C#13[(var X#1)]) S#8)) -SR,lbeta2-> (letrec {X#1=(var X#2);E#11} in (letrec {X#6=S#8} in C#13[(var X#1)])) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#11} in (app (\ X#6.S#9) C#12[(var X#2)])) , (letrec {X#1=(var X#2);E#11} in (letrec {X#6=C#12[(var X#1)]} in S#9)) ) where Delta1 = {C#5} Delta2 = {E#7} Delta3 = {((var X#1),(app (\ X#6.S#9) C#12)), ((var X#2),(app (\ X#6.S#9) C#12)), (C#12[(var X#1)],(\ X#6.[.])), (C#12[(var X#1)],(letrec {X#6=[.]} in S#9)), ((var X#1),(app (\ X#6.S#9) C#12[[.]]))} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> [.], C#5 |-> (app (\ X#6.S#9) C#12), S#8 |-> C#12[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in (app (\ X#6.S#9) C#12[(var X#1)])) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in (app (\ X#6.S#9) C#12[(var X#2)])) ................................................................................ (letrec {X#1=(var X#2);E#11} in (app (\ X#6.S#9) C#12[(var X#1)])) -SR,lbeta2-> (letrec {X#1=(var X#2);E#11} in (letrec {X#6=C#12[(var X#1)]} in S#9)) ================================================================================ Critical Pair: ( (letrec E#8 ;EE#12[X#6,(app (\ X#7.S#10) S#9)] in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec E#8 ;EE#12[X#6,(letrec {X#7=S#9} in S#10)] in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16)]), T#13 |-> A#14[(app A#15[(var X#6)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#16 ;EE#12[X#6,(app (\ X#7.S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#16 ;EE#12[X#6,(letrec {X#7=S#9} in S#10)] in A#11[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]), E#8 |-> {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16}, E#15 |-> {E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#8 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec {X#7=T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10)] ;E#8 in A#11[(var X#6)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#17} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#7.[.])), (T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (\ X#7.S#10) T#19)];E#8} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#8}, A#16 |-> A#17, T#13 |-> A#17[(app (\ X#7.S#10) T#19)], T#18 |-> (app (\ X#7.S#10) T#19), S#9 |-> T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=A#17[(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#8} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#17[(letrec {X#7=T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10)];E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#8 in A#11[(var X#6)] ) , (letrec X#6= A#17[(app A#18[(letrec {X#7=S#9} in S#10)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#8 in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19)];E#8} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]}, X#14 |-> X#6, E#15 |-> {E#8}, T#13 |-> A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#8} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#17[(app A#18[(letrec {X#7=S#9} in S#10)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (\ X#7.S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ;E#8 in A#11[(var X#6)] ) , (letrec X#6= (letrec {X#7=T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10) ;E#8 in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#7.[.])), (T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (\ X#7.S#10) T#17);E#8} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#8}, A#16 |-> [.], T#13 |-> (app (\ X#7.S#10) T#17), S#9 |-> T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(app (\ X#7.S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#8} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=(app (\ X#7.S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]);E#8} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (\ X#7.S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#8} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=(letrec {X#7=T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10);E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#8 ;EE#18[X#17,(app (\ X#7.S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#8 ;EE#18[X#17,(letrec {X#7=S#9} in S#10)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#6, E#15 |-> {E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#17,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#8 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(app (\ X#7.S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#8 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(letrec {X#7=S#9} in S#10)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (\ X#7.S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {X#7=T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10)] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#19} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#7.[.])), (T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (\ X#7.S#10) T#21)];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#8;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (\ X#7.S#10) T#21)], T#20 |-> (app (\ X#7.S#10) T#21), S#9 |-> T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#17=A#19[(app (\ X#7.S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app (\ X#7.S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (\ X#7.S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=A#19[(letrec {X#7=T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10)];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(app A#20[(letrec {X#7=S#9} in S#10)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21)];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#8;EE#18[X#6,(var X#17)]}, T#13 |-> A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=A#19[(app A#20[(letrec {X#7=S#9} in S#10)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {X#7=T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10) ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(\ X#7.[.])), (T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (\ X#7.S#10) T#19);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#8;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (\ X#7.S#10) T#19), S#9 |-> T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#17=(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (\ X#7.S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=(letrec {X#7=T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} in S#10);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#13 ;EE#12[X#6,(app (\ X#7.S#10) S#9)] in A#14[(app A#15[(var X#6)] C#16[(var X#2)])] ) , (letrec X#1= (var X#2) ;E#13 ;EE#12[X#6,(letrec {X#7=S#9} in S#10)] in A#14[(app A#15[(var X#6)] C#16[(var X#1)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#1),A#14[(app A#15[(var X#6)] C#16)]), ((var X#2),A#14[(app A#15[(var X#6)] C#16)]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),A#14[(app A#15[(var X#6)] C#16[[.]])]), ((var X#6),A#14[(app A#15[[.]] C#16[(var X#1)])]), ((var X#6),A#14[(app A#15[[.]] C#16[(var X#1)])])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], E#8 |-> {X#1=(var X#2);E#13}, E#3 |-> {E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]}, C#5 |-> A#14[(app A#15[(var X#6)] C#16)], A#11 |-> A#14[(app A#15 C#16[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] C#16[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] C#16[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] C#16[(var X#1)])]) -SR,lbeta3-> (letrec {X#1=(var X#2);E#13;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#14[(app A#15[(var X#6)] C#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#8 ;EE#15[X#2,(app (\ X#7.S#10) S#9)] in A#16[(var X#2)] ) , (letrec X#6= (var X#2) ;E#8 ;EE#15[X#2,(letrec {X#7=S#9} in S#10)] in A#16[(var X#6)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {} Delta3 = {((var X#6),A#16[[.]]), ((var X#2),A#16[[.]]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]}, A#13 |-> [.], X#14 |-> X#2, A#11 |-> A#16, C#5 |-> A#16[[.]], C#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) <-cpx-in1- (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(var X#2)]) ................................................................................ (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) -SR,lbeta3-> (letrec {X#6=(var X#2);E#8;EE#15[X#2,(letrec {X#7=S#9} in S#10)]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#8 ;EE#15[X#2,(app (\ X#7.S#10) S#9)] in A#16[(var X#2)] ) , (letrec X#6= (var X#2) ;E#8 ;EE#15[X#2,(letrec {X#7=S#9} in S#10)] in A#16[(var X#6)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {} Delta3 = {((var X#6),A#16), ((var X#2),A#16), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]}, A#13 |-> [.], X#14 |-> X#2, A#11 |-> A#16[[.]], C#5 |-> A#16, A#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) <-cpx-in1- (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(var X#2)]) ................................................................................ (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) -SR,lbeta3-> (letrec {X#6=(var X#2);E#8;EE#15[X#2,(letrec {X#7=S#9} in S#10)]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#8 ;EE#15[X#2,(app (\ X#7.S#10) S#9)] in A#16[(app A#17[(var X#6)] C#18[(var X#2)])] ) , (letrec X#6= (var X#2) ;E#8 ;EE#15[X#2,(letrec {X#7=S#9} in S#10)] in A#16[(app A#17[(var X#6)] C#18[(var X#6)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#6),A#16[(app A#17[(var X#6)] C#18)]), ((var X#2),A#16[(app A#17[(var X#6)] C#18)]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#16[(app A#17[(var X#6)] C#18[[.]])]), ((var X#6),A#16[(app A#17[[.]] C#18[(var X#6)])]), ((var X#6),A#16[(app A#17[[.]] C#18[(var X#6)])])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]}, A#13 |-> [.], X#14 |-> X#2, C#5 |-> A#16[(app A#17[(var X#6)] C#18)], A#11 |-> A#16[(app A#17 C#18[(var X#6)])]} and instantiated rules: (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(app A#17[(var X#6)] C#18[(var X#6)])]) <-cpx-in1- (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(app A#17[(var X#6)] C#18[(var X#2)])]) ................................................................................ (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in A#16[(app A#17[(var X#6)] C#18[(var X#6)])]) -SR,lbeta3-> (letrec {X#6=(var X#2);E#8;EE#15[X#2,(letrec {X#7=S#9} in S#10)]} in A#16[(app A#17[(var X#6)] C#18[(var X#6)])]) ================================================================================ Critical Pair: ( (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in (var X#2)) , (letrec {X#6=(var X#2);E#8;EE#15[X#2,(letrec {X#7=S#9} in S#10)]} in (var X#6)) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#6),[.]), ((var X#2),[.]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]}, C#5 |-> [.], A#13 |-> [.], X#14 |-> X#2, A#11 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in (var X#6)) <-cpx-in1- (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in (var X#2)) ................................................................................ (letrec {X#6=(var X#2);E#8;EE#15[X#2,(app (\ X#7.S#10) S#9)]} in (var X#6)) -SR,lbeta3-> (letrec {X#6=(var X#2);E#8;EE#15[X#2,(letrec {X#7=S#9} in S#10)]} in (var X#6)) ================================================================================ Critical Pair: ( (letrec X#14= (var X#2) ;E#8 ;EE#16[X#6,(var X#14)] ;EE#17[X#2,(app (\ X#7.S#10) S#9)] in A#18[(app A#19[(var X#6)] C#20[(var X#2)])] ) , (letrec X#14= (var X#2) ;E#8 ;EE#16[X#6,(var X#14)] ;EE#17[X#2,(letrec {X#7=S#9} in S#10)] in A#18[(app A#19[(var X#6)] C#20[(var X#14)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#14),A#18[(app A#19[(var X#6)] C#20)]), ((var X#2),A#18[(app A#19[(var X#6)] C#20)]), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#14),A#18[(app A#19[(var X#6)] C#20[[.]])]), ((var X#6),A#18[(app A#19[[.]] C#20[(var X#14)])]), ((var X#6),A#18[(app A#19[[.]] C#20[(var X#14)])])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {X#14=(var X#2);EE#16[[.1],(var X#14)];EE#17[X#2,[.2]]}, X#1 |-> X#14, E#3 |-> {E#8;EE#16[X#6,(var X#14)];EE#17[X#2,(app (\ X#7.S#10) S#9)]}, A#13 |-> [.], X#15 |-> X#2, C#5 |-> A#18[(app A#19[(var X#6)] C#20)], A#11 |-> A#18[(app A#19 C#20[(var X#14)])]} and instantiated rules: (letrec {X#14=(var X#2);E#8;EE#16[X#6,(var X#14)];EE#17[X#2,(app (\ X#7.S#10) S#9)]} in A#18[(app A#19[(var X#6)] C#20[(var X#14)])]) <-cpx-in1- (letrec {X#14=(var X#2);E#8;EE#16[X#6,(var X#14)];EE#17[X#2,(app (\ X#7.S#10) S#9)]} in A#18[(app A#19[(var X#6)] C#20[(var X#2)])]) ................................................................................ (letrec {X#14=(var X#2);E#8;EE#16[X#6,(var X#14)];EE#17[X#2,(app (\ X#7.S#10) S#9)]} in A#18[(app A#19[(var X#6)] C#20[(var X#14)])]) -SR,lbeta3-> (letrec {X#14=(var X#2);E#8;EE#16[X#6,(var X#14)];EE#17[X#2,(letrec {X#7=S#9} in S#10)]} in A#18[(app A#19[(var X#6)] C#20[(var X#14)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#9) ;E#8 in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec X#6= (\ X#7.S#9) ;E#8 in A#12[(app A#13[(\ X#7.S#9)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14)]), T#11 |-> A#12[(app A#13[(var X#6)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(\ X#7.S#9)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;X#6= (\ X#7.S#9) ;E#14 in A#10[(var X#6)] ) , (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= (\ X#7.S#9) ;E#14 in A#10[(\ X#7.S#9)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]), E#8 |-> {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14}, E#13 |-> {X#6=(\ X#7.S#9);E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]) <-cpx-in1- (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#9);E#14} in A#10[(\ X#7.S#9)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#6= (\ X#7.S#9) ;E#11 in A#12[(app A#13[(var X#6)] C#14[(var X#2)])] ) , (letrec X#1= (var X#2) ;X#6= (\ X#7.S#9) ;E#11 in A#12[(app A#13[(\ X#7.S#9)] C#14[(var X#1)])] ) ) where Delta1 = {A#10,C#5} Delta2 = {} Delta3 = {((var X#1),A#12[(app A#13[(var X#6)] C#14)]), ((var X#2),A#12[(app A#13[(var X#6)] C#14)]), ((var X#1),A#12[(app A#13[(var X#6)] C#14[[.]])]), ((var X#6),A#12[(app A#13[[.]] C#14[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], E#8 |-> {X#1=(var X#2);E#11}, E#3 |-> {X#6=(\ X#7.S#9);E#11}, C#5 |-> A#12[(app A#13[(var X#6)] C#14)], A#10 |-> A#12[(app A#13 C#14[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] C#14[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] C#14[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] C#14[(var X#1)])]) -SR,cp-in1-> (letrec {X#1=(var X#2);X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(\ X#7.S#9)] C#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#9 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec X#6= (\ X#7.S#10) ;E#9 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(\ X#7.S#10)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16)]), T#13 |-> A#14[(app A#15[(var X#8)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(\ X#7.S#10)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;X#6= (\ X#7.S#10) ;E#16 ;VV#12|X#8,(var X#6)| in A#11[(var X#8)] ) , (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= (\ X#7.S#10) ;E#16 ;VV#12|X#8,(var X#6)| in A#11[(\ X#7.S#10)] ) ) where Delta1 = {T#4} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#11[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]), E#9 |-> {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16}, E#15 |-> {X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) <-cpx-in1- (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#6= (\ X#7.S#10) ;E#13 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(var X#8)] C#16[(var X#2)])] ) , (letrec X#1= (var X#2) ;X#6= (\ X#7.S#10) ;E#13 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(\ X#7.S#10)] C#16[(var X#1)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#1),A#14[(app A#15[(var X#8)] C#16)]), ((var X#2),A#14[(app A#15[(var X#8)] C#16)]), ((var X#1),A#14[(app A#15[(var X#8)] C#16[[.]])]), ((var X#6),[.]), ((var X#8),A#14[(app A#15[[.]] C#16[(var X#1)])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], E#9 |-> {X#1=(var X#2);E#13}, E#3 |-> {X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|}, C#5 |-> A#14[(app A#15[(var X#8)] C#16)], A#11 |-> A#14[(app A#15 C#16[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] C#16[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] C#16[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] C#16[(var X#1)])]) -SR,cp-in2-> (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(\ X#7.S#10)] C#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#6)]) , (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ) where Delta1 = {A#11,C#5,A#14} Delta2 = {} Delta3 = {((var X#8),A#14[[.]]), ((var X#6),A#14[[.]]), ((var X#8),A#14[[.]]), ((var X#6),[.]), ((var X#8),A#14[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#10);E#9}, A#11 |-> A#14, C#5 |-> A#14[[.]], C#15 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#6)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#6)]) , (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ) where Delta1 = {A#11,C#5,A#14} Delta2 = {} Delta3 = {((var X#8),A#14), ((var X#6),A#14), ((var X#8),A#14[[.]]), ((var X#6),[.]), ((var X#8),A#14[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#10);E#9}, A#11 |-> A#14[[.]], C#5 |-> A#14, A#15 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#6)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#6) ;E#9 in A#14[(app A#15[(var X#8)] C#16[(var X#6)])] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#6) ;E#9 in A#14[(app A#15[(\ X#7.S#10)] C#16[(var X#8)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#8),A#14[(app A#15[(var X#8)] C#16)]), ((var X#6),A#14[(app A#15[(var X#8)] C#16)]), ((var X#8),A#14[(app A#15[(var X#8)] C#16[[.]])]), ((var X#6),[.]), ((var X#8),A#14[(app A#15[[.]] C#16[(var X#8)])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#10);E#9}, C#5 |-> A#14[(app A#15[(var X#8)] C#16)], A#11 |-> A#14[(app A#15 C#16[(var X#8)])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(app A#15[(var X#8)] C#16[(var X#8)])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(app A#15[(var X#8)] C#16[(var X#6)])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(app A#15[(var X#8)] C#16[(var X#8)])]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(app A#15[(\ X#7.S#10)] C#16[(var X#8)])]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (var X#6)) , (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (\ X#7.S#10)) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#10);E#9}, C#5 |-> [.], A#11 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (var X#8)) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (var X#6)) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (var X#8)) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (\ X#7.S#10)) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(var X#14)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(\ X#7.S#10)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {} Delta3 = {((var X#8),A#16[[.]]), ((var X#14),A#16[[.]]), ((var X#8),A#16[[.]]), ((var X#6),[.]), ((var X#8),A#16[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, X#2 |-> X#14, E#3 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, A#11 |-> A#16, C#5 |-> A#16[[.]], C#17 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#14)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(var X#14)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(\ X#7.S#10)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {} Delta3 = {((var X#8),A#16), ((var X#14),A#16), ((var X#8),A#16[[.]]), ((var X#6),[.]), ((var X#8),A#16[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, X#2 |-> X#14, E#3 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, A#11 |-> A#16[[.]], C#5 |-> A#16, A#17 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#14)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(app A#17[(var X#8)] C#18[(var X#14)])] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(app A#17[(\ X#7.S#10)] C#18[(var X#8)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#8),A#16[(app A#17[(var X#8)] C#18)]), ((var X#14),A#16[(app A#17[(var X#8)] C#18)]), ((var X#8),A#16[(app A#17[(var X#8)] C#18[[.]])]), ((var X#6),[.]), ((var X#8),A#16[(app A#17[[.]] C#18[(var X#8)])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, X#2 |-> X#14, E#3 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, C#5 |-> A#16[(app A#17[(var X#8)] C#18)], A#11 |-> A#16[(app A#17 C#18[(var X#8)])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(app A#17[(var X#8)] C#18[(var X#8)])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(app A#17[(var X#8)] C#18[(var X#14)])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(app A#17[(var X#8)] C#18[(var X#8)])]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(app A#17[(\ X#7.S#10)] C#18[(var X#8)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in (var X#14) ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in (\ X#7.S#10) ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#8),[.]), ((var X#14),[.]), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, X#2 |-> X#14, E#3 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, C#5 |-> [.], A#11 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (var X#8)) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (var X#14)) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (var X#8)) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (\ X#7.S#10)) ================================================================================ Critical Pair: ( (letrec X#14= (var X#15) ;X#6= (\ X#7.S#10) ;E#9 ;VV#16|X#8,(var X#14)| ;VV#17|X#15,(var X#6)| in A#18[(app A#19[(var X#8)] C#20[(var X#15)])] ) , (letrec X#14= (var X#15) ;X#6= (\ X#7.S#10) ;E#9 ;VV#16|X#8,(var X#14)| ;VV#17|X#15,(var X#6)| in A#18[(app A#19[(\ X#7.S#10)] C#20[(var X#14)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#14),A#18[(app A#19[(var X#8)] C#20)]), ((var X#15),A#18[(app A#19[(var X#8)] C#20)]), ((var X#14),A#18[(app A#19[(var X#8)] C#20[[.]])]), ((var X#6),[.]), ((var X#8),A#18[(app A#19[[.]] C#20[(var X#14)])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {X#14=(var X#15);VV#16|[.1],(var X#14)|;VV#17|X#15,[.2]|}, X#1 |-> X#14, X#2 |-> X#15, E#3 |-> {X#6=(\ X#7.S#10);E#9;VV#16|X#8,(var X#14)|;VV#17|X#15,(var X#6)|}, C#5 |-> A#18[(app A#19[(var X#8)] C#20)], A#11 |-> A#18[(app A#19 C#20[(var X#14)])]} and instantiated rules: (letrec {X#14=(var X#15);X#6=(\ X#7.S#10);E#9;VV#16|X#8,(var X#14)|;VV#17|X#15,(var X#6)|} in A#18[(app A#19[(var X#8)] C#20[(var X#14)])]) <-cpx-in1- (letrec {X#14=(var X#15);X#6=(\ X#7.S#10);E#9;VV#16|X#8,(var X#14)|;VV#17|X#15,(var X#6)|} in A#18[(app A#19[(var X#8)] C#20[(var X#15)])]) ................................................................................ (letrec {X#14=(var X#15);X#6=(\ X#7.S#10);E#9;VV#16|X#8,(var X#14)|;VV#17|X#15,(var X#6)|} in A#18[(app A#19[(var X#8)] C#20[(var X#14)])]) -SR,cp-in2-> (letrec {X#14=(var X#15);X#6=(\ X#7.S#10);E#9;VV#16|X#8,(var X#14)|;VV#17|X#15,(var X#6)|} in A#18[(app A#19[(\ X#7.S#10)] C#20[(var X#14)])]) ================================================================================ Critical Pair: ( (letrec X#14= (var X#6) ;X#6= (\ X#7.S#10) ;E#9 ;VV#15|X#8,(var X#14)| in A#16[(app A#17[(var X#8)] C#18[(var X#6)])] ) , (letrec X#14= (var X#6) ;X#6= (\ X#7.S#10) ;E#9 ;VV#15|X#8,(var X#14)| in A#16[(app A#17[(\ X#7.S#10)] C#18[(var X#14)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {} Delta3 = {((var X#14),A#16[(app A#17[(var X#8)] C#18)]), ((var X#6),A#16[(app A#17[(var X#8)] C#18)]), ((var X#14),A#16[(app A#17[(var X#8)] C#18[[.]])]), ((var X#6),[.]), ((var X#8),A#16[(app A#17[[.]] C#18[(var X#14)])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {X#14=[.2];VV#15|[.1],(var X#14)|}, X#1 |-> X#14, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#8,(var X#14)|}, C#5 |-> A#16[(app A#17[(var X#8)] C#18)], A#11 |-> A#16[(app A#17 C#18[(var X#14)])]} and instantiated rules: (letrec {X#14=(var X#6);X#6=(\ X#7.S#10);E#9;VV#15|X#8,(var X#14)|} in A#16[(app A#17[(var X#8)] C#18[(var X#14)])]) <-cpx-in1- (letrec {X#14=(var X#6);X#6=(\ X#7.S#10);E#9;VV#15|X#8,(var X#14)|} in A#16[(app A#17[(var X#8)] C#18[(var X#6)])]) ................................................................................ (letrec {X#14=(var X#6);X#6=(\ X#7.S#10);E#9;VV#15|X#8,(var X#14)|} in A#16[(app A#17[(var X#8)] C#18[(var X#14)])]) -SR,cp-in2-> (letrec {X#14=(var X#6);X#6=(\ X#7.S#10);E#9;VV#15|X#8,(var X#14)|} in A#16[(app A#17[(\ X#7.S#10)] C#18[(var X#14)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#9 ;EE#13[X#8,A#11[(var X#6)]] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec X#6= (\ X#7.S#10) ;E#9 ;EE#13[X#8,A#11[(\ X#7.S#10)]] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#12,T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17)]), T#14 |-> A#15[(app A#16[(var X#8)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;X#6= (\ X#7.S#10) ;E#17 ;EE#13[X#8,A#11[(var X#6)]] in A#12[(var X#8)] ) , (letrec X#15= T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= (\ X#7.S#10) ;E#17 ;EE#13[X#8,A#11[(\ X#7.S#10)]] in A#12[(var X#8)] ) ) where Delta1 = {T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#15=T#14;X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]), E#9 |-> {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#17}, E#16 |-> {X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]] ;E#9 in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#18[A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]] ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#19,A#17,T#14,T#4,A#11,A#18} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#20[(app A#21[[.]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22)]];E#9} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9}, A#17 |-> A#18, T#14 |-> A#18[A#20[(app A#21[(var X#6)] T#22)]], T#19 |-> A#20[(app A#21[(var X#6)] T#22)], A#11 |-> A#20[(app A#21 T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];E#9} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]];E#9} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];E#9} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#9 in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[A#11[(\ X#7.S#10)]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20)];E#9} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9}, T#14 |-> A#18[(app A#19[A#11[(var X#6)]] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#9} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(\ X#7.S#10)]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[(var X#6)] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#9 in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[(\ X#7.S#10)] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#18[(app A#19[[.]] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20)];E#9} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9}, A#17 |-> [.], T#14 |-> A#18[(app A#19[(var X#6)] T#20)], A#11 |-> A#18[(app A#19 T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#9} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(\ X#7.S#10)] T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#9 ;EE#19[X#18,A#11[(var X#6)]] in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#9 ;EE#19[X#18,A#11[(\ X#7.S#10)]] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22)];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#19[X#18,[.2]]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#18,A#11[(var X#6)]]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#19[X#18,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,A#11[(var X#6)]] in A#12[(var X#8)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,A#11[(\ X#7.S#10)]] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[A#22[(app A#23[(\ X#7.S#10)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {T#21,A#17,T#14,T#4,A#11,A#20} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#22[(app A#23[[.]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24)]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[A#22[(app A#23[(var X#6)] T#24)]], T#21 |-> A#22[(app A#23[(var X#6)] T#24)], A#11 |-> A#22[(app A#23 T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(app A#23[(\ X#7.S#10)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[A#11[(\ X#7.S#10)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22)];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]}, T#14 |-> A#20[(app A#21[A#11[(var X#6)]] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[A#11[(\ X#7.S#10)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#4,A#11} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),A#20[(app A#21[[.]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#20[(app A#21[(var X#6)] T#22)];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]}, A#17 |-> [.], T#14 |-> A#20[(app A#21[(var X#6)] T#22)], A#11 |-> A#20[(app A#21 T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-cpx-in1- (letrec {X#18=A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#6= (\ X#7.S#10) ;E#14 ;EE#13[X#8,A#11[(var X#6)]] in A#15[(app A#16[(var X#8)] C#17[(var X#2)])] ) , (letrec X#1= (var X#2) ;X#6= (\ X#7.S#10) ;E#14 ;EE#13[X#8,A#11[(\ X#7.S#10)]] in A#15[(app A#16[(var X#8)] C#17[(var X#1)])] ) ) where Delta1 = {A#12,C#5,A#11} Delta2 = {} Delta3 = {((var X#1),A#15[(app A#16[(var X#8)] C#17)]), ((var X#2),A#15[(app A#16[(var X#8)] C#17)]), ((var X#1),A#15[(app A#16[(var X#8)] C#17[[.]])]), ((var X#6),A#11[[.]]), ((var X#8),A#15[(app A#16[[.]] C#17[(var X#1)])]), ((var X#8),A#15[(app A#16[[.]] C#17[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], E#9 |-> {X#1=(var X#2);E#14}, E#3 |-> {X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]}, C#5 |-> A#15[(app A#16[(var X#8)] C#17)], A#12 |-> A#15[(app A#16 C#17[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] C#17[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] C#17[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] C#17[(var X#1)])]) -SR,cp-e1-> (letrec {X#1=(var X#2);X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#15[(app A#16[(var X#8)] C#17[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(var X#6)]] in A#17[(var X#2)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(\ X#7.S#10)]] in A#17[(var X#8)] ) ) where Delta1 = {A#12,C#5,A#11,A#17} Delta2 = {} Delta3 = {((var X#8),A#17[[.]]), ((var X#2),A#17[[.]]), ((var X#8),A#17[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#17[[.]]), ((var X#8),A#17[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=(var X#2);EE#16[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#2,A#11[(var X#6)]]}, A#14 |-> [.], X#15 |-> X#2, A#12 |-> A#17, C#5 |-> A#17[[.]], C#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(var X#2)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(\ X#7.S#10)]]} in A#17[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(var X#6)]] in A#17[(var X#2)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(\ X#7.S#10)]] in A#17[(var X#8)] ) ) where Delta1 = {A#12,C#5,A#11,A#17} Delta2 = {} Delta3 = {((var X#8),A#17), ((var X#2),A#17), ((var X#8),A#17[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#17[[.]]), ((var X#8),A#17[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=(var X#2);EE#16[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#2,A#11[(var X#6)]]}, A#14 |-> [.], X#15 |-> X#2, A#12 |-> A#17[[.]], C#5 |-> A#17, A#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(var X#2)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(\ X#7.S#10)]]} in A#17[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(var X#6)]] in A#17[(app A#18[(var X#8)] C#19[(var X#2)])] ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(\ X#7.S#10)]] in A#17[(app A#18[(var X#8)] C#19[(var X#8)])] ) ) where Delta1 = {A#12,C#5,A#11} Delta2 = {} Delta3 = {((var X#8),A#17[(app A#18[(var X#8)] C#19)]), ((var X#2),A#17[(app A#18[(var X#8)] C#19)]), ((var X#8),A#17[(app A#18[(var X#8)] C#19[[.]])]), ((var X#6),A#11[[.]]), ((var X#8),A#17[(app A#18[[.]] C#19[(var X#8)])]), ((var X#8),A#17[(app A#18[[.]] C#19[(var X#8)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=(var X#2);EE#16[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#2,A#11[(var X#6)]]}, A#14 |-> [.], X#15 |-> X#2, C#5 |-> A#17[(app A#18[(var X#8)] C#19)], A#12 |-> A#17[(app A#18 C#19[(var X#8)])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#8)])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#2)])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#8)])]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(\ X#7.S#10)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#8)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(var X#6)]] in (var X#2) ) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#2) ;E#9 ;EE#16[X#2,A#11[(\ X#7.S#10)]] in (var X#8) ) ) where Delta1 = {A#11} Delta2 = {} Delta3 = {((var X#8),[.]), ((var X#2),[.]), ((var X#8),[.]), ((var X#6),A#11[[.]]), ((var X#8),[.]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=(var X#2);EE#16[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#2,A#11[(var X#6)]]}, C#5 |-> [.], A#14 |-> [.], X#15 |-> X#2, A#12 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in (var X#8)) <-cpx-in1- (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in (var X#2)) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(var X#6)]]} in (var X#8)) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#2);E#9;EE#16[X#2,A#11[(\ X#7.S#10)]]} in (var X#8)) ================================================================================ Critical Pair: ( (letrec X#15= (var X#2) ;X#6= (\ X#7.S#10) ;E#9 ;EE#17[X#8,(var X#15)] ;EE#18[X#2,A#11[(var X#6)]] in A#19[(app A#20[(var X#8)] C#21[(var X#2)])] ) , (letrec X#15= (var X#2) ;X#6= (\ X#7.S#10) ;E#9 ;EE#17[X#8,(var X#15)] ;EE#18[X#2,A#11[(\ X#7.S#10)]] in A#19[(app A#20[(var X#8)] C#21[(var X#15)])] ) ) where Delta1 = {A#12,C#5,A#11} Delta2 = {} Delta3 = {((var X#15),A#19[(app A#20[(var X#8)] C#21)]), ((var X#2),A#19[(app A#20[(var X#8)] C#21)]), ((var X#15),A#19[(app A#20[(var X#8)] C#21[[.]])]), ((var X#6),A#11[[.]]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#15)])]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#15)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {X#15=(var X#2);EE#17[[.1],(var X#15)];EE#18[X#2,[.2]]}, X#1 |-> X#15, E#3 |-> {X#6=(\ X#7.S#10);E#9;EE#17[X#8,(var X#15)];EE#18[X#2,A#11[(var X#6)]]}, A#14 |-> [.], X#16 |-> X#2, C#5 |-> A#19[(app A#20[(var X#8)] C#21)], A#12 |-> A#19[(app A#20 C#21[(var X#15)])]} and instantiated rules: (letrec {X#15=(var X#2);X#6=(\ X#7.S#10);E#9;EE#17[X#8,(var X#15)];EE#18[X#2,A#11[(var X#6)]]} in A#19[(app A#20[(var X#8)] C#21[(var X#15)])]) <-cpx-in1- (letrec {X#15=(var X#2);X#6=(\ X#7.S#10);E#9;EE#17[X#8,(var X#15)];EE#18[X#2,A#11[(var X#6)]]} in A#19[(app A#20[(var X#8)] C#21[(var X#2)])]) ................................................................................ (letrec {X#15=(var X#2);X#6=(\ X#7.S#10);E#9;EE#17[X#8,(var X#15)];EE#18[X#2,A#11[(var X#6)]]} in A#19[(app A#20[(var X#8)] C#21[(var X#15)])]) -SR,cp-e1-> (letrec {X#15=(var X#2);X#6=(\ X#7.S#10);E#9;EE#17[X#8,(var X#15)];EE#18[X#2,A#11[(\ X#7.S#10)]]} in A#19[(app A#20[(var X#8)] C#21[(var X#15)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#13,T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19)]), T#16 |-> A#17[(app A#18[(var X#8)] T#19)], A#13 |-> A#17[(app A#18 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;X#6= (\ X#7.S#11) ;E#19 ;EE#14[X#8,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#17= T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= (\ X#7.S#11) ;E#19 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=T#16;X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), E#10 |-> {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19}, E#18 |-> {X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#20[A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#21,A#19,T#16,T#4,A#12,A#20} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#22[(app A#23[[.]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24)]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, A#19 |-> A#20, T#16 |-> A#20[A#22[(app A#23[(var X#9)] T#24)]], T#21 |-> A#22[(app A#23[(var X#9)] T#24)], A#12 |-> A#22[(app A#23 T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[A#12[(\ X#7.S#11)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22)];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, T#16 |-> A#20[(app A#21[A#12[(var X#9)]] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(\ X#7.S#11)]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[(\ X#7.S#11)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#20[(app A#21[[.]] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22)];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, A#19 |-> [.], T#16 |-> A#20[(app A#21[(var X#9)] T#22)], A#12 |-> A#20[(app A#21 T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(\ X#7.S#11)] T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#10 ;EE#21[X#20,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#10 ;EE#21[X#20,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24)];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#21[X#20,[.2]]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#10;EE#21[X#20,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#22[X#8,(var X#20)] ;EE#23[X#21,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#22[X#8,(var X#20)] ;EE#23[X#21,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#22[A#24[(app A#25[(\ X#7.S#11)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#23,A#19,T#16,T#4,A#12,A#22} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#24[(app A#25[[.]] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26)]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|}, A#19 |-> A#22, T#16 |-> A#22[A#24[(app A#25[(var X#9)] T#26)]], T#23 |-> A#24[(app A#25[(var X#9)] T#26)], A#12 |-> A#24[(app A#25 T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#22[A#24[(app A#25[(\ X#7.S#11)] T#26[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#22[(app A#23[A#12[(\ X#7.S#11)]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24)];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|}, T#16 |-> A#22[(app A#23[A#12[(var X#9)]] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#22[(app A#23[A#12[(\ X#7.S#11)]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#16,T#4,A#12} Delta2 = {} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#22[(app A#23[[.]] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#22[(app A#23[(var X#9)] T#24)];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|}, A#19 |-> [.], T#16 |-> A#22[(app A#23[(var X#9)] T#24)], A#12 |-> A#22[(app A#23 T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-cpx-in1- (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#6= (\ X#7.S#11) ;E#16 ;EE#14[X#8,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] C#19[(var X#2)])] ) , (letrec X#1= (var X#2) ;X#6= (\ X#7.S#11) ;E#16 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] C#19[(var X#1)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#1),A#17[(app A#18[(var X#8)] C#19)]), ((var X#2),A#17[(app A#18[(var X#8)] C#19)]), ((var X#1),A#17[(app A#18[(var X#8)] C#19[[.]])]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] C#19[(var X#1)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] C#19[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], E#10 |-> {X#1=(var X#2);E#16}, E#3 |-> {X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, C#5 |-> A#17[(app A#18[(var X#8)] C#19)], A#13 |-> A#17[(app A#18 C#19[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] C#19[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] C#19[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] C#19[(var X#1)])]) -SR,cp-e2-> (letrec {X#1=(var X#2);X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] C#19[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#9= (var X#6) ;E#10 ;EE#14[X#8,A#12[(var X#9)]] in A#17[(app A#18[(var X#8)] C#19[(var X#6)])] ) , (letrec X#6= (\ X#7.S#11) ;X#9= (var X#6) ;E#10 ;EE#14[X#8,A#12[(\ X#7.S#11)]] in A#17[(app A#18[(var X#8)] C#19[(var X#9)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#9),A#17[(app A#18[(var X#8)] C#19)]), ((var X#6),A#17[(app A#18[(var X#8)] C#19)]), ((var X#9),A#17[(app A#18[(var X#8)] C#19[[.]])]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] C#19[(var X#9)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] C#19[(var X#9)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], VV#15|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#9, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]]}, C#5 |-> A#17[(app A#18[(var X#8)] C#19)], A#13 |-> A#17[(app A#18 C#19[(var X#9)])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#9=(var X#6);E#10;EE#14[X#8,A#12[(var X#9)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#9)])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#9=(var X#6);E#10;EE#14[X#8,A#12[(var X#9)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#6)])]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#9=(var X#6);E#10;EE#14[X#8,A#12[(var X#9)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#9)])]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#9=(var X#6);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]]} in A#17[(app A#18[(var X#8)] C#19[(var X#9)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#9= (var X#17) ;E#10 ;EE#14[X#8,A#12[(var X#9)]] ;VV#18|X#17,(var X#6)| in A#19[(app A#20[(var X#8)] C#21[(var X#17)])] ) , (letrec X#6= (\ X#7.S#11) ;X#9= (var X#17) ;E#10 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#18|X#17,(var X#6)| in A#19[(app A#20[(var X#8)] C#21[(var X#9)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#9),A#19[(app A#20[(var X#8)] C#21)]), ((var X#17),A#19[(app A#20[(var X#8)] C#21)]), ((var X#9),A#19[(app A#20[(var X#8)] C#21[[.]])]), ((var X#6),[.]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#9)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#9)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], VV#15|.1,.2| |-> {[.1]=(var X#17);VV#18|X#17,[.2]|}, X#1 |-> X#9, X#2 |-> X#17, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#17,(var X#6)|}, C#5 |-> A#19[(app A#20[(var X#8)] C#21)], A#13 |-> A#19[(app A#20 C#21[(var X#9)])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#9=(var X#17);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#17,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#9)])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#9=(var X#17);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#17,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#17)])]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#9=(var X#17);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#17,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#9)])]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#9=(var X#17);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#18|X#17,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#9)])]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#18) ;X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(var X#9)]] ;VV#19|X#9,(var X#17)| ;VV#20|X#18,(var X#6)| in A#21[(app A#22[(var X#8)] C#23[(var X#18)])] ) , (letrec X#17= (var X#18) ;X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#19|X#9,(var X#17)| ;VV#20|X#18,(var X#6)| in A#21[(app A#22[(var X#8)] C#23[(var X#17)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#17),A#21[(app A#22[(var X#8)] C#23)]), ((var X#18),A#21[(app A#22[(var X#8)] C#23)]), ((var X#17),A#21[(app A#22[(var X#8)] C#23[[.]])]), ((var X#6),[.]), ((var X#8),A#21[(app A#22[[.]] C#23[(var X#17)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#21[(app A#22[[.]] C#23[(var X#17)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], VV#15|.1,.2| |-> {X#17=(var X#18);VV#19|[.1],(var X#17)|;VV#20|X#18,[.2]|}, X#1 |-> X#17, X#2 |-> X#18, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#19|X#9,(var X#17)|;VV#20|X#18,(var X#6)|}, C#5 |-> A#21[(app A#22[(var X#8)] C#23)], A#13 |-> A#21[(app A#22 C#23[(var X#17)])]} and instantiated rules: (letrec {X#17=(var X#18);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#19|X#9,(var X#17)|;VV#20|X#18,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#17)])]) <-cpx-in1- (letrec {X#17=(var X#18);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#19|X#9,(var X#17)|;VV#20|X#18,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#18)])]) ................................................................................ (letrec {X#17=(var X#18);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#19|X#9,(var X#17)|;VV#20|X#18,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#17)])]) -SR,cp-e2-> (letrec {X#17=(var X#18);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#19|X#9,(var X#17)|;VV#20|X#18,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#17)])]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#6) ;X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(var X#9)]] ;VV#18|X#9,(var X#17)| in A#19[(app A#20[(var X#8)] C#21[(var X#6)])] ) , (letrec X#17= (var X#6) ;X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#18|X#9,(var X#17)| in A#19[(app A#20[(var X#8)] C#21[(var X#17)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#17),A#19[(app A#20[(var X#8)] C#21)]), ((var X#6),A#19[(app A#20[(var X#8)] C#21)]), ((var X#17),A#19[(app A#20[(var X#8)] C#21[[.]])]), ((var X#6),[.]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#17)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#17)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], VV#15|.1,.2| |-> {X#17=[.2];VV#18|[.1],(var X#17)|}, X#1 |-> X#17, X#2 |-> X#6, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#9,(var X#17)|}, C#5 |-> A#19[(app A#20[(var X#8)] C#21)], A#13 |-> A#19[(app A#20 C#21[(var X#17)])]} and instantiated rules: (letrec {X#17=(var X#6);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#9,(var X#17)|} in A#19[(app A#20[(var X#8)] C#21[(var X#17)])]) <-cpx-in1- (letrec {X#17=(var X#6);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#9,(var X#17)|} in A#19[(app A#20[(var X#8)] C#21[(var X#6)])]) ................................................................................ (letrec {X#17=(var X#6);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#18|X#9,(var X#17)|} in A#19[(app A#20[(var X#8)] C#21[(var X#17)])]) -SR,cp-e2-> (letrec {X#17=(var X#6);X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#18|X#9,(var X#17)|} in A#19[(app A#20[(var X#8)] C#21[(var X#17)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#19[(var X#2)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#19[(var X#8)] ) ) where Delta1 = {A#13,C#5,A#12,A#19} Delta2 = {} Delta3 = {((var X#8),A#19[[.]]), ((var X#2),A#19[[.]]), ((var X#8),A#19[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=(var X#2);EE#18[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, A#16 |-> [.], X#17 |-> X#2, A#13 |-> A#19, C#5 |-> A#19[[.]], C#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#2)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#19[(var X#2)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#19[(var X#8)] ) ) where Delta1 = {A#13,C#5,A#12,A#19} Delta2 = {} Delta3 = {((var X#8),A#19), ((var X#2),A#19), ((var X#8),A#19[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=(var X#2);EE#18[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, A#16 |-> [.], X#17 |-> X#2, A#13 |-> A#19[[.]], C#5 |-> A#19, A#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#2)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#19[(app A#20[(var X#8)] C#21[(var X#2)])] ) , (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#19[(app A#20[(var X#8)] C#21[(var X#8)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#8),A#19[(app A#20[(var X#8)] C#21)]), ((var X#2),A#19[(app A#20[(var X#8)] C#21)]), ((var X#8),A#19[(app A#20[(var X#8)] C#21[[.]])]), ((var X#6),[.]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#8)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[(app A#20[[.]] C#21[(var X#8)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=(var X#2);EE#18[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, A#16 |-> [.], X#17 |-> X#2, C#5 |-> A#19[(app A#20[(var X#8)] C#21)], A#13 |-> A#19[(app A#20 C#21[(var X#8)])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#8)])]) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#2)])]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#8)])]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#19[(app A#20[(var X#8)] C#21[(var X#8)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in (var X#2) ) , (letrec X#6= (\ X#7.S#11) ;X#8= (var X#2) ;E#10 ;EE#18[X#2,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in (var X#8) ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#8),[.]), ((var X#2),[.]), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=(var X#2);EE#18[X#2,[.2]]}, X#1 |-> X#8, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, C#5 |-> [.], A#16 |-> [.], X#17 |-> X#2, A#13 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in (var X#8)) <-cpx-in1- (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in (var X#2)) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in (var X#8)) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=(var X#2);E#10;EE#18[X#2,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in (var X#8)) ================================================================================ Critical Pair: ( (letrec X#17= (var X#2) ;X#6= (\ X#7.S#11) ;E#10 ;EE#19[X#8,(var X#17)] ;EE#20[X#2,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#21[(app A#22[(var X#8)] C#23[(var X#2)])] ) , (letrec X#17= (var X#2) ;X#6= (\ X#7.S#11) ;E#10 ;EE#19[X#8,(var X#17)] ;EE#20[X#2,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#21[(app A#22[(var X#8)] C#23[(var X#17)])] ) ) where Delta1 = {A#13,C#5,A#12} Delta2 = {} Delta3 = {((var X#17),A#21[(app A#22[(var X#8)] C#23)]), ((var X#2),A#21[(app A#22[(var X#8)] C#23)]), ((var X#17),A#21[(app A#22[(var X#8)] C#23[[.]])]), ((var X#6),[.]), ((var X#8),A#21[(app A#22[[.]] C#23[(var X#17)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#21[(app A#22[[.]] C#23[(var X#17)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#1),C#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {X#17=(var X#2);EE#19[[.1],(var X#17)];EE#20[X#2,[.2]]}, X#1 |-> X#17, E#3 |-> {X#6=(\ X#7.S#11);E#10;EE#19[X#8,(var X#17)];EE#20[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, A#16 |-> [.], X#18 |-> X#2, C#5 |-> A#21[(app A#22[(var X#8)] C#23)], A#13 |-> A#21[(app A#22 C#23[(var X#17)])]} and instantiated rules: (letrec {X#17=(var X#2);X#6=(\ X#7.S#11);E#10;EE#19[X#8,(var X#17)];EE#20[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#17)])]) <-cpx-in1- (letrec {X#17=(var X#2);X#6=(\ X#7.S#11);E#10;EE#19[X#8,(var X#17)];EE#20[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#2)])]) ................................................................................ (letrec {X#17=(var X#2);X#6=(\ X#7.S#11);E#10;EE#19[X#8,(var X#17)];EE#20[X#2,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#17)])]) -SR,cp-e2-> (letrec {X#17=(var X#2);X#6=(\ X#7.S#11);E#10;EE#19[X#8,(var X#17)];EE#20[X#2,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#21[(app A#22[(var X#8)] C#23[(var X#17)])]) ================================================================================ Critical Pair: ( (letrec E#6 in (letrec {E#7} in T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ) , (letrec {E#6;E#7} in T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) ) where Delta1 = {T#9,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), [{E#6},(letrec {E#7} in [.])], ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),[{E#6},(letrec {E#7} in [.])],((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (letrec {E#7} in T#10)), T#9 |-> (letrec {E#7} in T#10), S#8 |-> T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in (letrec {E#7} in T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) <-cpx-in1- (letrec {E#6} in (letrec {E#7} in T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])) ................................................................................ (letrec {E#6} in (letrec {E#7} in T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) -SR,llet-in1-> (letrec {E#6;E#7} in T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec E#6 in (letrec {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#13} in S#8) ) , (letrec X#11= T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#13 ;E#6 in S#8 ) ) where Delta1 = {T#9,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), [{E#6},(letrec {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#13} in [.])], ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),[{E#6},(letrec {E#7} in [.])],((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (letrec {X#11=T#10;E#13} in S#8)), T#9 |-> (letrec {X#11=T#10;E#13} in S#8), E#7 |-> {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {E#6} in (letrec {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#13} in S#8)) <-cpx-in1- (letrec {E#6} in (letrec {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#13} in S#8)) ................................................................................ (letrec {E#6} in (letrec {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#13} in S#8)) -SR,llet-in1-> (letrec {X#11=T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#13;E#6} in S#8) ================================================================================ Critical Pair: ( (letrec {E#6} in (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])) , (letrec {X#1=(var X#2);E#3;E#6} in C#5[(var X#1)]) ) where Delta1 = {T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), [{E#6},(letrec {X#1=(var X#2);E#3} in [.])], ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),[{E#6},(letrec {E#7} in [.])],((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in [.]), T#9 |-> [.], S#8 |-> C#5[(var X#1)], E#7 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {E#6} in (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])) <-cpx-in1- (letrec {E#6} in (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])) ................................................................................ (letrec {E#6} in (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])) -SR,llet-in1-> (letrec {X#1=(var X#2);E#3;E#6} in C#5[(var X#1)]) ================================================================================ Critical Pair: ( (letrec X#10= T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#12 in (letrec {E#7} in S#8) ) , (letrec X#10= T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#12 ;E#7 in S#8 ) ) where Delta1 = {T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), [{X#10=T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#12},(letrec {E#7} in [.])], ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),[{E#6},(letrec {E#7} in [.])],((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#10=T#9;E#12} in (letrec {E#7} in S#8)), E#6 |-> {X#10=T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {X#10=T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#12} in (letrec {E#7} in S#8)) <-cpx-in1- (letrec {X#10=T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#12} in (letrec {E#7} in S#8)) ................................................................................ (letrec {X#10=T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#12} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {X#10=T#9[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#12;E#7} in S#8) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#9} in (letrec {E#7} in C#10[(var X#2)])) , (letrec {X#1=(var X#2);E#7;E#9} in C#10[(var X#1)]) ) where Delta1 = {C#5} Delta2 = {E#6,E#7} Delta3 = {((var X#1),(letrec {E#7} in C#10)), ((var X#2),(letrec {E#7} in C#10)), [{X#1=(var X#2);E#9},(letrec {E#7} in [.])], ((var X#1),(letrec {E#7} in C#10[[.]]))} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),[{E#6},(letrec {E#7} in [.])],((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#9}, E#3 |-> {E#9}, C#5 |-> (letrec {E#7} in C#10), S#8 |-> C#10[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#9} in (letrec {E#7} in C#10[(var X#1)])) <-cpx-in1- (letrec {X#1=(var X#2);E#9} in (letrec {E#7} in C#10[(var X#2)])) ................................................................................ (letrec {X#1=(var X#2);E#9} in (letrec {E#7} in C#10[(var X#1)])) -SR,llet-in1-> (letrec {X#1=(var X#2);E#7;E#9} in C#10[(var X#1)]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#9} in (letrec {X#11=C#10[(var X#2)];E#13} in S#8)) , (letrec {X#1=(var X#2);X#11=C#10[(var X#1)];E#13;E#9} in S#8) ) where Delta1 = {C#5} Delta2 = {E#6,E#7} Delta3 = {((var X#1),(letrec {X#11=C#10;E#13} in S#8)), ((var X#2),(letrec {X#11=C#10;E#13} in S#8)), [{X#1=(var X#2);E#9},(letrec {X#11=C#10[(var X#1)];E#13} in [.])], ((var X#1),(letrec {X#11=C#10[[.]];E#13} in S#8))} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),[{E#6},(letrec {E#7} in [.])],((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#9}, E#3 |-> {E#9}, C#5 |-> (letrec {X#11=C#10;E#13} in S#8), E#7 |-> {X#11=C#10[(var X#1)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#1=(var X#2);E#9} in (letrec {X#11=C#10[(var X#1)];E#13} in S#8)) <-cpx-in1- (letrec {X#1=(var X#2);E#9} in (letrec {X#11=C#10[(var X#2)];E#13} in S#8)) ................................................................................ (letrec {X#1=(var X#2);E#9} in (letrec {X#11=C#10[(var X#1)];E#13} in S#8)) -SR,llet-in1-> (letrec {X#1=(var X#2);X#11=C#10[(var X#1)];E#13;E#9} in S#8) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#7} in S#9) ;E#8 in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec X#6= S#9 ;E#7 ;E#8 in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])],(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#1),C#5[[.]]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),C#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14)]), T#11 |-> A#12[(app A#13[(var X#6)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#7} in T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ;E#8 in A#10[(var X#6)] ) , (letrec X#6= T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {T#11,T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#1),C#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),C#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#7} in T#14);E#8} in A#10[(var X#6)]), X#12 |-> X#6, E#13 |-> {E#8}, T#11 |-> (letrec {E#7} in T#14), S#9 |-> T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(letrec {E#7} in T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#8} in A#10[(var X#6)]) <-cpx-in1- (letrec {X#6=(letrec {E#7} in T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]);E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {E#7} in T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#17} in S#9) ;E#8 in A#10[(var X#6)] ) , (letrec X#15= T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= S#9 ;E#17 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {T#11,T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (A#10[(var X#6)],(letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#17} in [.])), [{E#8},(letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#17} in [.])], ((var X#1),C#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),C#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {X#15=T#14;E#17} in S#9);E#8} in A#10[(var X#6)]), X#12 |-> X#6, E#13 |-> {E#8}, T#11 |-> (letrec {X#15=T#14;E#17} in S#9), E#7 |-> {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#6=(letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#17} in S#9);E#8} in A#10[(var X#6)]) <-cpx-in1- (letrec {X#6=(letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#17} in S#9);E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#17} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#15=T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=S#9;E#17;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) ;E#8 in A#10[(var X#6)] ) , (letrec {X#1=(var X#2);X#6=C#5[(var X#1)];E#3;E#8} in A#10[(var X#6)]) ) where Delta1 = {T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (A#10[(var X#6)],(letrec {X#1=(var X#2);E#3} in [.])), [{E#8},(letrec {X#1=(var X#2);E#3} in [.])], ((var X#1),C#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),C#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=[.];E#8} in A#10[(var X#6)]), X#12 |-> X#6, E#13 |-> {E#8}, T#11 |-> [.], S#9 |-> C#5[(var X#1)], E#7 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {X#6=(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]);E#8} in A#10[(var X#6)]) <-cpx-in1- (letrec {X#6=(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]);E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#1=(var X#2);X#6=C#5[(var X#1)];E#3;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;X#6= (letrec {E#7} in S#9) ;E#14 in A#10[(var X#6)] ) , (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= S#9 ;E#14 ;E#7 in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14},(letrec {E#7} in [.])], ((var X#1),C#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),C#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]), E#8 |-> {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14}, E#13 |-> {X#6=(letrec {E#7} in S#9);E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]) <-cpx-in1- (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=S#9;E#14;E#7} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#6= (letrec {E#7} in S#9) ;E#11 in A#12[(app A#13[(var X#6)] C#14[(var X#2)])] ) , (letrec X#1= (var X#2) ;X#6= S#9 ;E#11 ;E#7 in A#12[(app A#13[(var X#6)] C#14[(var X#1)])] ) ) where Delta1 = {A#10,C#5} Delta2 = {E#7} Delta3 = {((var X#1),A#12[(app A#13[(var X#6)] C#14)]), ((var X#2),A#12[(app A#13[(var X#6)] C#14)]), (A#12[(app A#13[(var X#6)] C#14[(var X#1)])],(letrec {E#7} in [.])), [{X#1=(var X#2);E#11},(letrec {E#7} in [.])], ((var X#1),A#12[(app A#13[(var X#6)] C#14[[.]])]), ((var X#6),A#12[(app A#13[[.]] C#14[(var X#1)])]), ((var X#6),A#12[(app A#13[[.]] C#14[(var X#1)])])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),C#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], E#8 |-> {X#1=(var X#2);E#11}, E#3 |-> {X#6=(letrec {E#7} in S#9);E#11}, C#5 |-> A#12[(app A#13[(var X#6)] C#14)], A#10 |-> A#12[(app A#13 C#14[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] C#14[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] C#14[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] C#14[(var X#1)])]) -SR,llet-e1-> (letrec {X#1=(var X#2);X#6=S#9;E#11;E#7} in A#12[(app A#13[(var X#6)] C#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;E#9 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec X#6= S#10 ;E#8 ;E#9 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])],(letrec {E#8} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#6= T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#8 ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in T#16);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), X#14 |-> X#6, E#15 |-> {E#9;EE#12[X#7,(var X#6)]}, T#13 |-> (letrec {E#8} in T#16), S#10 |-> T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {E#8} in T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec X#17= T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#19 in S#10 ) ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#17= T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= S#10 ;E#19 ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {X#17=T#16;E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), X#14 |-> X#6, E#15 |-> {E#9;EE#12[X#7,(var X#6)]}, T#13 |-> (letrec {X#17=T#16;E#19} in S#10), E#8 |-> {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#6=(letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#17=T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=S#10;E#19;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#1= (var X#2) ;X#6= C#5[(var X#1)] ;E#3 ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#1=(var X#2);E#3;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {X#1=(var X#2);E#3} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {X#1=(var X#2);E#3} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=[.];E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), X#14 |-> X#6, E#15 |-> {E#9;EE#12[X#7,(var X#6)]}, T#13 |-> [.], S#10 |-> C#5[(var X#1)], E#8 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {X#6=(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#1=(var X#2);X#6=C#5[(var X#1)];E#3;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;X#6= (letrec {E#8} in S#10) ;E#16 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;X#6= S#10 ;E#16 ;E#8 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;E#8;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), E#9 |-> {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16}, E#15 |-> {X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];X#6=S#10;E#16;E#8;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#9 in A#11[(var X#7)] ) , (letrec X#6= S#10 ;X#7= A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#8 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;E#9} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19)];E#9} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]}, X#14 |-> X#7, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9}, T#13 |-> A#17[(app A#18[(var X#6)] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#9 ;EE#18[X#17,(var X#6)] in A#11[(var X#7)] ) , (letrec X#6= S#10 ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#8 ;E#9 ;EE#18[X#17,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;E#9;EE#18[X#17,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#18[X#17,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21)];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#18[X#17,(var X#6)]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (letrec {E#8} in S#10) ;E#9 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,(var X#6)] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= S#10 ;E#8 ;E#9 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=S#10;E#8;E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;X#6= (letrec {E#8} in S#10) ;E#9 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;X#6= S#10 ;E#8 ;E#9 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), ((var X#6),(letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#8;E#9;EE#18[X#7,(var X#17)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#9;EE#18[X#7,(var X#17)]},(letrec {E#8} in [.])], ((var X#1),C#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(var X#6)] T#21)];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[(var X#6)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-cpx-in1- (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];X#6=S#10;E#8;E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#6= (letrec {E#8} in S#10) ;E#13 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] C#16[(var X#2)])] ) , (letrec X#1= (var X#2) ;X#6= S#10 ;E#13 ;E#8 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] C#16[(var X#1)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#1),A#14[(app A#15[(var X#7)] C#16)]), ((var X#2),A#14[(app A#15[(var X#7)] C#16)]), ((var X#6),(letrec {X#1=(var X#2);E#13;E#8;EE#12[X#7,(var X#6)]} in [.])), (A#14[(app A#15[(var X#7)] C#16[(var X#1)])],(letrec {E#8} in [.])), [{X#1=(var X#2);E#13;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),A#14[(app A#15[(var X#7)] C#16[[.]])]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] C#16[(var X#1)])]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] C#16[(var X#1)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], E#9 |-> {X#1=(var X#2);E#13}, E#3 |-> {X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]}, C#5 |-> A#14[(app A#15[(var X#7)] C#16)], A#11 |-> A#14[(app A#15 C#16[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] C#16[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] C#16[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] C#16[(var X#1)])]) -SR,llet-e2-> (letrec {X#1=(var X#2);X#6=S#10;E#13;E#8;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] C#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#2)]) , (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in A#14[(var X#7)]) ) where Delta1 = {A#11,C#5,A#14} Delta2 = {E#8} Delta3 = {((var X#7),A#14[[.]]), ((var X#2),A#14[[.]]), ((var X#2),(letrec {X#7=(var X#2);E#8;E#9} in [.])), (A#14[(var X#7)],(letrec {E#8} in [.])), [{X#7=(var X#2);E#9},(letrec {E#8} in [.])], ((var X#7),A#14[[.]]), ((var X#2),[.]), ((var X#7),A#14[[.]]), ((var X#2),[.]), ((var X#7),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#7, E#3 |-> {X#2=(letrec {E#8} in S#10);E#9}, A#13 |-> [.], X#6 |-> X#2, A#11 |-> A#14, C#5 |-> A#14[[.]], C#15 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#7)]) <-cpx-in1- (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#2)]) ................................................................................ (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#7)]) -SR,llet-e2-> (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in A#14[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#2)]) , (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in A#14[(var X#7)]) ) where Delta1 = {A#11,C#5,A#14} Delta2 = {E#8} Delta3 = {((var X#7),A#14), ((var X#2),A#14), ((var X#2),(letrec {X#7=(var X#2);E#8;E#9} in [.])), (A#14[(var X#7)],(letrec {E#8} in [.])), [{X#7=(var X#2);E#9},(letrec {E#8} in [.])], ((var X#7),A#14[[.]]), ((var X#2),[.]), ((var X#7),A#14[[.]]), ((var X#2),[.]), ((var X#7),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#7, E#3 |-> {X#2=(letrec {E#8} in S#10);E#9}, A#13 |-> [.], X#6 |-> X#2, A#11 |-> A#14[[.]], C#5 |-> A#14, A#15 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#7)]) <-cpx-in1- (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#2)]) ................................................................................ (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(var X#7)]) -SR,llet-e2-> (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in A#14[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#2= (letrec {E#8} in S#10) ;X#7= (var X#2) ;E#9 in A#14[(app A#15[(var X#7)] C#16[(var X#2)])] ) , (letrec X#2= S#10 ;X#7= (var X#2) ;E#8 ;E#9 in A#14[(app A#15[(var X#7)] C#16[(var X#7)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#7),A#14[(app A#15[(var X#7)] C#16)]), ((var X#2),A#14[(app A#15[(var X#7)] C#16)]), ((var X#2),(letrec {X#7=(var X#2);E#8;E#9} in [.])), (A#14[(app A#15[(var X#7)] C#16[(var X#7)])],(letrec {E#8} in [.])), [{X#7=(var X#2);E#9},(letrec {E#8} in [.])], ((var X#7),A#14[(app A#15[(var X#7)] C#16[[.]])]), ((var X#2),[.]), ((var X#7),A#14[(app A#15[[.]] C#16[(var X#7)])]), ((var X#2),[.]), ((var X#7),A#14[(app A#15[[.]] C#16[(var X#7)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#7, E#3 |-> {X#2=(letrec {E#8} in S#10);E#9}, A#13 |-> [.], X#6 |-> X#2, C#5 |-> A#14[(app A#15[(var X#7)] C#16)], A#11 |-> A#14[(app A#15 C#16[(var X#7)])]} and instantiated rules: (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(app A#15[(var X#7)] C#16[(var X#7)])]) <-cpx-in1- (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(app A#15[(var X#7)] C#16[(var X#2)])]) ................................................................................ (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in A#14[(app A#15[(var X#7)] C#16[(var X#7)])]) -SR,llet-e2-> (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in A#14[(app A#15[(var X#7)] C#16[(var X#7)])]) ================================================================================ Critical Pair: ( (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in (var X#2)) , (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in (var X#7)) ) where Delta1 = {} Delta2 = {E#8} Delta3 = {((var X#7),[.]), ((var X#2),[.]), ((var X#2),(letrec {X#7=(var X#2);E#8;E#9} in [.])), ((var X#7),(letrec {E#8} in [.])), [{X#7=(var X#2);E#9},(letrec {E#8} in [.])], ((var X#7),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#2),[.]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#7, E#3 |-> {X#2=(letrec {E#8} in S#10);E#9}, C#5 |-> [.], A#13 |-> [.], X#6 |-> X#2, A#11 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in (var X#7)) <-cpx-in1- (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in (var X#2)) ................................................................................ (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#9} in (var X#7)) -SR,llet-e2-> (letrec {X#2=S#10;X#7=(var X#2);E#8;E#9} in (var X#7)) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= (var X#2) ;E#9 ;EE#15[X#2,(var X#6)] in A#16[(var X#2)] ) , (letrec X#6= S#10 ;X#7= (var X#2) ;E#8 ;E#9 ;EE#15[X#2,(var X#6)] in A#16[(var X#7)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {E#8} Delta3 = {((var X#7),A#16[[.]]), ((var X#2),A#16[[.]]), ((var X#6),(letrec {X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in [.])), (A#16[(var X#7)],(letrec {E#8} in [.])), [{X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#7, E#3 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#2,(var X#6)]}, A#13 |-> [.], X#14 |-> X#2, A#11 |-> A#16, C#5 |-> A#16[[.]], C#17 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#2)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= (var X#2) ;E#9 ;EE#15[X#2,(var X#6)] in A#16[(var X#2)] ) , (letrec X#6= S#10 ;X#7= (var X#2) ;E#8 ;E#9 ;EE#15[X#2,(var X#6)] in A#16[(var X#7)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {E#8} Delta3 = {((var X#7),A#16), ((var X#2),A#16), ((var X#6),(letrec {X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in [.])), (A#16[(var X#7)],(letrec {E#8} in [.])), [{X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#7, E#3 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#2,(var X#6)]}, A#13 |-> [.], X#14 |-> X#2, A#11 |-> A#16[[.]], C#5 |-> A#16, A#17 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#7)]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#2)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in A#16[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= (var X#2) ;E#9 ;EE#15[X#2,(var X#6)] in A#16[(app A#17[(var X#7)] C#18[(var X#2)])] ) , (letrec X#6= S#10 ;X#7= (var X#2) ;E#8 ;E#9 ;EE#15[X#2,(var X#6)] in A#16[(app A#17[(var X#7)] C#18[(var X#7)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#7),A#16[(app A#17[(var X#7)] C#18)]), ((var X#2),A#16[(app A#17[(var X#7)] C#18)]), ((var X#6),(letrec {X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in [.])), (A#16[(app A#17[(var X#7)] C#18[(var X#7)])],(letrec {E#8} in [.])), [{X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),A#16[(app A#17[(var X#7)] C#18[[.]])]), ((var X#6),[.]), ((var X#7),A#16[(app A#17[[.]] C#18[(var X#7)])]), ((var X#6),[.]), ((var X#7),A#16[(app A#17[[.]] C#18[(var X#7)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#7, E#3 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#2,(var X#6)]}, A#13 |-> [.], X#14 |-> X#2, C#5 |-> A#16[(app A#17[(var X#7)] C#18)], A#11 |-> A#16[(app A#17 C#18[(var X#7)])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(app A#17[(var X#7)] C#18[(var X#7)])]) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(app A#17[(var X#7)] C#18[(var X#2)])]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in A#16[(app A#17[(var X#7)] C#18[(var X#7)])]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in A#16[(app A#17[(var X#7)] C#18[(var X#7)])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= (var X#2) ;E#9 ;EE#15[X#2,(var X#6)] in (var X#2) ) , (letrec {X#6=S#10;X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in (var X#7)) ) where Delta1 = {} Delta2 = {E#8} Delta3 = {((var X#7),[.]), ((var X#2),[.]), ((var X#6),(letrec {X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in [.])), ((var X#7),(letrec {E#8} in [.])), [{X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),[.]), ((var X#6),[.]), ((var X#7),[.]), ((var X#6),[.]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#7, E#3 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#2,(var X#6)]}, C#5 |-> [.], A#13 |-> [.], X#14 |-> X#2, A#11 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in (var X#7)) <-cpx-in1- (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in (var X#2)) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=(var X#2);E#9;EE#15[X#2,(var X#6)]} in (var X#7)) -SR,llet-e2-> (letrec {X#6=S#10;X#7=(var X#2);E#8;E#9;EE#15[X#2,(var X#6)]} in (var X#7)) ================================================================================ Critical Pair: ( (letrec X#14= (var X#2) ;X#6= (letrec {E#8} in S#10) ;E#9 ;EE#16[X#7,(var X#14)] ;EE#17[X#2,(var X#6)] in A#18[(app A#19[(var X#7)] C#20[(var X#2)])] ) , (letrec X#14= (var X#2) ;X#6= S#10 ;E#8 ;E#9 ;EE#16[X#7,(var X#14)] ;EE#17[X#2,(var X#6)] in A#18[(app A#19[(var X#7)] C#20[(var X#14)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#14),A#18[(app A#19[(var X#7)] C#20)]), ((var X#2),A#18[(app A#19[(var X#7)] C#20)]), ((var X#6),(letrec {X#14=(var X#2);E#8;E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]} in [.])), (A#18[(app A#19[(var X#7)] C#20[(var X#14)])],(letrec {E#8} in [.])), [{X#14=(var X#2);E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]},(letrec {E#8} in [.])], ((var X#14),A#18[(app A#19[(var X#7)] C#20[[.]])]), ((var X#6),[.]), ((var X#7),A#18[(app A#19[[.]] C#20[(var X#14)])]), ((var X#6),[.]), ((var X#7),A#18[(app A#19[[.]] C#20[(var X#14)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {X#14=(var X#2);EE#16[[.1],(var X#14)];EE#17[X#2,[.2]]}, X#1 |-> X#14, E#3 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]}, A#13 |-> [.], X#15 |-> X#2, C#5 |-> A#18[(app A#19[(var X#7)] C#20)], A#11 |-> A#18[(app A#19 C#20[(var X#14)])]} and instantiated rules: (letrec {X#14=(var X#2);X#6=(letrec {E#8} in S#10);E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]} in A#18[(app A#19[(var X#7)] C#20[(var X#14)])]) <-cpx-in1- (letrec {X#14=(var X#2);X#6=(letrec {E#8} in S#10);E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]} in A#18[(app A#19[(var X#7)] C#20[(var X#2)])]) ................................................................................ (letrec {X#14=(var X#2);X#6=(letrec {E#8} in S#10);E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]} in A#18[(app A#19[(var X#7)] C#20[(var X#14)])]) -SR,llet-e2-> (letrec {X#14=(var X#2);X#6=S#10;E#8;E#9;EE#16[X#7,(var X#14)];EE#17[X#2,(var X#6)]} in A#18[(app A#19[(var X#7)] C#20[(var X#14)])]) ================================================================================ Critical Pair: ( (letrec X#14= (var X#2) ;X#2= (letrec {E#8} in S#10) ;E#9 ;EE#15[X#7,(var X#14)] in A#16[(app A#17[(var X#7)] C#18[(var X#2)])] ) , (letrec X#14= (var X#2) ;X#2= S#10 ;E#8 ;E#9 ;EE#15[X#7,(var X#14)] in A#16[(app A#17[(var X#7)] C#18[(var X#14)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#14),A#16[(app A#17[(var X#7)] C#18)]), ((var X#2),A#16[(app A#17[(var X#7)] C#18)]), ((var X#2),(letrec {X#14=(var X#2);E#8;E#9;EE#15[X#7,(var X#14)]} in [.])), (A#16[(app A#17[(var X#7)] C#18[(var X#14)])],(letrec {E#8} in [.])), [{X#14=(var X#2);E#9;EE#15[X#7,(var X#14)]},(letrec {E#8} in [.])], ((var X#14),A#16[(app A#17[(var X#7)] C#18[[.]])]), ((var X#2),[.]), ((var X#7),A#16[(app A#17[[.]] C#18[(var X#14)])]), ((var X#2),[.]), ((var X#7),A#16[(app A#17[[.]] C#18[(var X#14)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),C#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {X#14=[.2];EE#15[[.1],(var X#14)]}, X#1 |-> X#14, E#3 |-> {X#2=(letrec {E#8} in S#10);E#9;EE#15[X#7,(var X#14)]}, A#13 |-> [.], X#6 |-> X#2, C#5 |-> A#16[(app A#17[(var X#7)] C#18)], A#11 |-> A#16[(app A#17 C#18[(var X#14)])]} and instantiated rules: (letrec {X#14=(var X#2);X#2=(letrec {E#8} in S#10);E#9;EE#15[X#7,(var X#14)]} in A#16[(app A#17[(var X#7)] C#18[(var X#14)])]) <-cpx-in1- (letrec {X#14=(var X#2);X#2=(letrec {E#8} in S#10);E#9;EE#15[X#7,(var X#14)]} in A#16[(app A#17[(var X#7)] C#18[(var X#2)])]) ................................................................................ (letrec {X#14=(var X#2);X#2=(letrec {E#8} in S#10);E#9;EE#15[X#7,(var X#14)]} in A#16[(app A#17[(var X#7)] C#18[(var X#14)])]) -SR,llet-e2-> (letrec {X#14=(var X#2);X#2=S#10;E#8;E#9;EE#15[X#7,(var X#14)]} in A#16[(app A#17[(var X#7)] C#18[(var X#14)])]) ================================================================================ Critical Pair: ( A#10[(app (letrec {E#6} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#7)] , A#10[(letrec {E#6} in (app T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#7))] ) where Delta1 = {T#12,T#11,A#9,T#4,A#10} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {E#6} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (letrec {E#6} in T#13) S#7)], T#11 |-> (app (letrec {E#6} in T#13) S#7), T#12 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: A#10[(app (letrec {E#6} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#7)] <-cpx-in1- A#10[(app (letrec {E#6} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#7)] ................................................................................ A#10[(app (letrec {E#6} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#7)] -SR,lapp1-> A#10[(letrec {E#6} in (app T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#7))] ================================================================================ Critical Pair: ( A#10[(app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#16} in S#8) S#7)] , A#10[(letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#16 in (app S#8 S#7) )] ) where Delta1 = {T#12,T#11,A#9,T#4,A#10} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (letrec {X#14=T#13;E#16} in S#8) S#7)], T#11 |-> (app (letrec {X#14=T#13;E#16} in S#8) S#7), T#12 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16}, E#15 |-> {E#16}} and instantiated rules: A#10[(app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in S#8) S#7)] <-cpx-in1- A#10[(app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#16} in S#8) S#7)] ................................................................................ A#10[(app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in S#8) S#7)] -SR,lapp1-> A#10[(letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in (app S#8 S#7))] ================================================================================ Critical Pair: ( A#10[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#7)] , A#10[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#7))] ) where Delta1 = {T#11,A#9,T#4,A#10} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app [.] S#7)], T#11 |-> (app [.] S#7), T#12 |-> [.], S#8 |-> C#5[(var X#1)], E#6 |-> {X#1=(var X#2);E#3}} and instantiated rules: A#10[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#7)] <-cpx-in1- A#10[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#7)] ................................................................................ A#10[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#7)] -SR,lapp1-> A#10[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#7))] ================================================================================ Critical Pair: ( A#10[(app (letrec {E#6} in S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] , A#10[(letrec {E#6} in (app S#8 T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))] ) where Delta1 = {T#11,A#9,T#4,A#10} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#6} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (letrec {E#6} in S#8) T#12)], T#11 |-> (app (letrec {E#6} in S#8) T#12), S#7 |-> T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: A#10[(app (letrec {E#6} in S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] <-cpx-in1- A#10[(app (letrec {E#6} in S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ................................................................................ A#10[(app (letrec {E#6} in S#8) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] -SR,lapp1-> A#10[(letrec {E#6} in (app S#8 T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))] ================================================================================ Critical Pair: ( A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] , A#10[(app A#11[(letrec {E#6} in (app S#8 S#7))] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) where Delta1 = {A#9,T#4} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {E#6} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12)], A#9 |-> A#10[(app A#11 T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] <-cpx-in1- A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ................................................................................ A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] -SR,lapp1-> A#10[(app A#11[(letrec {E#6} in (app S#8 S#7))] T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ================================================================================ Critical Pair: ( (app (letrec {E#6} in T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#7) , (letrec {E#6} in (app T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#7)) ) where Delta1 = {T#10,T#4} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {E#6} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (letrec {E#6} in T#11) S#7), T#10 |-> (letrec {E#6} in T#11), S#8 |-> T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (app (letrec {E#6} in T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#7) <-cpx-in1- (app (letrec {E#6} in T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#7) ................................................................................ (app (letrec {E#6} in T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#7) -SR,lapp1-> (letrec {E#6} in (app T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#7)) ================================================================================ Critical Pair: ( (app (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#14} in S#8) S#7) , (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#14 in (app S#8 S#7) ) ) where Delta1 = {T#10,T#4} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (letrec {X#12=T#11;E#14} in S#8) S#7), T#10 |-> (letrec {X#12=T#11;E#14} in S#8), E#6 |-> {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (app (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in S#8) S#7) <-cpx-in1- (app (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#14} in S#8) S#7) ................................................................................ (app (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in S#8) S#7) -SR,lapp1-> (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in (app S#8 S#7)) ================================================================================ Critical Pair: ( (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#7) , (letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#7)) ) where Delta1 = {T#4} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#7,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app [.] S#7), T#10 |-> [.], S#8 |-> C#5[(var X#1)], E#6 |-> {X#1=(var X#2);E#3}} and instantiated rules: (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#7) <-cpx-in1- (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#7) ................................................................................ (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#7) -SR,lapp1-> (letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#7)) ================================================================================ Critical Pair: ( (app (letrec {E#6} in S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) , (letrec {E#6} in (app S#8 T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) ) where Delta1 = {T#4} Delta2 = {E#6} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#6} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#7,(letrec {E#6} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (letrec {E#6} in S#8) T#10), S#7 |-> T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (app (letrec {E#6} in S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) <-cpx-in1- (app (letrec {E#6} in S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ................................................................................ (app (letrec {E#6} in S#8) T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) -SR,lapp1-> (letrec {E#6} in (app S#8 T#10[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app (letrec {E#7} in T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#8)] ) , (letrec E#6 in A#12[(letrec {E#7} in (app T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#8))] ) ) where Delta1 = {T#14,T#13,A#10,T#11,T#4,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {E#7} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app (letrec {E#7} in T#15) S#8)]), A#10 |-> A#12, T#11 |-> A#12[(app (letrec {E#7} in T#15) S#8)], T#13 |-> (app (letrec {E#7} in T#15) S#8), T#14 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {E#7} in T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#8)]) <-cpx-in1- (letrec {E#6} in A#12[(app (letrec {E#7} in T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#8)]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {E#7} in T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#8)]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {E#7} in (app T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#8))]) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app (letrec {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#18} in S#9) S#8)] ) , (letrec E#6 in A#12[(letrec X#16= T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#18 in (app S#9 S#8) )] ) ) where Delta1 = {T#14,T#13,A#10,T#11,T#4,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#18} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)]), A#10 |-> A#12, T#11 |-> A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#9) S#8), T#14 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#18} in S#9) S#8)]) <-cpx-in1- (letrec {E#6} in A#12[(app (letrec {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#18} in S#9) S#8)]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#18} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {X#16=T#15[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#18} in (app S#9 S#8))]) ================================================================================ Critical Pair: ( (letrec {E#6} in A#12[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#8)]) , (letrec {E#6} in A#12[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#8))]) ) where Delta1 = {T#13,A#10,T#11,T#4,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app [.] S#8)]), A#10 |-> A#12, T#11 |-> A#12[(app [.] S#8)], T#13 |-> (app [.] S#8), T#14 |-> [.], S#9 |-> C#5[(var X#1)], E#7 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#8)]) <-cpx-in1- (letrec {E#6} in A#12[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#8)]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#8)]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#8))]) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec E#6 in A#12[(letrec {E#7} in (app S#9 T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))] ) ) where Delta1 = {T#13,A#10,T#11,T#4,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14)]), A#10 |-> A#12, T#11 |-> A#12[(app (letrec {E#7} in S#9) T#14)], T#13 |-> (app (letrec {E#7} in S#9) T#14), S#8 |-> T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {E#7} in (app S#9 T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))]) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec E#6 in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {E#7} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)]), T#11 |-> A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,lapp2-> (letrec {E#6} in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] T#14[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec E#6 in (app (letrec {E#7} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#8) ) , (letrec E#6 in (letrec {E#7} in (app T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#8)) ) ) where Delta1 = {T#12,T#11,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {E#7} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (letrec {E#7} in T#13) S#8)), A#10 |-> [.], T#11 |-> (app (letrec {E#7} in T#13) S#8), T#12 |-> (letrec {E#7} in T#13), S#9 |-> T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#8)) <-cpx-in1- (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#8)) ................................................................................ (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#8)) -SR,lapp2-> (letrec {E#6} in (letrec {E#7} in (app T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#8))) ================================================================================ Critical Pair: ( (letrec E#6 in (app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#16} in S#9) S#8) ) , (letrec E#6 in (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#16 in (app S#9 S#8) ) ) ) where Delta1 = {T#12,T#11,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (letrec {X#14=T#13;E#16} in S#9) S#8)), A#10 |-> [.], T#11 |-> (app (letrec {X#14=T#13;E#16} in S#9) S#8), T#12 |-> (letrec {X#14=T#13;E#16} in S#9), E#7 |-> {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {E#6} in (app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in S#9) S#8)) <-cpx-in1- (letrec {E#6} in (app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#16} in S#9) S#8)) ................................................................................ (letrec {E#6} in (app (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in S#9) S#8)) -SR,lapp2-> (letrec {E#6} in (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16} in (app S#9 S#8))) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#8)) , (letrec {E#6} in (letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#8))) ) where Delta1 = {T#11,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app [.] S#8)), A#10 |-> [.], T#11 |-> (app [.] S#8), T#12 |-> [.], S#9 |-> C#5[(var X#1)], E#7 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {E#6} in (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#8)) <-cpx-in1- (letrec {E#6} in (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#8)) ................................................................................ (letrec {E#6} in (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#8)) -SR,lapp2-> (letrec {E#6} in (letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#8))) ================================================================================ Critical Pair: ( (letrec E#6 in (app (letrec {E#7} in S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ) , (letrec E#6 in (letrec {E#7} in (app S#9 T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) ) ) where Delta1 = {T#11,T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (letrec {E#7} in S#9) T#12)), A#10 |-> [.], T#11 |-> (app (letrec {E#7} in S#9) T#12), S#8 |-> T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) <-cpx-in1- (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])) ................................................................................ (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])) -SR,lapp2-> (letrec {E#6} in (letrec {E#7} in (app S#9 T#12[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#14 in A#10[(app (letrec {E#7} in S#9) S#8)] ) , (letrec X#12= T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#14 in A#10[(letrec {E#7} in (app S#9 S#8))] ) ) where Delta1 = {T#4} Delta2 = {E#6,E#7} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#8,(letrec {E#7} in [.])), ((var X#1),C#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]), E#6 |-> {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]) <-cpx-in1- (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {X#12=T#11[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#14} in A#10[(letrec {E#7} in (app S#9 S#8))]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#11 in A#12[(app (letrec {E#7} in C#15[(var X#2)]) S#8)] ) , (letrec X#1= (var X#2) ;E#11 in A#12[(letrec {E#7} in (app C#15[(var X#1)] S#8))] ) ) where Delta1 = {C#14,C#13,A#10,C#5,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),A#12[(app (letrec {E#7} in C#15) S#8)]), ((var X#2),A#12[(app (letrec {E#7} in C#15) S#8)]), (S#8,(letrec {E#7} in [.])), ((var X#1),A#12[(app (letrec {E#7} in C#15[[.]]) S#8)])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> A#12, C#5 |-> A#12[(app (letrec {E#7} in C#15) S#8)], C#13 |-> (app (letrec {E#7} in C#15) S#8), C#14 |-> (letrec {E#7} in C#15), S#9 |-> C#15[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {E#7} in C#15[(var X#1)]) S#8)]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {E#7} in C#15[(var X#2)]) S#8)]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {E#7} in C#15[(var X#1)]) S#8)]) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in A#12[(letrec {E#7} in (app C#15[(var X#1)] S#8))]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#11 in A#12[(app (letrec {X#16=C#15[(var X#2)];E#18} in S#9) S#8)] ) , (letrec X#1= (var X#2) ;E#11 in A#12[(letrec {X#16=C#15[(var X#1)];E#18} in (app S#9 S#8))] ) ) where Delta1 = {C#14,C#13,A#10,C#5,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),A#12[(app (letrec {X#16=C#15;E#18} in S#9) S#8)]), ((var X#2),A#12[(app (letrec {X#16=C#15;E#18} in S#9) S#8)]), (S#8,(letrec {X#16=C#15[(var X#1)];E#18} in [.])), ((var X#1),A#12[(app (letrec {X#16=C#15[[.]];E#18} in S#9) S#8)])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> A#12, C#5 |-> A#12[(app (letrec {X#16=C#15;E#18} in S#9) S#8)], C#13 |-> (app (letrec {X#16=C#15;E#18} in S#9) S#8), C#14 |-> (letrec {X#16=C#15;E#18} in S#9), E#7 |-> {X#16=C#15[(var X#1)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {X#16=C#15[(var X#1)];E#18} in S#9) S#8)]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {X#16=C#15[(var X#2)];E#18} in S#9) S#8)]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {X#16=C#15[(var X#1)];E#18} in S#9) S#8)]) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in A#12[(letrec {X#16=C#15[(var X#1)];E#18} in (app S#9 S#8))]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#11 in A#12[(app (letrec {E#7} in S#9) C#14[(var X#2)])] ) , (letrec X#1= (var X#2) ;E#11 in A#12[(letrec {E#7} in (app S#9 C#14[(var X#1)]))] ) ) where Delta1 = {C#13,A#10,C#5,A#12} Delta2 = {E#6,E#7} Delta3 = {((var X#1),A#12[(app (letrec {E#7} in S#9) C#14)]), ((var X#2),A#12[(app (letrec {E#7} in S#9) C#14)]), (C#14[(var X#1)],(letrec {E#7} in [.])), ((var X#1),A#12[(app (letrec {E#7} in S#9) C#14[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> A#12, C#5 |-> A#12[(app (letrec {E#7} in S#9) C#14)], C#13 |-> (app (letrec {E#7} in S#9) C#14), S#8 |-> C#14[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {E#7} in S#9) C#14[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {E#7} in S#9) C#14[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app (letrec {E#7} in S#9) C#14[(var X#1)])]) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in A#12[(letrec {E#7} in (app S#9 C#14[(var X#1)]))]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#11 in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14[(var X#2)])] ) , (letrec X#1= (var X#2) ;E#11 in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] C#14[(var X#1)])] ) ) where Delta1 = {A#10,C#5} Delta2 = {E#6,E#7} Delta3 = {((var X#1),A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14)]), ((var X#2),A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14)]), (S#8,(letrec {E#7} in [.])), ((var X#1),A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, C#5 |-> A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14)], A#10 |-> A#12[(app A#13 C#14[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] C#14[(var X#1)])]) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] C#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in C#13[(var X#2)]) S#8)) , (letrec {X#1=(var X#2);E#11} in (letrec {E#7} in (app C#13[(var X#1)] S#8))) ) where Delta1 = {C#12,C#5} Delta2 = {E#6,E#7} Delta3 = {((var X#1),(app (letrec {E#7} in C#13) S#8)), ((var X#2),(app (letrec {E#7} in C#13) S#8)), (S#8,(letrec {E#7} in [.])), ((var X#1),(app (letrec {E#7} in C#13[[.]]) S#8))} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> [.], C#5 |-> (app (letrec {E#7} in C#13) S#8), C#12 |-> (letrec {E#7} in C#13), S#9 |-> C#13[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in C#13[(var X#1)]) S#8)) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in C#13[(var X#2)]) S#8)) ................................................................................ (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in C#13[(var X#1)]) S#8)) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in (letrec {E#7} in (app C#13[(var X#1)] S#8))) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#11 in (app (letrec {X#14=C#13[(var X#2)];E#16} in S#9) S#8) ) , (letrec X#1= (var X#2) ;E#11 in (letrec {X#14=C#13[(var X#1)];E#16} in (app S#9 S#8)) ) ) where Delta1 = {C#12,C#5} Delta2 = {E#6,E#7} Delta3 = {((var X#1),(app (letrec {X#14=C#13;E#16} in S#9) S#8)), ((var X#2),(app (letrec {X#14=C#13;E#16} in S#9) S#8)), (S#8,(letrec {X#14=C#13[(var X#1)];E#16} in [.])), ((var X#1),(app (letrec {X#14=C#13[[.]];E#16} in S#9) S#8))} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> [.], C#5 |-> (app (letrec {X#14=C#13;E#16} in S#9) S#8), C#12 |-> (letrec {X#14=C#13;E#16} in S#9), E#7 |-> {X#14=C#13[(var X#1)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#1=(var X#2);E#11} in (app (letrec {X#14=C#13[(var X#1)];E#16} in S#9) S#8)) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in (app (letrec {X#14=C#13[(var X#2)];E#16} in S#9) S#8)) ................................................................................ (letrec {X#1=(var X#2);E#11} in (app (letrec {X#14=C#13[(var X#1)];E#16} in S#9) S#8)) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in (letrec {X#14=C#13[(var X#1)];E#16} in (app S#9 S#8))) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in S#9) C#12[(var X#2)])) , (letrec {X#1=(var X#2);E#11} in (letrec {E#7} in (app S#9 C#12[(var X#1)]))) ) where Delta1 = {C#5} Delta2 = {E#6,E#7} Delta3 = {((var X#1),(app (letrec {E#7} in S#9) C#12)), ((var X#2),(app (letrec {E#7} in S#9) C#12)), (C#12[(var X#1)],(letrec {E#7} in [.])), ((var X#1),(app (letrec {E#7} in S#9) C#12[[.]]))} Delta4= {} from overlapping <-SR,lapp2- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#6,E#7} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#8,(letrec {E#7} in [.])),((var X#1),C#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=(var X#2);E#11}, E#3 |-> {E#11}, A#10 |-> [.], C#5 |-> (app (letrec {E#7} in S#9) C#12), S#8 |-> C#12[(var X#1)]} and instantiated rules: (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in S#9) C#12[(var X#1)])) <-cpx-in1- (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in S#9) C#12[(var X#2)])) ................................................................................ (letrec {X#1=(var X#2);E#11} in (app (letrec {E#7} in S#9) C#12[(var X#1)])) -SR,lapp2-> (letrec {X#1=(var X#2);E#11} in (letrec {E#7} in (app S#9 C#12[(var X#1)]))) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)] in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ) , (letrec E#7 ;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))] in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16)]), T#13 |-> A#14[(app A#15[(var X#6)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) <-cpx-in1- (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])]) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#16 ;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#14= T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#16 ;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))] in A#11[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]), E#7 |-> {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16}, E#15 |-> {E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#14=T#13[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#16;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9)] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec {E#8} in (app T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9))] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#18,A#16,T#13,T#4,A#17} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (letrec {E#8} in T#20) S#9)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app (letrec {E#8} in T#20) S#9)], T#18 |-> (app (letrec {E#8} in T#20) S#9), T#19 |-> (letrec {E#8} in T#20), S#10 |-> T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=A#17[(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9)];E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9)];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9)];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {E#8} in (app T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec X#21= T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#23 in S#10 ) S#9)] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec X#21= T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#23 in (app S#10 S#9) )] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#18,A#16,T#13,T#4,A#17} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (letrec {X#21=T#20;E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app (letrec {X#21=T#20;E#23} in S#10) S#9)], T#18 |-> (app (letrec {X#21=T#20;E#23} in S#10) S#9), T#19 |-> (letrec {X#21=T#20;E#23} in S#10), E#8 |-> {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#6=A#17[(app (letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app (letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in (app S#10 S#9))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9)] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9))] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#17} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app [.] S#9)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app [.] S#9)], T#18 |-> (app [.] S#9), T#19 |-> [.], S#10 |-> C#5[(var X#1)], E#8 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {X#6=A#17[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9)];E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9)];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9)];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec E#8 in (app S#10 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) )] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#17} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app (letrec {E#8} in S#10) T#19)], T#18 |-> (app (letrec {E#8} in S#10) T#19), S#9 |-> T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {E#8} in (app S#10 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(app A#18[(letrec {E#8} in (app S#10 S#9))] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]}, X#14 |-> X#6, E#15 |-> {E#7}, T#13 |-> A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(app A#18[(letrec {E#8} in (app S#10 S#9))] T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec {E#8} in T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec {E#8} in (app T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9)) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#17,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (letrec {E#8} in T#18) S#9);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in T#18) S#9), T#17 |-> (letrec {E#8} in T#18), S#10 |-> T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(app (letrec {E#8} in T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9);E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=(app (letrec {E#8} in T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {E#8} in T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {E#8} in (app T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec X#19= T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#21 in S#10 ) S#9) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec X#19= T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#21 in (app S#10 S#9) ) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#17,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#19=T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#21} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (letrec {X#19=T#18;E#21} in S#10) S#9);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app (letrec {X#19=T#18;E#21} in S#10) S#9), T#17 |-> (letrec {X#19=T#18;E#21} in S#10), E#8 |-> {X#19=T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#6=(app (letrec {X#19=T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#21} in S#10) S#9);E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=(app (letrec {X#19=T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#21} in S#10) S#9);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {X#19=T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#21} in S#10) S#9);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {X#19=T#18[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#21} in (app S#10 S#9));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9)) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app [.] S#9);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app [.] S#9), T#17 |-> [.], S#10 |-> C#5[(var X#1)], E#8 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {X#6=(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9);E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec {E#8} in S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec E#8 in (app S#10 T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) ) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (letrec {E#8} in S#10) T#17);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in S#10) T#17), S#9 |-> T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(app (letrec {E#8} in S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#7} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=(app (letrec {E#8} in S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {E#8} in S#10) T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {E#8} in (app S#10 T#17[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#7 ;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#7 ;EE#18[X#17,(letrec {E#8} in (app S#10 S#9))] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21)];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#6, E#15 |-> {E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#17,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#7 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(app (letrec {E#8} in S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#7 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(letrec {E#8} in (app S#10 S#9))] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#8} in T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9)] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {E#8} in (app T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9))] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#21,T#20,A#16,T#13,T#4,A#19} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (letrec {E#8} in T#22) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (letrec {E#8} in T#22) S#9)], T#20 |-> (app (letrec {E#8} in T#22) S#9), T#21 |-> (letrec {E#8} in T#22), S#10 |-> T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#8} in T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app (letrec {E#8} in T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#8} in T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#8} in (app T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec X#23= T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#25 in S#10 ) S#9)] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec X#23= T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#25 in (app S#10 S#9) )] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#21,T#20,A#16,T#13,T#4,A#19} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#23=T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#25} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (letrec {X#23=T#22;E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (letrec {X#23=T#22;E#25} in S#10) S#9)], T#20 |-> (app (letrec {X#23=T#22;E#25} in S#10) S#9), T#21 |-> (letrec {X#23=T#22;E#25} in S#10), E#8 |-> {X#23=T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#17=A#19[(app (letrec {X#23=T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app (letrec {X#23=T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {X#23=T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {X#23=T#22[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#25} in (app S#10 S#9))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9)] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9))] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#19} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app [.] S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app [.] S#9)], T#20 |-> (app [.] S#9), T#21 |-> [.], S#10 |-> C#5[(var X#1)], E#8 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {X#17=A#19[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#8} in S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec E#8 in (app S#10 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) )] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#19} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (letrec {E#8} in S#10) T#21)], T#20 |-> (app (letrec {E#8} in S#10) T#21), S#9 |-> T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#8} in (app S#10 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(app A#20[(letrec {E#8} in (app S#10 S#9))] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, T#13 |-> A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(app A#20[(letrec {E#8} in (app S#10 S#9))] T#21[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {E#8} in (app T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9)) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (letrec {E#8} in T#20) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in T#20) S#9), T#19 |-> (letrec {E#8} in T#20), S#10 |-> T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#17=(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {E#8} in T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {E#8} in (app T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] S#9));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec X#21= T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] ;E#23 in S#10 ) S#9) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec X#21= T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] ;E#23 in (app S#10 S#9) ) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (letrec {X#21=T#20;E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (letrec {X#21=T#20;E#23} in S#10) S#9), T#19 |-> (letrec {X#21=T#20;E#23} in S#10), E#8 |-> {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#17=(app (letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=(app (letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])];E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {X#21=T#20[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])];E#23} in (app S#10 S#9));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9)) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (S#9,(letrec {X#1=(var X#2);E#3} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app [.] S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app [.] S#9), T#19 |-> [.], S#10 |-> C#5[(var X#1)], E#8 |-> {X#1=(var X#2);E#3}} and instantiated rules: (letrec {X#17=(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#2)]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {X#1=(var X#2);E#3} in C#5[(var X#1)]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {X#1=(var X#2);E#3} in (app C#5[(var X#1)] S#9));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec E#8 in (app S#10 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]) ) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#8} Delta3 = {((var X#1),C#5), ((var X#2),C#5), (T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),C#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (letrec {E#8} in S#10) T#19);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in S#10) T#19), S#9 |-> T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]} and instantiated rules: (letrec {X#17=(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-cpx-in1- (letrec {X#17=(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])]);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {E#8} in S#10) T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {E#8} in (app S#10 T#19[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])]));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;E#13 ;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)] in A#14[(app A#15[(var X#6)] C#16[(var X#2)])] ) , (letrec X#1= (var X#2) ;E#13 ;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))] in A#14[(app A#15[(var X#6)] C#16[(var X#1)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#1),A#14[(app A#15[(var X#6)] C#16)]), ((var X#2),A#14[(app A#15[(var X#6)] C#16)]), (S#9,(letrec {E#8} in [.])), ((var X#1),A#14[(app A#15[(var X#6)] C#16[[.]])]), ((var X#6),A#14[(app A#15[[.]] C#16[(var X#1)])]), ((var X#6),A#14[(app A#15[[.]] C#16[(var X#1)])])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=(var X#2);E#13}, E#3 |-> {E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]}, C#5 |-> A#14[(app A#15[(var X#6)] C#16)], A#11 |-> A#14[(app A#15 C#16[(var X#1)])]} and instantiated rules: (letrec {X#1=(var X#2);E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] C#16[(var X#1)])]) <-cpx-in1- (letrec {X#1=(var X#2);E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] C#16[(var X#2)])]) ................................................................................ (letrec {X#1=(var X#2);E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] C#16[(var X#1)])]) -SR,lapp3-> (letrec {X#1=(var X#2);E#13;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#14[(app A#15[(var X#6)] C#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)] in A#16[(var X#2)] ) , (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))] in A#16[(var X#6)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {E#8} Delta3 = {((var X#6),A#16[[.]]), ((var X#2),A#16[[.]]), (S#9,(letrec {E#8} in [.])), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]}, A#13 |-> [.], X#14 |-> X#2, A#11 |-> A#16, C#5 |-> A#16[[.]], C#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) <-cpx-in1- (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#2)]) ................................................................................ (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) -SR,lapp3-> (letrec {X#6=(var X#2);E#7;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)] in A#16[(var X#2)] ) , (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))] in A#16[(var X#6)] ) ) where Delta1 = {A#11,C#5,A#16} Delta2 = {E#8} Delta3 = {((var X#6),A#16), ((var X#2),A#16), (S#9,(letrec {E#8} in [.])), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]}, A#13 |-> [.], X#14 |-> X#2, A#11 |-> A#16[[.]], C#5 |-> A#16, A#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) <-cpx-in1- (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#2)]) ................................................................................ (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) -SR,lapp3-> (letrec {X#6=(var X#2);E#7;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)] in A#16[(app A#17[(var X#6)] C#18[(var X#2)])] ) , (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))] in A#16[(app A#17[(var X#6)] C#18[(var X#6)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#6),A#16[(app A#17[(var X#6)] C#18)]), ((var X#2),A#16[(app A#17[(var X#6)] C#18)]), (S#9,(letrec {E#8} in [.])), ((var X#6),A#16[(app A#17[(var X#6)] C#18[[.]])]), ((var X#6),A#16[(app A#17[[.]] C#18[(var X#6)])]), ((var X#6),A#16[(app A#17[[.]] C#18[(var X#6)])])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]}, A#13 |-> [.], X#14 |-> X#2, C#5 |-> A#16[(app A#17[(var X#6)] C#18)], A#11 |-> A#16[(app A#17 C#18[(var X#6)])]} and instantiated rules: (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(app A#17[(var X#6)] C#18[(var X#6)])]) <-cpx-in1- (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(app A#17[(var X#6)] C#18[(var X#2)])]) ................................................................................ (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#16[(app A#17[(var X#6)] C#18[(var X#6)])]) -SR,lapp3-> (letrec {X#6=(var X#2);E#7;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))]} in A#16[(app A#17[(var X#6)] C#18[(var X#6)])]) ================================================================================ Critical Pair: ( (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)] in (var X#2) ) , (letrec X#6= (var X#2) ;E#7 ;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))] in (var X#6) ) ) where Delta1 = {} Delta2 = {E#8} Delta3 = {((var X#6),[.]), ((var X#2),[.]), (S#9,(letrec {E#8} in [.])), ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=(var X#2);EE#15[X#2,[.2]]}, X#1 |-> X#6, E#3 |-> {E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]}, C#5 |-> [.], A#13 |-> [.], X#14 |-> X#2, A#11 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in (var X#6)) <-cpx-in1- (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in (var X#2)) ................................................................................ (letrec {X#6=(var X#2);E#7;EE#15[X#2,(app (letrec {E#8} in S#10) S#9)]} in (var X#6)) -SR,lapp3-> (letrec {X#6=(var X#2);E#7;EE#15[X#2,(letrec {E#8} in (app S#10 S#9))]} in (var X#6)) ================================================================================ Critical Pair: ( (letrec X#14= (var X#2) ;E#7 ;EE#16[X#6,(var X#14)] ;EE#17[X#2,(app (letrec {E#8} in S#10) S#9)] in A#18[(app A#19[(var X#6)] C#20[(var X#2)])] ) , (letrec X#14= (var X#2) ;E#7 ;EE#16[X#6,(var X#14)] ;EE#17[X#2,(letrec {E#8} in (app S#10 S#9))] in A#18[(app A#19[(var X#6)] C#20[(var X#14)])] ) ) where Delta1 = {A#11,C#5} Delta2 = {E#8} Delta3 = {((var X#14),A#18[(app A#19[(var X#6)] C#20)]), ((var X#2),A#18[(app A#19[(var X#6)] C#20)]), (S#9,(letrec {E#8} in [.])), ((var X#14),A#18[(app A#19[(var X#6)] C#20[[.]])]), ((var X#6),A#18[(app A#19[[.]] C#20[(var X#14)])]), ((var X#6),A#18[(app A#19[[.]] C#20[(var X#14)])])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-in1-> with input rules: T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] <-cpx-in1- T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#2)])] and constraints: ((var X#1),C#5), ((var X#2),C#5) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=(var X#2);E#3} in C#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#8} Delta3= {((var X#1),C#5),((var X#2),C#5),(S#9,(letrec {E#8} in [.])),((var X#1),C#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {X#14=(var X#2);EE#16[[.1],(var X#14)];EE#17[X#2,[.2]]}, X#1 |-> X#14, E#3 |-> {E#7;EE#16[X#6,(var X#14)];EE#17[X#2,(app (letrec {E#8} in S#10) S#9)]}, A#13 |-> [.], X#15 |-> X#2, C#5 |-> A#18[(app A#19[(var X#6)] C#20)], A#11 |-> A#18[(app A#19 C#20[(var X#14)])]} and instantiated rules: (letrec {X#14=(var X#2);E#7;EE#16[X#6,(var X#14)];EE#17[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#18[(app A#19[(var X#6)] C#20[(var X#14)])]) <-cpx-in1- (letrec {X#14=(var X#2);E#7;EE#16[X#6,(var X#14)];EE#17[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#18[(app A#19[(var X#6)] C#20[(var X#2)])]) ................................................................................ (letrec {X#14=(var X#2);E#7;EE#16[X#6,(var X#14)];EE#17[X#2,(app (letrec {E#8} in S#10) S#9)]} in A#18[(app A#19[(var X#6)] C#20[(var X#14)])]) -SR,lapp3-> (letrec {X#14=(var X#2);E#7;EE#16[X#6,(var X#14)];EE#17[X#2,(letrec {E#8} in (app S#10 S#9))]} in A#18[(app A#19[(var X#6)] C#20[(var X#14)])]) ================================================================================ Critical Pair: ( A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] , A#12[(letrec X#8= T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#10 )] ) where Delta1 = {T#13,A#11,T#6,A#12} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#8.[.])), (T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#8=[.]} in S#10)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (\ X#8.S#10) S#9)] -SR,lbeta1-> A#11[(letrec {X#8=S#9} in S#10)] and constraints: (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (\ X#8.S#10) S#9)]} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(\ X#8.[.])),(S#9,(letrec {X#8=[.]} in S#10)),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (\ X#8.S#10) T#14)], T#13 |-> (app (\ X#8.S#10) T#14), S#9 |-> T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] <-cpx-e1- A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ................................................................................ A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] -SR,lbeta1-> A#12[(letrec {X#8=T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#10)] ================================================================================ Critical Pair: ( A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] , A#12[(app A#13[(letrec {X#8=S#9} in S#10)] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) where Delta1 = {A#11,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (\ X#8.S#10) S#9)] -SR,lbeta1-> A#11[(letrec {X#8=S#9} in S#10)] and constraints: (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (\ X#8.S#10) S#9)]} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(\ X#8.[.])),(S#9,(letrec {X#8=[.]} in S#10)),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14)], A#11 |-> A#12[(app A#13 T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] <-cpx-e1- A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ................................................................................ A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] -SR,lbeta1-> A#12[(app A#13[(letrec {X#8=S#9} in S#10)] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ================================================================================ Critical Pair: ( (app (\ X#8.S#10) T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) , (letrec X#8= T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#10 ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#8.[.])), (T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#8=[.]} in S#10)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (\ X#8.S#10) S#9)] -SR,lbeta1-> A#11[(letrec {X#8=S#9} in S#10)] and constraints: (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (\ X#8.S#10) S#9)]} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(\ X#8.[.])),(S#9,(letrec {X#8=[.]} in S#10)),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (\ X#8.S#10) T#12), S#9 |-> T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (app (\ X#8.S#10) T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) <-cpx-e1- (app (\ X#8.S#10) T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ................................................................................ (app (\ X#8.S#10) T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) -SR,lbeta1-> (letrec {X#8=T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#10) ================================================================================ Critical Pair: ( (letrec E#9 in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec E#9 in A#14[(letrec X#8= T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#11 )] ) ) where Delta1 = {T#15,A#12,T#13,T#6,A#14} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#8.[.])), (T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16)]), A#12 |-> A#14, T#13 |-> A#14[(app (\ X#8.S#11) T#16)], T#15 |-> (app (\ X#8.S#11) T#16), S#10 |-> T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,lbeta2-> (letrec {E#9} in A#14[(letrec {X#8=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#11)]) ================================================================================ Critical Pair: ( (letrec E#9 in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec E#9 in A#14[(app A#15[(letrec {X#8=S#10} in S#11)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16)]), T#13 |-> A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,lbeta2-> (letrec {E#9} in A#14[(app A#15[(letrec {X#8=S#10} in S#11)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec E#9 in (app (\ X#8.S#11) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ) , (letrec E#9 in (letrec X#8= T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#11 ) ) ) where Delta1 = {T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#8.[.])), (T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9} in (app (\ X#8.S#11) T#14)), A#12 |-> [.], T#13 |-> (app (\ X#8.S#11) T#14), S#10 |-> T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) <-cpx-e1- (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])) ................................................................................ (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) -SR,lbeta2-> (letrec {E#9} in (letrec {X#8=T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#11)) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#16 in A#12[(app (\ X#8.S#11) S#10)] ) , (letrec X#14= T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#16 in A#12[(letrec {X#8=S#10} in S#11)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;E#16} in A#12[(app (\ X#8.S#11) S#10)]), E#9 |-> {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(app (\ X#8.S#11) S#10)]) <-cpx-e1- (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(app (\ X#8.S#11) S#10)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(letrec {X#8=S#10} in S#11)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;E#14 in A#12[(app (\ X#8.S#11) S#10)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;E#14 in A#12[(letrec {X#8=S#10} in S#11)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(app (\ X#8.S#11) S#10)], E#9 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#14}, E#13 |-> {X#1=C#7[(var X#2)];E#14}, E#4 |-> {E#14}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in A#12[(app (\ X#8.S#11) S#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#14} in A#12[(app (\ X#8.S#11) S#10)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in A#12[(letrec {X#8=S#10} in S#11)]) ================================================================================ Critical Pair: ( (letrec E#10 ;EE#14[X#8,(app (\ X#9.S#12) S#11)] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec E#10 ;EE#14[X#8,(letrec {X#9=S#11} in S#12)] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18)]), T#15 |-> A#16[(app A#17[(var X#8)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#18 ;EE#14[X#8,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#18 ;EE#14[X#8,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]), E#10 |-> {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18}, E#17 |-> {E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#10 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec X#9= T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#12 )] ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#19} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#9.[.])), (T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (\ X#9.S#12) T#21)];E#10} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#10}, A#18 |-> A#19, T#15 |-> A#19[(app (\ X#9.S#12) T#21)], T#20 |-> (app (\ X#9.S#12) T#21), S#11 |-> T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=A#19[(letrec {X#9=T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#12)];E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#10 in A#13[(var X#8)] ) , (letrec X#8= A#19[(app A#20[(letrec {X#9=S#11} in S#12)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)];E#10} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]}, X#16 |-> X#8, E#17 |-> {E#10}, T#15 |-> A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=A#19[(app A#20[(letrec {X#9=S#11} in S#12)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (\ X#9.S#12) T#19[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ;E#10 in A#13[(var X#8)] ) , (letrec X#8= (letrec X#9= T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#12 ) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#9.[.])), (T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (\ X#9.S#12) T#19);E#10} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#10}, A#18 |-> [.], T#15 |-> (app (\ X#9.S#12) T#19), S#11 |-> T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=(app (\ X#9.S#12) T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=(app (\ X#9.S#12) T#19[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (\ X#9.S#12) T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=(letrec {X#9=T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#12);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#20[X#19,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#20[X#19,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23)];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#8, E#17 |-> {E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#19,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec X#9= T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#12 )] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#21} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#9.[.])), (T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (\ X#9.S#12) T#23)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#10;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (\ X#9.S#12) T#23)], T#22 |-> (app (\ X#9.S#12) T#23), S#11 |-> T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#19=A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(letrec {X#9=T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#12)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(app A#22[(letrec {X#9=S#11} in S#12)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#10;EE#20[X#8,(var X#19)]}, T#15 |-> A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(app A#22[(letrec {X#9=S#11} in S#12)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec X#9= T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] in S#12 ) ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(\ X#9.[.])), (T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (\ X#9.S#12) T#21);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#10;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (\ X#9.S#12) T#21), S#11 |-> T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#19=(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (\ X#9.S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=(letrec {X#9=T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} in S#12);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;E#16 ;EE#14[X#8,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;E#16 ;EE#14[X#8,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#16}, E#15 |-> {X#1=C#7[(var X#2)];E#16}, E#4 |-> {E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app (\ X#9.C#20[(var X#3)]) S#11)] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(letrec {X#9=S#11} in C#20[(var X#2)])] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#18,A#16,C#7,A#17} Delta2 = {} Delta3 = {((var X#2),A#17[(app (\ X#9.C#20) S#11)]), ((var X#3),A#17[(app (\ X#9.C#20) S#11)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#20[(var X#2)])), ((var X#2),A#17[(app (\ X#9.C#20[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> A#17, C#7 |-> A#17[(app (\ X#9.C#20) S#11)], C#18 |-> (app (\ X#9.C#20) S#11), C#19 |-> (\ X#9.C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app (\ X#9.C#20[(var X#2)]) S#11)];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app (\ X#9.C#20[(var X#3)]) S#11)];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app (\ X#9.C#20[(var X#2)]) S#11)];E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=(var X#3);X#8=A#17[(letrec {X#9=S#11} in C#20[(var X#2)])];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app (\ X#9.S#12) C#19[(var X#3)])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(letrec {X#9=C#19[(var X#2)]} in S#12)] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#18,A#16,C#7,A#17} Delta2 = {} Delta3 = {((var X#2),A#17[(app (\ X#9.S#12) C#19)]), ((var X#3),A#17[(app (\ X#9.S#12) C#19)]), (C#19[(var X#2)],(\ X#9.[.])), (C#19[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),A#17[(app (\ X#9.S#12) C#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> A#17, C#7 |-> A#17[(app (\ X#9.S#12) C#19)], C#18 |-> (app (\ X#9.S#12) C#19), S#11 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app (\ X#9.S#12) C#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app (\ X#9.S#12) C#19[(var X#3)])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app (\ X#9.S#12) C#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=(var X#3);X#8=A#17[(letrec {X#9=C#19[(var X#2)]} in S#12)];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19[(var X#3)])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(app A#18[(letrec {X#9=S#11} in S#12)] C#19[(var X#2)])] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {} Delta3 = {((var X#2),A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19)]), ((var X#3),A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] C#19[(var X#2)])]}, X#1 |-> X#8, E#4 |-> {E#15}, C#7 |-> A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19)], A#16 |-> A#17[(app A#18 C#19[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19[(var X#3)])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] C#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(letrec {X#9=S#11} in S#12)] C#19[(var X#2)])];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (app (\ X#9.C#18[(var X#3)]) S#11) ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= (letrec {X#9=S#11} in C#18[(var X#2)]) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#17,C#7} Delta2 = {} Delta3 = {((var X#2),(app (\ X#9.C#18) S#11)), ((var X#3),(app (\ X#9.C#18) S#11)), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#18[(var X#2)])), ((var X#2),(app (\ X#9.C#18[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> [.], C#7 |-> (app (\ X#9.C#18) S#11), C#17 |-> (\ X#9.C#18), S#12 |-> C#18[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(app (\ X#9.C#18[(var X#2)]) S#11);E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(app (\ X#9.C#18[(var X#3)]) S#11);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(app (\ X#9.C#18[(var X#2)]) S#11);E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=(var X#3);X#8=(letrec {X#9=S#11} in C#18[(var X#2)]);E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (app (\ X#9.S#12) C#17[(var X#3)]) ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= (letrec {X#9=C#17[(var X#2)]} in S#12) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#2),(app (\ X#9.S#12) C#17)), ((var X#3),(app (\ X#9.S#12) C#17)), (C#17[(var X#2)],(\ X#9.[.])), (C#17[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),(app (\ X#9.S#12) C#17[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> [.], C#7 |-> (app (\ X#9.S#12) C#17), S#11 |-> C#17[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(app (\ X#9.S#12) C#17[(var X#2)]);E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(app (\ X#9.S#12) C#17[(var X#3)]);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(app (\ X#9.S#12) C#17[(var X#2)]);E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=(var X#3);X#8=(letrec {X#9=C#17[(var X#2)]} in S#12);E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#19[(app A#20[(var X#17)] C#21[(var X#3)])] ;E#15 ;EE#18[X#17,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#19[(app A#20[(var X#17)] C#21[(var X#2)])] ;E#15 ;EE#18[X#17,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {} Delta3 = {((var X#2),A#19[(app A#20[(var X#17)] C#21)]), ((var X#3),A#19[(app A#20[(var X#17)] C#21)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#19[(app A#20[(var X#17)] C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];EE#18[X#17,[.2]]}, X#1 |-> X#8, E#4 |-> {E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#19[(app A#20[(var X#17)] C#21)], A#16 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#3)])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] C#23[(var X#3)])] ;X#2= (var X#3) ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] C#23[(var X#2)])] ;X#2= (var X#3) ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {} Delta3 = {((var X#2),A#21[(app A#22[(var X#18)] C#23)]), ((var X#3),A#21[(app A#22[(var X#18)] C#23)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#21[(app A#22[(var X#18)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, E#4 |-> {E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#21[(app A#22[(var X#18)] C#23)], A#16 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#3)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (\ X#9.C#22[(var X#3)]) S#11)] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {X#9=S#11} in C#22[(var X#2)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#20,A#16,C#7,A#19} Delta2 = {} Delta3 = {((var X#2),A#19[(app (\ X#9.C#22) S#11)]), ((var X#3),A#19[(app (\ X#9.C#22) S#11)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#22[(var X#2)])), ((var X#2),A#19[(app (\ X#9.C#22[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, C#7 |-> A#19[(app (\ X#9.C#22) S#11)], C#20 |-> (app (\ X#9.C#22) S#11), C#21 |-> (\ X#9.C#22), S#12 |-> C#22[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (\ X#9.C#22[(var X#2)]) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app (\ X#9.C#22[(var X#3)]) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (\ X#9.C#22[(var X#2)]) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#19[(letrec {X#9=S#11} in C#22[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (\ X#9.S#12) C#21[(var X#3)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {X#9=C#21[(var X#2)]} in S#12)] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#20,A#16,C#7,A#19} Delta2 = {} Delta3 = {((var X#2),A#19[(app (\ X#9.S#12) C#21)]), ((var X#3),A#19[(app (\ X#9.S#12) C#21)]), (C#21[(var X#2)],(\ X#9.[.])), (C#21[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),A#19[(app (\ X#9.S#12) C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, C#7 |-> A#19[(app (\ X#9.S#12) C#21)], C#20 |-> (app (\ X#9.S#12) C#21), S#11 |-> C#21[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (\ X#9.S#12) C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app (\ X#9.S#12) C#21[(var X#3)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (\ X#9.S#12) C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#19[(letrec {X#9=C#21[(var X#2)]} in S#12)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#3)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(app A#20[(letrec {X#9=S#11} in S#12)] C#21[(var X#2)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {} Delta3 = {((var X#2),A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21)]), ((var X#3),A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] C#21[(var X#2)])];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, C#7 |-> A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21)], A#16 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#3)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#19[(app A#20[(letrec {X#9=S#11} in S#12)] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (\ X#9.C#20[(var X#3)]) S#11) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {X#9=S#11} in C#20[(var X#2)]) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#7} Delta2 = {} Delta3 = {((var X#2),(app (\ X#9.C#20) S#11)), ((var X#3),(app (\ X#9.C#20) S#11)), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#20[(var X#2)])), ((var X#2),(app (\ X#9.C#20[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], C#7 |-> (app (\ X#9.C#20) S#11), C#19 |-> (\ X#9.C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#17=(app (\ X#9.C#20[(var X#2)]) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=(app (\ X#9.C#20[(var X#3)]) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (\ X#9.C#20[(var X#2)]) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=(letrec {X#9=S#11} in C#20[(var X#2)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (\ X#9.S#12) C#19[(var X#3)]) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {X#9=C#19[(var X#2)]} in S#12) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#2),(app (\ X#9.S#12) C#19)), ((var X#3),(app (\ X#9.S#12) C#19)), (C#19[(var X#2)],(\ X#9.[.])), (C#19[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),(app (\ X#9.S#12) C#19[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], C#7 |-> (app (\ X#9.S#12) C#19), S#11 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#17=(app (\ X#9.S#12) C#19[(var X#2)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=(app (\ X#9.S#12) C#19[(var X#3)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (\ X#9.S#12) C#19[(var X#2)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=(letrec {X#9=C#19[(var X#2)]} in S#12);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#8= (var X#3) ;E#18 ;EE#17[X#3,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= C#7[(var X#8)] ;X#8= (var X#3) ;E#18 ;EE#17[X#3,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#8),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#8),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {[.1]=(var X#3);EE#17[X#3,[.2]]}, X#2 |-> X#8, E#10 |-> {X#1=C#7[(var X#8)];E#18}, E#4 |-> {E#18;EE#17[X#3,(app (\ X#9.S#12) S#11)]}, A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#8)];X#8=(var X#3);E#18;EE#17[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#8=(var X#3);E#18;EE#17[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#8)];X#8=(var X#3);E#18;EE#17[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#1=C#7[(var X#8)];X#8=(var X#3);E#18;EE#17[X#3,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app (\ X#9.C#22[(var X#3)]) S#11)] ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) , (letrec X#3= A#19[(letrec {X#9=S#11} in C#22[(var X#8)])] ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#20,A#18,C#7,A#19} Delta2 = {} Delta3 = {((var X#8),A#19[(app (\ X#9.C#22) S#11)]), ((var X#3),A#19[(app (\ X#9.C#22) S#11)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#22[(var X#8)])), ((var X#8),A#19[(app (\ X#9.C#22[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[[.2]];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#3, E#4 |-> {E#10}, A#18 |-> A#19, C#7 |-> A#19[(app (\ X#9.C#22) S#11)], A#15 |-> [.], X#16 |-> X#3, C#20 |-> (app (\ X#9.C#22) S#11), C#21 |-> (\ X#9.C#22), S#12 |-> C#22[(var X#8)]} and instantiated rules: (letrec {X#3=A#19[(app (\ X#9.C#22[(var X#8)]) S#11)];X#8=(var X#3);E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app (\ X#9.C#22[(var X#3)]) S#11)];X#8=(var X#3);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app (\ X#9.C#22[(var X#8)]) S#11)];X#8=(var X#3);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#3=A#19[(letrec {X#9=S#11} in C#22[(var X#8)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app (\ X#9.S#12) C#21[(var X#3)])] ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) , (letrec X#3= A#19[(letrec {X#9=C#21[(var X#8)]} in S#12)] ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {C#20,A#18,C#7,A#19} Delta2 = {} Delta3 = {((var X#8),A#19[(app (\ X#9.S#12) C#21)]), ((var X#3),A#19[(app (\ X#9.S#12) C#21)]), (C#21[(var X#8)],(\ X#9.[.])), (C#21[(var X#8)],(letrec {X#9=[.]} in S#12)), ((var X#8),A#19[(app (\ X#9.S#12) C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[[.2]];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#3, E#4 |-> {E#10}, A#18 |-> A#19, C#7 |-> A#19[(app (\ X#9.S#12) C#21)], A#15 |-> [.], X#16 |-> X#3, C#20 |-> (app (\ X#9.S#12) C#21), S#11 |-> C#21[(var X#8)]} and instantiated rules: (letrec {X#3=A#19[(app (\ X#9.S#12) C#21[(var X#8)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app (\ X#9.S#12) C#21[(var X#3)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app (\ X#9.S#12) C#21[(var X#8)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#3=A#19[(letrec {X#9=C#21[(var X#8)]} in S#12)];X#8=(var X#3);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#3)])] ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) , (letrec X#3= A#19[(app A#20[(letrec {X#9=S#11} in S#12)] C#21[(var X#8)])] ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {} Delta3 = {((var X#8),A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21)]), ((var X#3),A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#8),A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[(app A#20[[.2]] C#21[(var X#8)])];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] C#21[(var X#8)])]}, X#1 |-> X#3, E#4 |-> {E#10}, C#7 |-> A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21)], A#18 |-> A#19[(app A#20 C#21[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#8)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#3)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app A#20[(app (\ X#9.S#12) S#11)] C#21[(var X#8)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#3=A#19[(app A#20[(letrec {X#9=S#11} in S#12)] C#21[(var X#8)])];X#8=(var X#3);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= (app (\ X#9.C#20[(var X#3)]) S#11) ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) , (letrec X#3= (letrec {X#9=S#11} in C#20[(var X#8)]) ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#7} Delta2 = {} Delta3 = {((var X#8),(app (\ X#9.C#20) S#11)), ((var X#3),(app (\ X#9.C#20) S#11)), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#20[(var X#8)])), ((var X#8),(app (\ X#9.C#20[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#10}, A#18 |-> [.], C#7 |-> (app (\ X#9.C#20) S#11), C#19 |-> (\ X#9.C#20), S#12 |-> C#20[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=(app (\ X#9.C#20[(var X#8)]) S#11);X#8=(var X#3);E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=(app (\ X#9.C#20[(var X#3)]) S#11);X#8=(var X#3);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=(app (\ X#9.C#20[(var X#8)]) S#11);X#8=(var X#3);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#3=(letrec {X#9=S#11} in C#20[(var X#8)]);X#8=(var X#3);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= (app (\ X#9.S#12) C#19[(var X#3)]) ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) , (letrec X#3= (letrec {X#9=C#19[(var X#8)]} in S#12) ;X#8= (var X#3) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#8),(app (\ X#9.S#12) C#19)), ((var X#3),(app (\ X#9.S#12) C#19)), (C#19[(var X#8)],(\ X#9.[.])), (C#19[(var X#8)],(letrec {X#9=[.]} in S#12)), ((var X#8),(app (\ X#9.S#12) C#19[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#10}, A#18 |-> [.], C#7 |-> (app (\ X#9.S#12) C#19), S#11 |-> C#19[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=(app (\ X#9.S#12) C#19[(var X#8)]);X#8=(var X#3);E#10} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=(app (\ X#9.S#12) C#19[(var X#3)]);X#8=(var X#3);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=(app (\ X#9.S#12) C#19[(var X#8)]);X#8=(var X#3);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#3=(letrec {X#9=C#19[(var X#8)]} in S#12);X#8=(var X#3);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#21[(app A#22[(var X#19)] C#23[(var X#3)])] ;X#8= (var X#3) ;E#10 ;EE#20[X#19,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#3= A#21[(app A#22[(var X#19)] C#23[(var X#8)])] ;X#8= (var X#3) ;E#10 ;EE#20[X#19,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {} Delta3 = {((var X#8),A#21[(app A#22[(var X#19)] C#23)]), ((var X#3),A#21[(app A#22[(var X#19)] C#23)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#8),A#21[(app A#22[(var X#19)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];[.1]=(var X#3);EE#20[X#19,[.2]]}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];EE#20[X#19,[.2]]}, X#1 |-> X#3, E#4 |-> {E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#21[(app A#22[(var X#19)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#3)])];X#8=(var X#3);E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#19,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#3)])] ;X#8= (var X#3) ;E#10 ;EE#21[X#3,(var X#19)] ;EE#22[X#20,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#8)])] ;X#8= (var X#3) ;E#10 ;EE#21[X#3,(var X#19)] ;EE#22[X#20,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {} Delta3 = {((var X#8),A#23[(app A#24[(var X#20)] C#25)]), ((var X#3),A#23[(app A#24[(var X#20)] C#25)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#8),A#23[(app A#24[(var X#20)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];[.1]=(var X#3);EE#21[X#3,(var X#19)];EE#22[X#20,[.2]]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#1 |-> X#19, E#4 |-> {E#10;EE#21[X#3,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#23[(app A#24[(var X#20)] C#25)], A#18 |-> A#23[(app A#24 C#25[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];X#8=(var X#3);E#10;EE#21[X#3,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#3)])];X#8=(var X#3);E#10;EE#21[X#3,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];X#8=(var X#3);E#10;EE#21[X#3,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];X#8=(var X#3);E#10;EE#21[X#3,(var X#19)];EE#22[X#20,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (\ X#9.C#24[(var X#3)]) S#11)] ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {X#9=S#11} in C#24[(var X#8)])] ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#22,A#18,C#7,A#21} Delta2 = {} Delta3 = {((var X#8),A#21[(app (\ X#9.C#24) S#11)]), ((var X#3),A#21[(app (\ X#9.C#24) S#11)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#24[(var X#8)])), ((var X#8),A#21[(app (\ X#9.C#24[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[[.2]];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#10;EE#20[X#3,(var X#19)]}, A#18 |-> A#21, C#7 |-> A#21[(app (\ X#9.C#24) S#11)], A#15 |-> [.], X#16 |-> X#3, C#22 |-> (app (\ X#9.C#24) S#11), C#23 |-> (\ X#9.C#24), S#12 |-> C#24[(var X#8)]} and instantiated rules: (letrec {X#19=A#21[(app (\ X#9.C#24[(var X#8)]) S#11)];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (\ X#9.C#24[(var X#3)]) S#11)];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (\ X#9.C#24[(var X#8)]) S#11)];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(letrec {X#9=S#11} in C#24[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (\ X#9.S#12) C#23[(var X#3)])] ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {X#9=C#23[(var X#8)]} in S#12)] ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#22,A#18,C#7,A#21} Delta2 = {} Delta3 = {((var X#8),A#21[(app (\ X#9.S#12) C#23)]), ((var X#3),A#21[(app (\ X#9.S#12) C#23)]), (C#23[(var X#8)],(\ X#9.[.])), (C#23[(var X#8)],(letrec {X#9=[.]} in S#12)), ((var X#8),A#21[(app (\ X#9.S#12) C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[[.2]];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#10;EE#20[X#3,(var X#19)]}, A#18 |-> A#21, C#7 |-> A#21[(app (\ X#9.S#12) C#23)], A#15 |-> [.], X#16 |-> X#3, C#22 |-> (app (\ X#9.S#12) C#23), S#11 |-> C#23[(var X#8)]} and instantiated rules: (letrec {X#19=A#21[(app (\ X#9.S#12) C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (\ X#9.S#12) C#23[(var X#3)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (\ X#9.S#12) C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(letrec {X#9=C#23[(var X#8)]} in S#12)];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#3)])] ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(app A#22[(letrec {X#9=S#11} in S#12)] C#23[(var X#8)])] ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {} Delta3 = {((var X#8),A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23)]), ((var X#3),A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#8),A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#8)])];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#8)])];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#10;EE#20[X#3,(var X#19)]}, C#7 |-> A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#3)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(app A#22[(letrec {X#9=S#11} in S#12)] C#23[(var X#8)])];X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (\ X#9.C#22[(var X#3)]) S#11) ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {X#9=S#11} in C#22[(var X#8)]) ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#7} Delta2 = {} Delta3 = {((var X#8),(app (\ X#9.C#22) S#11)), ((var X#3),(app (\ X#9.C#22) S#11)), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#22[(var X#8)])), ((var X#8),(app (\ X#9.C#22[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=[.2];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#10;EE#20[X#3,(var X#19)]}, A#18 |-> [.], C#7 |-> (app (\ X#9.C#22) S#11), C#21 |-> (\ X#9.C#22), S#12 |-> C#22[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=(app (\ X#9.C#22[(var X#8)]) S#11);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (\ X#9.C#22[(var X#3)]) S#11);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (\ X#9.C#22[(var X#8)]) S#11);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=(letrec {X#9=S#11} in C#22[(var X#8)]);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (\ X#9.S#12) C#21[(var X#3)]) ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {X#9=C#21[(var X#8)]} in S#12) ;X#8= (var X#3) ;E#10 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#8),(app (\ X#9.S#12) C#21)), ((var X#3),(app (\ X#9.S#12) C#21)), (C#21[(var X#8)],(\ X#9.[.])), (C#21[(var X#8)],(letrec {X#9=[.]} in S#12)), ((var X#8),(app (\ X#9.S#12) C#21[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=[.2];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#10;EE#20[X#3,(var X#19)]}, A#18 |-> [.], C#7 |-> (app (\ X#9.S#12) C#21), S#11 |-> C#21[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=(app (\ X#9.S#12) C#21[(var X#8)]);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (\ X#9.S#12) C#21[(var X#3)]);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (\ X#9.S#12) C#21[(var X#8)]);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=(letrec {X#9=C#21[(var X#8)]} in S#12);X#8=(var X#3);E#10;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#16= (var X#3) ;E#20 ;EE#18[X#8,(var X#16)] ;EE#19[X#3,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= C#7[(var X#16)] ;X#16= (var X#3) ;E#20 ;EE#18[X#8,(var X#16)] ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),C#7), ((var X#3),C#7), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);EE#18[[.1],(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, E#10 |-> {X#1=C#7[(var X#16)];E#20}, E#4 |-> {E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (\ X#9.S#12) S#11)]}, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#21[(var X#3)] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#21[(var X#16)] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21[[.]]), ((var X#3),A#21[[.]]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]}, A#20 |-> A#21, C#7 |-> A#21[[.]], A#15 |-> [.], X#17 |-> X#3, C#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#21[(var X#3)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#21[(var X#3)] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#21[(var X#16)] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21), ((var X#3),A#21), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]}, A#20 |-> A#21[[.]], C#7 |-> A#21, A#15 |-> [.], X#17 |-> X#3, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#21[(var X#3)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#21[(app A#22[(var X#16)] C#23[(var X#3)])] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#21[(app A#22[(var X#16)] C#23[(var X#16)])] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#21[(app A#22[(var X#16)] C#23)]), ((var X#3),A#21[(app A#22[(var X#16)] C#23)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[(app A#22[(var X#16)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#16)])]}, X#1 |-> X#8, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#21[(app A#22[(var X#16)] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#3)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (var X#3) ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= (var X#16) ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#3),[.]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=(var X#16);EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]}, C#7 |-> [.], A#20 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(var X#16);E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(var X#3);E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(var X#16);E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#8=(var X#16);E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#23[(app A#24[(var X#21)] C#25[(var X#3)])] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] ;EE#22[X#21,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#23[(app A#24[(var X#21)] C#25[(var X#16)])] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] ;EE#22[X#21,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#23[(app A#24[(var X#21)] C#25)]), ((var X#3),A#23[(app A#24[(var X#21)] C#25)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#19[X#3,[.2]];EE#22[X#21,(var X#16)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#22[X#21,[.2]]}, X#1 |-> X#8, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#21,(var X#16)]}, C#7 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#3)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#3)])] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] ;EE#23[X#8,(var X#21)] ;EE#24[X#22,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#16)])] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] ;EE#23[X#8,(var X#21)] ;EE#24[X#22,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#25[(app A#26[(var X#22)] C#27)]), ((var X#3),A#25[(app A#26[(var X#22)] C#27)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#19[X#3,[.2]];EE#23[[.1],(var X#21)];EE#24[X#22,(var X#16)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]}, C#7 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#3)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(var X#3)] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(var X#16)] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#23} Delta2 = {} Delta3 = {((var X#16),A#23[[.]]), ((var X#3),A#23[[.]]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(var X#16)];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[[.]], A#15 |-> [.], X#17 |-> X#3, C#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(var X#3)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(var X#3)] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(var X#16)] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#23} Delta2 = {} Delta3 = {((var X#16),A#23), ((var X#3),A#23), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(var X#16)];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23[[.]], C#7 |-> A#23, A#15 |-> [.], X#17 |-> X#3, A#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(var X#3)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#16)] C#25[(var X#3)])] ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#16)] C#25[(var X#16)])] ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#23[(app A#24[(var X#16)] C#25)]), ((var X#3),A#23[(app A#24[(var X#16)] C#25)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[(app A#24[(var X#16)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, C#7 |-> A#23[(app A#24[(var X#16)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#3)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (var X#3) ;E#10 ;EE#19[X#3,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (var X#16) ;E#10 ;EE#19[X#3,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#3),[.]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=(var X#16);EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, C#7 |-> [.], A#20 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(var X#16);E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(var X#3);E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(var X#16);E#10;EE#19[X#3,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=(var X#16);E#10;EE#19[X#3,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app (\ X#9.C#24[(var X#3)]) S#11)] ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(letrec {X#9=S#11} in C#24[(var X#16)])] ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#22,A#20,C#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21[(app (\ X#9.C#24) S#11)]), ((var X#3),A#21[(app (\ X#9.C#24) S#11)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#24[(var X#16)])), ((var X#16),A#21[(app (\ X#9.C#24[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[[.2]];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#3, E#4 |-> {E#10;EE#18[X#8,(var X#16)]}, A#20 |-> A#21, C#7 |-> A#21[(app (\ X#9.C#24) S#11)], A#15 |-> [.], X#17 |-> X#3, C#22 |-> (app (\ X#9.C#24) S#11), C#23 |-> (\ X#9.C#24), S#12 |-> C#24[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app (\ X#9.C#24[(var X#16)]) S#11)];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app (\ X#9.C#24[(var X#3)]) S#11)];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app (\ X#9.C#24[(var X#16)]) S#11)];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#3=A#21[(letrec {X#9=S#11} in C#24[(var X#16)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app (\ X#9.S#12) C#23[(var X#3)])] ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(letrec {X#9=C#23[(var X#16)]} in S#12)] ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#22,A#20,C#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21[(app (\ X#9.S#12) C#23)]), ((var X#3),A#21[(app (\ X#9.S#12) C#23)]), (C#23[(var X#16)],(\ X#9.[.])), (C#23[(var X#16)],(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[(app (\ X#9.S#12) C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[[.2]];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#3, E#4 |-> {E#10;EE#18[X#8,(var X#16)]}, A#20 |-> A#21, C#7 |-> A#21[(app (\ X#9.S#12) C#23)], A#15 |-> [.], X#17 |-> X#3, C#22 |-> (app (\ X#9.S#12) C#23), S#11 |-> C#23[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app (\ X#9.S#12) C#23[(var X#16)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app (\ X#9.S#12) C#23[(var X#3)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app (\ X#9.S#12) C#23[(var X#16)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#3=A#21[(letrec {X#9=C#23[(var X#16)]} in S#12)];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#3)])] ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(app A#22[(letrec {X#9=S#11} in S#12)] C#23[(var X#16)])] ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23)]), ((var X#3),A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[(app A#22[[.2]] C#23[(var X#16)])];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#16)])]}, X#1 |-> X#3, E#4 |-> {E#10;EE#18[X#8,(var X#16)]}, C#7 |-> A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#16)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#3)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(app (\ X#9.S#12) S#11)] C#23[(var X#16)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(letrec {X#9=S#11} in S#12)] C#23[(var X#16)])];E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (app (\ X#9.C#22[(var X#3)]) S#11) ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= (letrec {X#9=S#11} in C#22[(var X#16)]) ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#7} Delta2 = {} Delta3 = {((var X#16),(app (\ X#9.C#22) S#11)), ((var X#3),(app (\ X#9.C#22) S#11)), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#22[(var X#16)])), ((var X#16),(app (\ X#9.C#22[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=[.2];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#10;EE#18[X#8,(var X#16)]}, A#20 |-> [.], C#7 |-> (app (\ X#9.C#22) S#11), C#21 |-> (\ X#9.C#22), S#12 |-> C#22[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(app (\ X#9.C#22[(var X#16)]) S#11);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(app (\ X#9.C#22[(var X#3)]) S#11);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(app (\ X#9.C#22[(var X#16)]) S#11);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#3=(letrec {X#9=S#11} in C#22[(var X#16)]);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (app (\ X#9.S#12) C#21[(var X#3)]) ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= (letrec {X#9=C#21[(var X#16)]} in S#12) ;E#10 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#16),(app (\ X#9.S#12) C#21)), ((var X#3),(app (\ X#9.S#12) C#21)), (C#21[(var X#16)],(\ X#9.[.])), (C#21[(var X#16)],(letrec {X#9=[.]} in S#12)), ((var X#16),(app (\ X#9.S#12) C#21[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=[.2];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#10;EE#18[X#8,(var X#16)]}, A#20 |-> [.], C#7 |-> (app (\ X#9.S#12) C#21), S#11 |-> C#21[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(app (\ X#9.S#12) C#21[(var X#16)]);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(app (\ X#9.S#12) C#21[(var X#3)]);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(app (\ X#9.S#12) C#21[(var X#16)]);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#3=(letrec {X#9=C#21[(var X#16)]} in S#12);E#10;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#23[(app A#24[(var X#21)] C#25[(var X#3)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#21,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#23[(app A#24[(var X#21)] C#25[(var X#16)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#21,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#23[(app A#24[(var X#21)] C#25)]), ((var X#3),A#23[(app A#24[(var X#21)] C#25)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#18[[.1],(var X#16)];EE#22[X#21,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#22[X#21,[.2]]}, X#1 |-> X#3, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#22[X#21,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#21,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#3)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#21,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#21,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#21,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#3)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#23[X#3,(var X#21)] ;EE#24[X#22,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#16)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#23[X#3,(var X#21)] ;EE#24[X#22,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#25[(app A#26[(var X#22)] C#27)]), ((var X#3),A#25[(app A#26[(var X#22)] C#27)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#18[[.1],(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (\ X#9.S#12) S#11)]}, C#7 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#3)])];E#10;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app (\ X#9.C#26[(var X#3)]) S#11)] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(letrec {X#9=S#11} in C#26[(var X#16)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#25,C#24,A#20,C#7,A#23} Delta2 = {} Delta3 = {((var X#16),A#23[(app (\ X#9.C#26) S#11)]), ((var X#3),A#23[(app (\ X#9.C#26) S#11)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#26[(var X#16)])), ((var X#16),A#23[(app (\ X#9.C#26[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[[.2]];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[(app (\ X#9.C#26) S#11)], A#15 |-> [.], X#17 |-> X#3, C#24 |-> (app (\ X#9.C#26) S#11), C#25 |-> (\ X#9.C#26), S#12 |-> C#26[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app (\ X#9.C#26[(var X#16)]) S#11)];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app (\ X#9.C#26[(var X#3)]) S#11)];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app (\ X#9.C#26[(var X#16)]) S#11)];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#23[(letrec {X#9=S#11} in C#26[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app (\ X#9.S#12) C#25[(var X#3)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(letrec {X#9=C#25[(var X#16)]} in S#12)] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#24,A#20,C#7,A#23} Delta2 = {} Delta3 = {((var X#16),A#23[(app (\ X#9.S#12) C#25)]), ((var X#3),A#23[(app (\ X#9.S#12) C#25)]), (C#25[(var X#16)],(\ X#9.[.])), (C#25[(var X#16)],(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[(app (\ X#9.S#12) C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[[.2]];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[(app (\ X#9.S#12) C#25)], A#15 |-> [.], X#17 |-> X#3, C#24 |-> (app (\ X#9.S#12) C#25), S#11 |-> C#25[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app (\ X#9.S#12) C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app (\ X#9.S#12) C#25[(var X#3)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app (\ X#9.S#12) C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#23[(letrec {X#9=C#25[(var X#16)]} in S#12)];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25[(var X#3)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(letrec {X#9=S#11} in S#12)] C#25[(var X#16)])] ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {} Delta3 = {((var X#16),A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25)]), ((var X#3),A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25)]), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, C#7 |-> A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25[(var X#3)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(app (\ X#9.S#12) S#11)] C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(letrec {X#9=S#11} in S#12)] C#25[(var X#16)])];E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (app (\ X#9.C#24[(var X#3)]) S#11) ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (letrec {X#9=S#11} in C#24[(var X#16)]) ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#7} Delta2 = {} Delta3 = {((var X#16),(app (\ X#9.C#24) S#11)), ((var X#3),(app (\ X#9.C#24) S#11)), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in C#24[(var X#16)])), ((var X#16),(app (\ X#9.C#24[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=[.2];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> [.], C#7 |-> (app (\ X#9.C#24) S#11), C#23 |-> (\ X#9.C#24), S#12 |-> C#24[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(app (\ X#9.C#24[(var X#16)]) S#11);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(app (\ X#9.C#24[(var X#3)]) S#11);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(app (\ X#9.C#24[(var X#16)]) S#11);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=(letrec {X#9=S#11} in C#24[(var X#16)]);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (app (\ X#9.S#12) C#23[(var X#3)]) ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (letrec {X#9=C#23[(var X#16)]} in S#12) ;E#10 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#16),(app (\ X#9.S#12) C#23)), ((var X#3),(app (\ X#9.S#12) C#23)), (C#23[(var X#16)],(\ X#9.[.])), (C#23[(var X#16)],(letrec {X#9=[.]} in S#12)), ((var X#16),(app (\ X#9.S#12) C#23[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=[.2];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> [.], C#7 |-> (app (\ X#9.S#12) C#23), S#11 |-> C#23[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(app (\ X#9.S#12) C#23[(var X#16)]);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(app (\ X#9.S#12) C#23[(var X#3)]);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(app (\ X#9.S#12) C#23[(var X#16)]);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=(var X#3);X#21=(letrec {X#9=C#23[(var X#16)]} in S#12);E#10;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#11) ;E#10 in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec X#8= (\ X#9.S#11) ;E#10 in A#14[(app A#15[(\ X#9.S#11)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16)]), T#13 |-> A#14[(app A#15[(var X#8)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(\ X#9.S#11)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#11) ;E#16 in A#12[(var X#8)] ) , (letrec X#14= T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#11) ;E#16 in A#12[(\ X#9.S#11)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]), E#10 |-> {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16}, E#15 |-> {X#8=(\ X#9.S#11);E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(\ X#9.S#11)]) ================================================================================ Critical Pair: ( (letrec {X#2=(var X#3);X#8=(\ X#9.C#14[(var X#3)]);E#13} in A#12[(var X#8)]) , (letrec X#2= (var X#3) ;X#8= (\ X#9.C#14[(var X#2)]) ;E#13 in A#12[(\ X#9.C#14[(var X#2)])] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#2),(\ X#9.C#14)), ((var X#3),(\ X#9.C#14)), ((var X#2),(\ X#9.C#14[[.]])), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#3);E#13}, X#1 |-> X#8, E#4 |-> {E#13}, C#7 |-> (\ X#9.C#14), S#11 |-> C#14[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(\ X#9.C#14[(var X#2)]);E#13} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(\ X#9.C#14[(var X#3)]);E#13} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(\ X#9.C#14[(var X#2)]);E#13} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#2=(var X#3);X#8=(\ X#9.C#14[(var X#2)]);E#13} in A#12[(\ X#9.C#14[(var X#2)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;X#8= (\ X#9.S#11) ;E#14 in A#12[(var X#8)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= (\ X#9.S#11) ;E#14 in A#12[(\ X#9.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#14}, E#13 |-> {X#1=C#7[(var X#2)];E#14}, E#4 |-> {X#8=(\ X#9.S#11);E#14}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#11);E#14} in A#12[(\ X#9.S#11)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#12) ;E#11 ;VV#14|X#10,(var X#8)| in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec X#8= (\ X#9.S#12) ;E#11 ;VV#14|X#10,(var X#8)| in A#16[(app A#17[(\ X#9.S#12)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18)]), T#15 |-> A#16[(app A#17[(var X#10)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(\ X#9.S#12)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#12) ;E#18 ;VV#14|X#10,(var X#8)| in A#13[(var X#10)] ) , (letrec X#16= T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#12) ;E#18 ;VV#14|X#10,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]), E#11 |-> {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18}, E#17 |-> {X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (\ X#9.C#16[(var X#3)]) ;E#15 ;VV#14|X#10,(var X#8)| in A#13[(var X#10)] ) , (letrec X#2= (var X#3) ;X#8= (\ X#9.C#16[(var X#2)]) ;E#15 ;VV#14|X#10,(var X#8)| in A#13[(\ X#9.C#16[(var X#2)])] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#2),(\ X#9.C#16)), ((var X#3),(\ X#9.C#16)), ((var X#2),(\ X#9.C#16[[.]])), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], E#11 |-> {X#2=(var X#3);E#15}, X#1 |-> X#8, E#4 |-> {E#15;VV#14|X#10,(var X#8)|}, C#7 |-> (\ X#9.C#16), S#12 |-> C#16[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(\ X#9.C#16[(var X#2)]);E#15;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(\ X#9.C#16[(var X#3)]);E#15;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(\ X#9.C#16[(var X#2)]);E#15;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#2=(var X#3);X#8=(\ X#9.C#16[(var X#2)]);E#15;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.C#16[(var X#2)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;VV#14|X#10,(var X#8)| in A#13[(var X#10)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;VV#14|X#10,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], E#11 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#16}, E#15 |-> {X#1=C#7[(var X#2)];E#16}, E#4 |-> {X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec {X#10=(var X#8);X#8=(\ X#9.C#16[(var X#8)]);E#11} in A#13[(var X#10)]) , (letrec X#10= (var X#8) ;X#8= (\ X#9.C#16[(var X#10)]) ;E#11 in A#13[(\ X#9.C#16[(var X#10)])] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#10),(\ X#9.C#16)), ((var X#8),(\ X#9.C#16)), ((var X#10),(\ X#9.C#16[[.]])), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#10, X#3 |-> X#8, X#1 |-> X#8, E#4 |-> {E#11}, C#7 |-> (\ X#9.C#16), S#12 |-> C#16[(var X#10)]} and instantiated rules: (letrec {X#10=(var X#8);X#8=(\ X#9.C#16[(var X#10)]);E#11} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#8);X#8=(\ X#9.C#16[(var X#8)]);E#11} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#8);X#8=(\ X#9.C#16[(var X#10)]);E#11} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#8);X#8=(\ X#9.C#16[(var X#10)]);E#11} in A#13[(\ X#9.C#16[(var X#10)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#8)] ;X#10= (var X#8) ;X#8= (\ X#9.S#12) ;E#16 in A#13[(var X#10)] ) , (letrec X#1= C#7[(var X#10)] ;X#10= (var X#8) ;X#8= (\ X#9.S#12) ;E#16 in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#10),C#7), ((var X#8),C#7), ((var X#10),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#10, X#3 |-> X#8, E#11 |-> {X#1=C#7[(var X#10)];E#16}, E#4 |-> {X#8=(\ X#9.S#12);E#16}} and instantiated rules: (letrec {X#1=C#7[(var X#10)];X#10=(var X#8);X#8=(\ X#9.S#12);E#16} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#8)];X#10=(var X#8);X#8=(\ X#9.S#12);E#16} in A#13[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#10)];X#10=(var X#8);X#8=(\ X#9.S#12);E#16} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#1=C#7[(var X#10)];X#10=(var X#8);X#8=(\ X#9.S#12);E#16} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#16) ;X#8= (\ X#9.C#18[(var X#16)]) ;E#11 ;VV#17|X#16,(var X#8)| in A#13[(var X#10)] ) , (letrec X#10= (var X#16) ;X#8= (\ X#9.C#18[(var X#10)]) ;E#11 ;VV#17|X#16,(var X#8)| in A#13[(\ X#9.C#18[(var X#10)])] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#10),(\ X#9.C#18)), ((var X#16),(\ X#9.C#18)), ((var X#10),(\ X#9.C#18[[.]])), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {[.1]=(var X#16);VV#17|X#16,[.2]|}, X#2 |-> X#10, X#3 |-> X#16, X#1 |-> X#8, E#4 |-> {E#11;VV#17|X#16,(var X#8)|}, C#7 |-> (\ X#9.C#18), S#12 |-> C#18[(var X#10)]} and instantiated rules: (letrec {X#10=(var X#16);X#8=(\ X#9.C#18[(var X#10)]);E#11;VV#17|X#16,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#16);X#8=(\ X#9.C#18[(var X#16)]);E#11;VV#17|X#16,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#16);X#8=(\ X#9.C#18[(var X#10)]);E#11;VV#17|X#16,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#16);X#8=(\ X#9.C#18[(var X#10)]);E#11;VV#17|X#16,(var X#8)|} in A#13[(\ X#9.C#18[(var X#10)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#16)] ;X#10= (var X#16) ;X#8= (\ X#9.S#12) ;E#18 ;VV#17|X#16,(var X#8)| in A#13[(var X#10)] ) , (letrec X#1= C#7[(var X#10)] ;X#10= (var X#16) ;X#8= (\ X#9.S#12) ;E#18 ;VV#17|X#16,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#10),C#7), ((var X#16),C#7), ((var X#10),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {[.1]=(var X#16);VV#17|X#16,[.2]|}, X#2 |-> X#10, X#3 |-> X#16, E#11 |-> {X#1=C#7[(var X#10)];E#18}, E#4 |-> {X#8=(\ X#9.S#12);E#18;VV#17|X#16,(var X#8)|}} and instantiated rules: (letrec {X#1=C#7[(var X#10)];X#10=(var X#16);X#8=(\ X#9.S#12);E#18;VV#17|X#16,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#16)];X#10=(var X#16);X#8=(\ X#9.S#12);E#18;VV#17|X#16,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#10)];X#10=(var X#16);X#8=(\ X#9.S#12);E#18;VV#17|X#16,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#1=C#7[(var X#10)];X#10=(var X#16);X#8=(\ X#9.S#12);E#18;VV#17|X#16,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#17) ;X#8= (\ X#9.C#20[(var X#17)]) ;E#11 ;VV#18|X#10,(var X#16)| ;VV#19|X#17,(var X#8)| in A#13[(var X#10)] ) , (letrec X#16= (var X#17) ;X#8= (\ X#9.C#20[(var X#16)]) ;E#11 ;VV#18|X#10,(var X#16)| ;VV#19|X#17,(var X#8)| in A#13[(\ X#9.C#20[(var X#16)])] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#16),(\ X#9.C#20)), ((var X#17),(\ X#9.C#20)), ((var X#16),(\ X#9.C#20[[.]])), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=(var X#17);VV#18|[.1],(var X#16)|;VV#19|X#17,[.2]|}, X#2 |-> X#16, X#3 |-> X#17, X#1 |-> X#8, E#4 |-> {E#11;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|}, C#7 |-> (\ X#9.C#20), S#12 |-> C#20[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#17);X#8=(\ X#9.C#20[(var X#16)]);E#11;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#16=(var X#17);X#8=(\ X#9.C#20[(var X#17)]);E#11;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#17);X#8=(\ X#9.C#20[(var X#16)]);E#11;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#17);X#8=(\ X#9.C#20[(var X#16)]);E#11;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(\ X#9.C#20[(var X#16)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#17)] ;X#16= (var X#17) ;X#8= (\ X#9.S#12) ;E#20 ;VV#18|X#10,(var X#16)| ;VV#19|X#17,(var X#8)| in A#13[(var X#10)] ) , (letrec X#1= C#7[(var X#16)] ;X#16= (var X#17) ;X#8= (\ X#9.S#12) ;E#20 ;VV#18|X#10,(var X#16)| ;VV#19|X#17,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),C#7), ((var X#17),C#7), ((var X#16),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=(var X#17);VV#18|[.1],(var X#16)|;VV#19|X#17,[.2]|}, X#2 |-> X#16, X#3 |-> X#17, E#11 |-> {X#1=C#7[(var X#16)];E#20}, E#4 |-> {X#8=(\ X#9.S#12);E#20;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|}} and instantiated rules: (letrec {X#1=C#7[(var X#16)];X#16=(var X#17);X#8=(\ X#9.S#12);E#20;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#17)];X#16=(var X#17);X#8=(\ X#9.S#12);E#20;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#16)];X#16=(var X#17);X#8=(\ X#9.S#12);E#20;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#1=C#7[(var X#16)];X#16=(var X#17);X#8=(\ X#9.S#12);E#20;VV#18|X#10,(var X#16)|;VV#19|X#17,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#17) ;X#16= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| in A#13[(var X#10)] ) , (letrec X#10= (var X#16) ;X#16= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#17),[.]), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=(var X#17);[.1]=(var X#16);VV#19|X#17,[.2]|}, X#2 |-> X#16, X#3 |-> X#17, VV#18|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|}, C#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#10=(var X#16);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#17);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#16);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#16);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#17) ;X#21= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| ;VV#22|X#10,(var X#21)| in A#13[(var X#10)] ) , (letrec X#16= (var X#17) ;X#21= (var X#16) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| ;VV#22|X#10,(var X#21)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#17),[.]), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=(var X#17);X#21=(var X#16);VV#19|X#17,[.2]|;VV#22|[.1],(var X#21)|}, X#2 |-> X#16, X#3 |-> X#17, VV#18|.1,.2| |-> {X#21=[.2];VV#22|[.1],(var X#21)|}, X#1 |-> X#21, E#4 |-> {X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|}, C#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#17);X#21=(var X#16);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#16=(var X#17);X#21=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#17);X#21=(var X#16);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#17);X#21=(var X#16);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#8) ;X#8= (\ X#9.C#18[(var X#8)]) ;E#11 ;VV#17|X#10,(var X#16)| in A#13[(var X#10)] ) , (letrec X#16= (var X#8) ;X#8= (\ X#9.C#18[(var X#16)]) ;E#11 ;VV#17|X#10,(var X#16)| in A#13[(\ X#9.C#18[(var X#16)])] ) ) where Delta1 = {C#7} Delta2 = {} Delta3 = {((var X#16),(\ X#9.C#18)), ((var X#8),(\ X#9.C#18)), ((var X#16),(\ X#9.C#18[[.]])), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=[.2];VV#17|[.1],(var X#16)|}, X#2 |-> X#16, X#3 |-> X#8, X#1 |-> X#8, E#4 |-> {E#11;VV#17|X#10,(var X#16)|}, C#7 |-> (\ X#9.C#18), S#12 |-> C#18[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#8);X#8=(\ X#9.C#18[(var X#16)]);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#16=(var X#8);X#8=(\ X#9.C#18[(var X#8)]);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#8);X#8=(\ X#9.C#18[(var X#16)]);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#8);X#8=(\ X#9.C#18[(var X#16)]);E#11;VV#17|X#10,(var X#16)|} in A#13[(\ X#9.C#18[(var X#16)])]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#8)] ;X#16= (var X#8) ;X#8= (\ X#9.S#12) ;E#18 ;VV#17|X#10,(var X#16)| in A#13[(var X#10)] ) , (letrec X#1= C#7[(var X#16)] ;X#16= (var X#8) ;X#8= (\ X#9.S#12) ;E#18 ;VV#17|X#10,(var X#16)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),C#7), ((var X#8),C#7), ((var X#16),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=[.2];VV#17|[.1],(var X#16)|}, X#2 |-> X#16, X#3 |-> X#8, E#11 |-> {X#1=C#7[(var X#16)];E#18}, E#4 |-> {X#8=(\ X#9.S#12);E#18;VV#17|X#10,(var X#16)|}} and instantiated rules: (letrec {X#1=C#7[(var X#16)];X#16=(var X#8);X#8=(\ X#9.S#12);E#18;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#8)];X#16=(var X#8);X#8=(\ X#9.S#12);E#18;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#16)];X#16=(var X#8);X#8=(\ X#9.S#12);E#18;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#1=C#7[(var X#16)];X#16=(var X#8);X#8=(\ X#9.S#12);E#18;VV#17|X#10,(var X#16)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#8) ;X#16= (var X#8) ;X#8= (\ X#9.S#12) ;E#11 in A#13[(var X#10)] ) , (letrec X#10= (var X#16) ;X#16= (var X#8) ;X#8= (\ X#9.S#12) ;E#11 in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#8),[.]), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=[.2];[.1]=(var X#16)}, X#2 |-> X#16, X#3 |-> X#8, VV#17|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11}, C#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#10=(var X#16);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#8);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#16);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#16);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#8) ;X#19= (var X#8) ;X#8= (\ X#9.S#12) ;E#11 ;VV#20|X#10,(var X#19)| in A#13[(var X#10)] ) , (letrec X#16= (var X#8) ;X#19= (var X#16) ;X#8= (\ X#9.S#12) ;E#11 ;VV#20|X#10,(var X#19)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#8),[.]), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=[.2];X#19=(var X#16);VV#20|[.1],(var X#19)|}, X#2 |-> X#16, X#3 |-> X#8, VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#1 |-> X#19, E#4 |-> {X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|}, C#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#8);X#19=(var X#16);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]) <-cpx-e1- (letrec {X#16=(var X#8);X#19=(var X#8);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#8);X#19=(var X#16);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#8);X#19=(var X#16);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#12) ;E#11 ;EE#15[X#10,A#13[(var X#8)]] in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec X#8= (\ X#9.S#12) ;E#11 ;EE#15[X#10,A#13[(\ X#9.S#12)]] in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#14,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#10),A#17[(app A#18[[.]] T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19)]), T#16 |-> A#17[(app A#18[(var X#10)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#12) ;E#19 ;EE#15[X#10,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#17= T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#12) ;E#19 ;EE#15[X#10,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#17=T#16;X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]), E#11 |-> {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#19}, E#18 |-> {X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {T#21,A#19,T#16,T#6,A#13,A#20} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#22[(app A#23[[.]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> A#20, T#16 |-> A#20[A#22[(app A#23[(var X#8)] T#24)]], T#21 |-> A#22[(app A#23[(var X#8)] T#24)], A#13 |-> A#22[(app A#23 T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[A#13[(\ X#9.S#12)]] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11}, T#16 |-> A#20[(app A#21[A#13[(var X#8)]] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(app A#21[A#13[(\ X#9.S#12)]] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(\ X#9.S#12)] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#20[(app A#21[[.]] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#20[(app A#21[(var X#8)] T#22)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> [.], T#16 |-> A#20[(app A#21[(var X#8)] T#22)], A#13 |-> A#20[(app A#21 T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(app A#21[(\ X#9.S#12)] T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#20,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#20,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24)];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#21[X#20,[.2]]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[A#24[(app A#25[(\ X#9.S#12)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {T#23,A#19,T#16,T#6,A#13,A#22} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#24[(app A#25[[.]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26)]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[A#24[(app A#25[(var X#8)] T#26)]], T#23 |-> A#24[(app A#25[(var X#8)] T#26)], A#13 |-> A#24[(app A#25 T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#22[A#24[(app A#25[(\ X#9.S#12)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[(app A#23[A#13[(\ X#9.S#12)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, T#16 |-> A#22[(app A#23[A#13[(var X#8)]] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#22[(app A#23[A#13[(\ X#9.S#12)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#22[(app A#23[[.]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#22[(app A#23[(var X#8)] T#24)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, A#19 |-> [.], T#16 |-> A#22[(app A#23[(var X#8)] T#24)], A#13 |-> A#22[(app A#23 T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#20=A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (\ X#9.C#17[(var X#3)]) ;E#16 ;EE#15[X#10,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#2= (var X#3) ;X#8= (\ X#9.C#17[(var X#2)]) ;E#16 ;EE#15[X#10,A#13[(\ X#9.C#17[(var X#2)])]] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#2),(\ X#9.C#17)), ((var X#3),(\ X#9.C#17)), ((var X#2),(\ X#9.C#17[[.]])), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, X#1 |-> X#8, E#4 |-> {E#16;EE#15[X#10,A#13[(var X#8)]]}, C#7 |-> (\ X#9.C#17), S#12 |-> C#17[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(\ X#9.C#17[(var X#2)]);E#16;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(\ X#9.C#17[(var X#3)]);E#16;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(\ X#9.C#17[(var X#2)]);E#16;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#2=(var X#3);X#8=(\ X#9.C#17[(var X#2)]);E#16;EE#15[X#10,A#13[(\ X#9.C#17[(var X#2)])]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#17 ;EE#15[X#10,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#17 ;EE#15[X#10,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#17}, E#16 |-> {X#1=C#7[(var X#2)];E#17}, E#4 |-> {X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[A#20[(app A#21[(var X#8)] C#22[(var X#3)])]] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[A#20[(app A#21[(\ X#9.S#12)] C#22[(var X#2)])]] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {C#19,A#17,C#7,A#13,A#18} Delta2 = {} Delta3 = {((var X#2),A#18[A#20[(app A#21[(var X#8)] C#22)]]), ((var X#3),A#18[A#20[(app A#21[(var X#8)] C#22)]]), ((var X#2),A#18[A#20[(app A#21[(var X#8)] C#22[[.]])]]), ((var X#8),A#20[(app A#21[[.]] C#22[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#16}, A#17 |-> A#18, C#7 |-> A#18[A#20[(app A#21[(var X#8)] C#22)]], C#19 |-> A#20[(app A#21[(var X#8)] C#22)], A#13 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[A#20[(app A#21[(var X#8)] C#22[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#18[A#20[(app A#21[(var X#8)] C#22[(var X#3)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[A#20[(app A#21[(var X#8)] C#22[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#18[A#20[(app A#21[(\ X#9.S#12)] C#22[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[(app A#19[A#13[(var X#8)]] C#20[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[(app A#19[A#13[(\ X#9.S#12)]] C#20[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#18[(app A#19[A#13[(var X#8)]] C#20)]), ((var X#3),A#18[(app A#19[A#13[(var X#8)]] C#20)]), ((var X#2),A#18[(app A#19[A#13[(var X#8)]] C#20[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] C#20[(var X#2)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#16}, C#7 |-> A#18[(app A#19[A#13[(var X#8)]] C#20)], A#17 |-> A#18[(app A#19 C#20[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] C#20[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] C#20[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] C#20[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#18[(app A#19[A#13[(\ X#9.S#12)]] C#20[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[(app A#19[(var X#8)] C#20[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[(app A#19[(\ X#9.S#12)] C#20[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#18[(app A#19[(var X#8)] C#20)]), ((var X#3),A#18[(app A#19[(var X#8)] C#20)]), ((var X#2),A#18[(app A#19[(var X#8)] C#20[[.]])]), ((var X#8),A#18[(app A#19[[.]] C#20[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#16}, A#17 |-> [.], C#7 |-> A#18[(app A#19[(var X#8)] C#20)], A#13 |-> A#18[(app A#19 C#20[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[(app A#19[(var X#8)] C#20[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#18[(app A#19[(var X#8)] C#20[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[(app A#19[(var X#8)] C#20[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#18[(app A#19[(\ X#9.S#12)] C#20[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#18)] C#22[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#18,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(var X#18)] C#22[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#18,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[(var X#18)] C#22)]), ((var X#3),A#20[(app A#21[(var X#18)] C#22)]), ((var X#2),A#20[(app A#21[(var X#18)] C#22[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];EE#19[X#18,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]}, C#7 |-> A#20[(app A#21[(var X#18)] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(app A#21[(var X#18)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#20[X#10,(var X#18)] ;EE#21[X#19,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] C#24[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#20[X#10,(var X#18)] ;EE#21[X#19,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[(var X#19)] C#24)]), ((var X#3),A#22[(app A#23[(var X#19)] C#24)]), ((var X#2),A#22[(app A#23[(var X#19)] C#24[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#1 |-> X#18, E#4 |-> {X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]}, C#7 |-> A#22[(app A#23[(var X#19)] C#24)], A#17 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#22[(app A#23[(var X#19)] C#24[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(app A#23[(var X#8)] C#24[(var X#3)])]] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#2)])]] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {C#21,A#17,C#7,A#13,A#20} Delta2 = {} Delta3 = {((var X#2),A#20[A#22[(app A#23[(var X#8)] C#24)]]), ((var X#3),A#20[A#22[(app A#23[(var X#8)] C#24)]]), ((var X#2),A#20[A#22[(app A#23[(var X#8)] C#24[[.]])]]), ((var X#8),A#22[(app A#23[[.]] C#24[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]}, A#17 |-> A#20, C#7 |-> A#20[A#22[(app A#23[(var X#8)] C#24)]], C#21 |-> A#22[(app A#23[(var X#8)] C#24)], A#13 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[A#22[(app A#23[(var X#8)] C#24[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#18=A#20[A#22[(app A#23[(var X#8)] C#24[(var X#3)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[A#22[(app A#23[(var X#8)] C#24[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[(app A#21[A#13[(\ X#9.S#12)]] C#22[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {A#17,C#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[A#13[(var X#8)]] C#22)]), ((var X#3),A#20[(app A#21[A#13[(var X#8)]] C#22)]), ((var X#2),A#20[(app A#21[A#13[(var X#8)]] C#22[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] C#22[(var X#2)])];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]}, C#7 |-> A#20[(app A#21[A#13[(var X#8)]] C#22)], A#17 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[A#13[(\ X#9.S#12)]] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#8)] C#22[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[(app A#21[(\ X#9.S#12)] C#22[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[(var X#8)] C#22)]), ((var X#3),A#20[(app A#21[(var X#8)] C#22)]), ((var X#2),A#20[(app A#21[(var X#8)] C#22[[.]])]), ((var X#8),A#20[(app A#21[[.]] C#22[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=(var X#3);E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#4 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]}, A#17 |-> [.], C#7 |-> A#20[(app A#21[(var X#8)] C#22)], A#13 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#8)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#18=A#20[(app A#21[(var X#8)] C#22[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#8)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[(\ X#9.S#12)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#8= (\ X#9.C#19[(var X#3)]) ;E#11 ;EE#18[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#8= (\ X#9.C#19[(var X#10)]) ;E#11 ;EE#18[X#3,A#13[(\ X#9.C#19[(var X#10)])]] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#10),(\ X#9.C#19)), ((var X#3),(\ X#9.C#19)), ((var X#10),(\ X#9.C#19[[.]])), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {[.1]=(var X#3);EE#18[X#3,[.2]]}, X#2 |-> X#10, X#1 |-> X#8, E#4 |-> {E#11;EE#18[X#3,A#13[(var X#8)]]}, C#7 |-> (\ X#9.C#19), S#12 |-> C#19[(var X#10)], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#8=(\ X#9.C#19[(var X#10)]);E#11;EE#18[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#8=(\ X#9.C#19[(var X#3)]);E#11;EE#18[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#8=(\ X#9.C#19[(var X#10)]);E#11;EE#18[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#8=(\ X#9.C#19[(var X#10)]);E#11;EE#18[X#3,A#13[(\ X#9.C#19[(var X#10)])]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#10= (var X#3) ;X#8= (\ X#9.S#12) ;E#19 ;EE#18[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#1= C#7[(var X#10)] ;X#10= (var X#3) ;X#8= (\ X#9.S#12) ;E#19 ;EE#18[X#3,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#10),C#7), ((var X#3),C#7), ((var X#10),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {[.1]=(var X#3);EE#18[X#3,[.2]]}, X#2 |-> X#10, E#11 |-> {X#1=C#7[(var X#10)];E#19}, E#4 |-> {X#8=(\ X#9.S#12);E#19;EE#18[X#3,A#13[(var X#8)]]}, A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#10)];X#10=(var X#3);X#8=(\ X#9.S#12);E#19;EE#18[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#10=(var X#3);X#8=(\ X#9.S#12);E#19;EE#18[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#10)];X#10=(var X#3);X#8=(\ X#9.S#12);E#19;EE#18[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#1=C#7[(var X#10)];X#10=(var X#3);X#8=(\ X#9.S#12);E#19;EE#18[X#3,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#20[A#22[(app A#23[(var X#8)] C#24[(var X#3)])]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#20[A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#10)])]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {C#21,A#19,C#7,A#13,A#20} Delta2 = {} Delta3 = {((var X#10),A#20[A#22[(app A#23[(var X#8)] C#24)]]), ((var X#3),A#20[A#22[(app A#23[(var X#8)] C#24)]]), ((var X#10),A#20[A#22[(app A#23[(var X#8)] C#24[[.]])]]), ((var X#8),A#22[(app A#23[[.]] C#24[(var X#10)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#3=A#20[[.2]];[.1]=(var X#3)}, X#2 |-> X#10, EE#18[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> A#20, C#7 |-> A#20[A#22[(app A#23[(var X#8)] C#24)]], A#16 |-> [.], X#17 |-> X#3, C#21 |-> A#22[(app A#23[(var X#8)] C#24)], A#13 |-> A#22[(app A#23 C#24[(var X#10)])]} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#20[A#22[(app A#23[(var X#8)] C#24[(var X#10)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#20[A#22[(app A#23[(var X#8)] C#24[(var X#3)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#20[A#22[(app A#23[(var X#8)] C#24[(var X#10)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#3=A#20[A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#10)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#20[(app A#21[A#13[(\ X#9.S#12)]] C#22[(var X#10)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#13} Delta2 = {} Delta3 = {((var X#10),A#20[(app A#21[A#13[(var X#8)]] C#22)]), ((var X#3),A#20[(app A#21[A#13[(var X#8)]] C#22)]), ((var X#10),A#20[(app A#21[A#13[(var X#8)]] C#22[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#3=A#20[(app A#21[[.2]] C#22[(var X#10)])];[.1]=(var X#3)}, X#2 |-> X#10, EE#18[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] C#22[(var X#10)])]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11}, C#7 |-> A#20[(app A#21[A#13[(var X#8)]] C#22)], A#19 |-> A#20[(app A#21 C#22[(var X#10)])], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#10)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#3)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#20[(app A#21[A#13[(var X#8)]] C#22[(var X#10)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#3=A#20[(app A#21[A#13[(\ X#9.S#12)]] C#22[(var X#10)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#20[(app A#21[(var X#8)] C#22[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#20[(app A#21[(\ X#9.S#12)] C#22[(var X#10)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#10),A#20[(app A#21[(var X#8)] C#22)]), ((var X#3),A#20[(app A#21[(var X#8)] C#22)]), ((var X#10),A#20[(app A#21[(var X#8)] C#22[[.]])]), ((var X#8),A#20[(app A#21[[.]] C#22[(var X#10)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#10, EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> [.], C#7 |-> A#20[(app A#21[(var X#8)] C#22)], A#13 |-> A#20[(app A#21 C#22[(var X#10)])], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#20[(app A#21[(var X#8)] C#22[(var X#10)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#20[(app A#21[(var X#8)] C#22[(var X#3)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#20[(app A#21[(var X#8)] C#22[(var X#10)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#3=A#20[(app A#21[(\ X#9.S#12)] C#22[(var X#10)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#22[(app A#23[(var X#20)] C#24[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#20,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#22[(app A#23[(var X#20)] C#24[(var X#10)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#20,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#13} Delta2 = {} Delta3 = {((var X#10),A#22[(app A#23[(var X#20)] C#24)]), ((var X#3),A#22[(app A#23[(var X#20)] C#24)]), ((var X#10),A#22[(app A#23[(var X#20)] C#24[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#3=A#22[(app A#23[(var X#20)] C#24[(var X#10)])];[.1]=(var X#3);EE#21[X#20,[.2]]}, X#2 |-> X#10, EE#18[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] C#24[(var X#10)])];EE#21[X#20,[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]}, C#7 |-> A#22[(app A#23[(var X#20)] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#10)])], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#20)] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#20)] C#24[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#20)] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#20)] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#20= A#24[(app A#25[(var X#21)] C#26[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#22[X#3,(var X#20)] ;EE#23[X#21,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#20= A#24[(app A#25[(var X#21)] C#26[(var X#10)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#22[X#3,(var X#20)] ;EE#23[X#21,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#13} Delta2 = {} Delta3 = {((var X#10),A#24[(app A#25[(var X#21)] C#26)]), ((var X#3),A#24[(app A#25[(var X#21)] C#26)]), ((var X#10),A#24[(app A#25[(var X#21)] C#26[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#10)])];[.1]=(var X#3);EE#22[X#3,(var X#20)];EE#23[X#21,[.2]]}, X#2 |-> X#10, EE#18[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#10)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#22[X#3,(var X#20)];EE#23[X#21,A#13[(var X#8)]]}, C#7 |-> A#24[(app A#25[(var X#21)] C#26)], A#19 |-> A#24[(app A#25 C#26[(var X#10)])], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#22[X#3,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#22[X#3,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#22[X#3,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#22[X#3,(var X#20)];EE#23[X#21,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#20= A#22[A#24[(app A#25[(var X#8)] C#26[(var X#3)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#3,(var X#20)] in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#20= A#22[A#24[(app A#25[(\ X#9.S#12)] C#26[(var X#10)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#3,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {C#23,A#19,C#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#10),A#22[A#24[(app A#25[(var X#8)] C#26)]]), ((var X#3),A#22[A#24[(app A#25[(var X#8)] C#26)]]), ((var X#10),A#22[A#24[(app A#25[(var X#8)] C#26[[.]])]]), ((var X#8),A#24[(app A#25[[.]] C#26[(var X#10)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#20=A#22[[.2]];[.1]=(var X#3);EE#21[X#3,(var X#20)]}, X#2 |-> X#10, EE#18[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]}, A#19 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#8)] C#26)]], A#16 |-> [.], X#17 |-> X#3, C#23 |-> A#24[(app A#25[(var X#8)] C#26)], A#13 |-> A#24[(app A#25 C#26[(var X#10)])]} and instantiated rules: (letrec {X#10=(var X#3);X#20=A#22[A#24[(app A#25[(var X#8)] C#26[(var X#10)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#20=A#22[A#24[(app A#25[(var X#8)] C#26[(var X#3)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#20=A#22[A#24[(app A#25[(var X#8)] C#26[(var X#10)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#20=A#22[A#24[(app A#25[(\ X#9.S#12)] C#26[(var X#10)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#20= A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#3,(var X#20)] in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#20= A#22[(app A#23[A#13[(\ X#9.S#12)]] C#24[(var X#10)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#3,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#13} Delta2 = {} Delta3 = {((var X#10),A#22[(app A#23[A#13[(var X#8)]] C#24)]), ((var X#3),A#22[(app A#23[A#13[(var X#8)]] C#24)]), ((var X#10),A#22[(app A#23[A#13[(var X#8)]] C#24[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] C#24[(var X#10)])];[.1]=(var X#3);EE#21[X#3,(var X#20)]}, X#2 |-> X#10, EE#18[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] C#24[(var X#10)])];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]}, C#7 |-> A#22[(app A#23[A#13[(var X#8)]] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#10)])], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#20=A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#20=A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#20=A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#20=A#22[(app A#23[A#13[(\ X#9.S#12)]] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#20= A#22[(app A#23[(var X#8)] C#24[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#3,(var X#20)] in A#14[(var X#10)] ) , (letrec X#10= (var X#3) ;X#20= A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#10)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#3,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#10),A#22[(app A#23[(var X#8)] C#24)]), ((var X#3),A#22[(app A#23[(var X#8)] C#24)]), ((var X#10),A#22[(app A#23[(var X#8)] C#24[[.]])]), ((var X#8),A#22[(app A#23[[.]] C#24[(var X#10)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#20=[.2];[.1]=(var X#3);EE#21[X#3,(var X#20)]}, X#2 |-> X#10, EE#18[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]}, A#19 |-> [.], C#7 |-> A#22[(app A#23[(var X#8)] C#24)], A#13 |-> A#22[(app A#23 C#24[(var X#10)])], A#16 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#20=A#22[(app A#23[(var X#8)] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#20=A#22[(app A#23[(var X#8)] C#24[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#20=A#22[(app A#23[(var X#8)] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#3);X#20=A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#10)])];X#8=(\ X#9.S#12);E#11;EE#21[X#3,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#8= (\ X#9.C#21[(var X#3)]) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#20[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#8= (\ X#9.C#21[(var X#17)]) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#20[X#3,A#13[(\ X#9.C#21[(var X#17)])]] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#17),(\ X#9.C#21)), ((var X#3),(\ X#9.C#21)), ((var X#17),(\ X#9.C#21[[.]])), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);EE#19[[.1],(var X#17)];EE#20[X#3,[.2]]}, X#2 |-> X#17, X#1 |-> X#8, E#4 |-> {E#11;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]}, C#7 |-> (\ X#9.C#21), S#12 |-> C#21[(var X#17)], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#8=(\ X#9.C#21[(var X#17)]);E#11;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#8=(\ X#9.C#21[(var X#3)]);E#11;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#8=(\ X#9.C#21[(var X#17)]);E#11;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#8=(\ X#9.C#21[(var X#17)]);E#11;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(\ X#9.C#21[(var X#17)])]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#21 ;EE#19[X#10,(var X#17)] ;EE#20[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#1= C#7[(var X#17)] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#21 ;EE#19[X#10,(var X#17)] ;EE#20[X#3,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),C#7), ((var X#3),C#7), ((var X#17),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);EE#19[[.1],(var X#17)];EE#20[X#3,[.2]]}, X#2 |-> X#17, E#11 |-> {X#1=C#7[(var X#17)];E#21}, E#4 |-> {X#8=(\ X#9.S#12);E#21;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]}, A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#21;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#17=(var X#3);X#8=(\ X#9.S#12);E#21;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#21;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#1=C#7[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#21;EE#19[X#10,(var X#17)];EE#20[X#3,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(var X#3)] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(var X#17)] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22[[.]]), ((var X#3),A#22[[.]]), ((var X#17),A#22[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);[.1]=A#22[(var X#17)];EE#20[X#3,[.2]]}, X#2 |-> X#17, EE#19[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]}, A#21 |-> A#22, C#7 |-> A#22[[.]], A#16 |-> [.], X#18 |-> X#3, C#23 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=A#22[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(var X#3)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(var X#3)] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(var X#17)] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22), ((var X#3),A#22), ((var X#17),A#22[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);[.1]=A#22[(var X#17)];EE#20[X#3,[.2]]}, X#2 |-> X#17, EE#19[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]}, A#21 |-> A#22[[.]], C#7 |-> A#22, A#16 |-> [.], X#18 |-> X#3, A#23 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=A#22[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(var X#3)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(var X#17)];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#17)] C#24[(var X#3)])] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#17)] C#24[(var X#17)])] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#22[(app A#23[(var X#17)] C#24)]), ((var X#3),A#22[(app A#23[(var X#17)] C#24)]), ((var X#17),A#22[(app A#23[(var X#17)] C#24[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);[.1]=A#22[(app A#23[(var X#17)] C#24[(var X#17)])];EE#20[X#3,[.2]]}, X#2 |-> X#17, EE#19[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] C#24[(var X#17)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]}, C#7 |-> A#22[(app A#23[(var X#17)] C#24)], A#21 |-> A#22[(app A#23 C#24[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#17)] C#24[(var X#17)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#17)] C#24[(var X#3)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#17)] C#24[(var X#17)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(app A#23[(var X#17)] C#24[(var X#17)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= (var X#17) ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),[.]), ((var X#3),[.]), ((var X#17),[.]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);[.1]=(var X#17);EE#20[X#3,[.2]]}, X#2 |-> X#17, EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]}, C#7 |-> [.], A#21 |-> [.], X#17 |-> X#17, A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#10=(var X#17);X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#17);X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#17);X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#22)] C#26[(var X#3)])] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] ;EE#23[X#22,(var X#17)] in A#14[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(var X#22)] C#26[(var X#17)])] ;X#17= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] ;EE#23[X#22,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#24[(app A#25[(var X#22)] C#26)]), ((var X#3),A#24[(app A#25[(var X#22)] C#26)]), ((var X#17),A#24[(app A#25[(var X#22)] C#26[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);[.1]=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];EE#20[X#3,[.2]];EE#23[X#22,(var X#17)]}, X#2 |-> X#17, EE#19[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];EE#23[X#22,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#22,(var X#17)]}, C#7 |-> A#24[(app A#25[(var X#22)] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#22,(var X#17)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#3)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#22,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#22,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];X#17=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]];EE#23[X#22,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] ;EE#24[X#10,(var X#22)] ;EE#25[X#23,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] ;EE#24[X#10,(var X#22)] ;EE#25[X#23,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#26[(app A#27[(var X#23)] C#28)]), ((var X#3),A#26[(app A#27[(var X#23)] C#28)]), ((var X#17),A#26[(app A#27[(var X#23)] C#28[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];EE#20[X#3,[.2]];EE#24[[.1],(var X#22)];EE#25[X#23,(var X#17)]}, X#2 |-> X#17, EE#19[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#24[X#10,(var X#22)];EE#25[X#23,(var X#17)]}, C#7 |-> A#26[(app A#27[(var X#23)] C#28)], A#21 |-> A#26[(app A#27 C#28[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#24[X#10,(var X#22)];EE#25[X#23,(var X#17)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#24[X#10,(var X#22)];EE#25[X#23,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#24[X#10,(var X#22)];EE#25[X#23,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]];EE#24[X#10,(var X#22)];EE#25[X#23,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#24[(var X#3)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#24[(var X#17)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13,A#24} Delta2 = {} Delta3 = {((var X#17),A#24[[.]]), ((var X#3),A#24[[.]]), ((var X#17),A#24[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#24[(var X#17)];EE#20[X#3,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, EE#19[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, A#21 |-> A#24, C#7 |-> A#24[[.]], A#16 |-> [.], X#18 |-> X#3, C#25 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#24[(var X#3)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#24[(var X#3)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#24[(var X#17)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13,A#24} Delta2 = {} Delta3 = {((var X#17),A#24), ((var X#3),A#24), ((var X#17),A#24[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#24[(var X#17)];EE#20[X#3,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, EE#19[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, A#21 |-> A#24[[.]], C#7 |-> A#24, A#16 |-> [.], X#18 |-> X#3, A#25 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#24[(var X#3)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#24[(app A#25[(var X#17)] C#26[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#24[(app A#25[(var X#17)] C#26[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#24[(app A#25[(var X#17)] C#26)]), ((var X#3),A#24[(app A#25[(var X#17)] C#26)]), ((var X#17),A#24[(app A#25[(var X#17)] C#26[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#24[(app A#25[(var X#17)] C#26[(var X#17)])];EE#20[X#3,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, EE#19[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] C#26[(var X#17)])];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, C#7 |-> A#24[(app A#25[(var X#17)] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#17)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#17)] C#26[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#17)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#17)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= (var X#3) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#3,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),[.]), ((var X#3),[.]), ((var X#17),[.]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=(var X#17);EE#20[X#3,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, EE#19[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, C#7 |-> [.], A#21 |-> [.], X#17 |-> X#17, A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#22=(var X#17);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=(var X#3);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=(var X#17);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=(var X#17);X#8=(\ X#9.S#12);E#11;EE#20[X#3,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#3= A#22[A#24[(app A#25[(var X#8)] C#26[(var X#3)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#3= A#22[A#24[(app A#25[(\ X#9.S#12)] C#26[(var X#17)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {C#23,A#21,C#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22[A#24[(app A#25[(var X#8)] C#26)]]), ((var X#3),A#22[A#24[(app A#25[(var X#8)] C#26)]]), ((var X#17),A#22[A#24[(app A#25[(var X#8)] C#26[[.]])]]), ((var X#8),A#24[(app A#25[[.]] C#26[(var X#17)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#3=A#22[[.2]];EE#19[[.1],(var X#17)]}, X#2 |-> X#17, EE#20[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]}, A#21 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#8)] C#26)]], A#16 |-> [.], X#18 |-> X#3, C#23 |-> A#24[(app A#25[(var X#8)] C#26)], A#13 |-> A#24[(app A#25 C#26[(var X#17)])]} and instantiated rules: (letrec {X#17=(var X#3);X#3=A#22[A#24[(app A#25[(var X#8)] C#26[(var X#17)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#3=A#22[A#24[(app A#25[(var X#8)] C#26[(var X#3)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#3=A#22[A#24[(app A#25[(var X#8)] C#26[(var X#17)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#3=A#22[A#24[(app A#25[(\ X#9.S#12)] C#26[(var X#17)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#3= A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#3= A#22[(app A#23[A#13[(\ X#9.S#12)]] C#24[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#22[(app A#23[A#13[(var X#8)]] C#24)]), ((var X#3),A#22[(app A#23[A#13[(var X#8)]] C#24)]), ((var X#17),A#22[(app A#23[A#13[(var X#8)]] C#24[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#3=A#22[(app A#23[[.2]] C#24[(var X#17)])];EE#19[[.1],(var X#17)]}, X#2 |-> X#17, EE#20[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] C#24[(var X#17)])]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]}, C#7 |-> A#22[(app A#23[A#13[(var X#8)]] C#24)], A#21 |-> A#22[(app A#23 C#24[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#3=A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#3=A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#3=A#22[(app A#23[A#13[(var X#8)]] C#24[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#3=A#22[(app A#23[A#13[(\ X#9.S#12)]] C#24[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#3= A#22[(app A#23[(var X#8)] C#24[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#3= A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#22[(app A#23[(var X#8)] C#24)]), ((var X#3),A#22[(app A#23[(var X#8)] C#24)]), ((var X#17),A#22[(app A#23[(var X#8)] C#24[[.]])]), ((var X#8),A#22[(app A#23[[.]] C#24[(var X#17)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#3=[.2];EE#19[[.1],(var X#17)]}, X#2 |-> X#17, EE#20[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]}, A#21 |-> [.], C#7 |-> A#22[(app A#23[(var X#8)] C#24)], A#13 |-> A#22[(app A#23 C#24[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#3=A#22[(app A#23[(var X#8)] C#24[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#3=A#22[(app A#23[(var X#8)] C#24[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#3=A#22[(app A#23[(var X#8)] C#24[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#3=A#22[(app A#23[(\ X#9.S#12)] C#24[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#3= A#24[(app A#25[(var X#22)] C#26[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#22,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#3= A#24[(app A#25[(var X#22)] C#26[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#22,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#24[(app A#25[(var X#22)] C#26)]), ((var X#3),A#24[(app A#25[(var X#22)] C#26)]), ((var X#17),A#24[(app A#25[(var X#22)] C#26[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];EE#19[[.1],(var X#17)];EE#23[X#22,[.2]]}, X#2 |-> X#17, EE#20[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];EE#23[X#22,[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#22,A#13[(var X#8)]]}, C#7 |-> A#24[(app A#25[(var X#22)] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#22,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#22,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#22,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#22,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#24[X#3,(var X#22)] ;EE#25[X#23,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#24[X#3,(var X#22)] ;EE#25[X#23,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#26[(app A#27[(var X#23)] C#28)]), ((var X#3),A#26[(app A#27[(var X#23)] C#28)]), ((var X#17),A#26[(app A#27[(var X#23)] C#28[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];EE#19[[.1],(var X#17)];EE#24[X#3,(var X#22)];EE#25[X#23,[.2]]}, X#2 |-> X#17, EE#20[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#24[X#3,(var X#22)];EE#25[X#23,A#13[(var X#8)]]}, C#7 |-> A#26[(app A#27[(var X#23)] C#28)], A#21 |-> A#26[(app A#27 C#28[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#24[X#3,(var X#22)];EE#25[X#23,A#13[(var X#8)]]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#24[X#3,(var X#22)];EE#25[X#23,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#24[X#3,(var X#22)];EE#25[X#23,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#24[X#3,(var X#22)];EE#25[X#23,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#24[A#26[(app A#27[(var X#8)] C#28[(var X#3)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#3,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#24[A#26[(app A#27[(\ X#9.S#12)] C#28[(var X#17)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#3,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {C#25,A#21,C#7,A#13,A#24} Delta2 = {} Delta3 = {((var X#17),A#24[A#26[(app A#27[(var X#8)] C#28)]]), ((var X#3),A#24[A#26[(app A#27[(var X#8)] C#28)]]), ((var X#17),A#24[A#26[(app A#27[(var X#8)] C#28[[.]])]]), ((var X#8),A#26[(app A#27[[.]] C#28[(var X#17)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#24[[.2]];EE#19[[.1],(var X#17)];EE#23[X#3,(var X#22)]}, X#2 |-> X#17, EE#20[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]}, A#21 |-> A#24, C#7 |-> A#24[A#26[(app A#27[(var X#8)] C#28)]], A#16 |-> [.], X#18 |-> X#3, C#25 |-> A#26[(app A#27[(var X#8)] C#28)], A#13 |-> A#26[(app A#27 C#28[(var X#17)])]} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#24[A#26[(app A#27[(var X#8)] C#28[(var X#17)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#24[A#26[(app A#27[(var X#8)] C#28[(var X#3)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#24[A#26[(app A#27[(var X#8)] C#28[(var X#17)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#24[A#26[(app A#27[(\ X#9.S#12)] C#28[(var X#17)])]];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#24[(app A#25[A#13[(var X#8)]] C#26[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#3,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#24[(app A#25[A#13[(\ X#9.S#12)]] C#26[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#3,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#24[(app A#25[A#13[(var X#8)]] C#26)]), ((var X#3),A#24[(app A#25[A#13[(var X#8)]] C#26)]), ((var X#17),A#24[(app A#25[A#13[(var X#8)]] C#26[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=A#24[(app A#25[[.2]] C#26[(var X#17)])];EE#19[[.1],(var X#17)];EE#23[X#3,(var X#22)]}, X#2 |-> X#17, EE#20[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] C#26[(var X#17)])];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]}, C#7 |-> A#24[(app A#25[A#13[(var X#8)]] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#24[(app A#25[A#13[(var X#8)]] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#24[(app A#25[A#13[(var X#8)]] C#26[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#24[(app A#25[A#13[(var X#8)]] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#24[(app A#25[A#13[(\ X#9.S#12)]] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#3) ;X#22= A#24[(app A#25[(var X#8)] C#26[(var X#3)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#3,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= (var X#3) ;X#22= A#24[(app A#25[(\ X#9.S#12)] C#26[(var X#17)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#19[X#10,(var X#17)] ;EE#23[X#3,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {C#7,A#13} Delta2 = {} Delta3 = {((var X#17),A#24[(app A#25[(var X#8)] C#26)]), ((var X#3),A#24[(app A#25[(var X#8)] C#26)]), ((var X#17),A#24[(app A#25[(var X#8)] C#26[[.]])]), ((var X#8),A#24[(app A#25[[.]] C#26[(var X#17)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=(var X#3);X#22=[.2];EE#19[[.1],(var X#17)];EE#23[X#3,(var X#22)]}, X#2 |-> X#17, EE#20[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]}, A#21 |-> [.], C#7 |-> A#24[(app A#25[(var X#8)] C#26)], A#13 |-> A#24[(app A#25 C#26[(var X#17)])], A#16 |-> [.], X#18 |-> X#3} and instantiated rules: (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#8)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) <-cpx-e1- (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#8)] C#26[(var X#3)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(var X#8)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=(var X#3);X#22=A#24[(app A#25[(\ X#9.S#12)] C#26[(var X#17)])];X#8=(\ X#9.S#12);E#11;EE#19[X#10,(var X#17)];EE#23[X#3,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#15,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#19[(app A#20[[.]] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#19[(app A#20[[.]] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21)]), T#18 |-> A#19[(app A#20[(var X#10)] T#21)], A#15 |-> A#19[(app A#20 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#19= T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=T#18;X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), E#12 |-> {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#21}, E#20 |-> {X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}} and instantiated rules: (letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#21,T#18,T#6,A#14,A#22} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> A#22, T#18 |-> A#22[A#24[(app A#25[(var X#11)] T#26)]], T#23 |-> A#24[(app A#25[(var X#11)] T#26)], A#14 |-> A#24[(app A#25 T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[A#14[(\ X#9.S#13)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24)];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, T#18 |-> A#22[(app A#23[A#14[(var X#11)]] T#24)], A#21 |-> A#22[(app A#23 T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[A#14[(\ X#9.S#13)]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(\ X#9.S#13)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[(app A#23[(var X#11)] T#24)];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=[.2]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> [.], T#18 |-> A#22[(app A#23[(var X#11)] T#24)], A#14 |-> A#22[(app A#23 T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(\ X#9.S#13)] T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#24[(app A#25[(var X#22)] T#26)];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#23[X#22,[.2]]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#18 |-> A#24[(app A#25[(var X#22)] T#26)], A#21 |-> A#24[(app A#25 T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#26[(app A#27[(var X#23)] T#28)];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#18 |-> A#26[(app A#27[(var X#23)] T#28)], A#21 |-> A#26[(app A#27 T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#24[A#26[(app A#27[(\ X#9.S#13)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#25,A#21,T#18,T#6,A#14,A#24} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> A#24, T#18 |-> A#24[A#26[(app A#27[(var X#11)] T#28)]], T#25 |-> A#26[(app A#27[(var X#11)] T#28)], A#14 |-> A#26[(app A#27 T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#24[A#26[(app A#27[(\ X#9.S#13)] T#28[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#24[(app A#25[A#14[(\ X#9.S#13)]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#23[[.1],(var X#22)]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, T#18 |-> A#24[(app A#25[A#14[(var X#11)]] T#26)], A#21 |-> A#24[(app A#25 T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#24[(app A#25[A#14[(\ X#9.S#13)]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#24[(app A#25[(var X#11)] T#26)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> [.], T#18 |-> A#24[(app A#25[(var X#11)] T#26)], A#14 |-> A#24[(app A#25 T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#22=A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#22=A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (\ X#9.C#19[(var X#3)]) ;E#18 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= (var X#3) ;X#8= (\ X#9.C#19[(var X#2)]) ;E#18 ;EE#16[X#10,A#14[(\ X#9.C#19[(var X#2)])]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#2),(\ X#9.C#19)), ((var X#3),(\ X#9.C#19)), ((var X#2),(\ X#9.C#19[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, X#1 |-> X#8, E#4 |-> {E#18;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> (\ X#9.C#19), S#13 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(\ X#9.C#19[(var X#2)]);E#18;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(\ X#9.C#19[(var X#3)]);E#18;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(\ X#9.C#19[(var X#2)]);E#18;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=(var X#3);X#8=(\ X#9.C#19[(var X#2)]);E#18;EE#16[X#10,A#14[(\ X#9.C#19[(var X#2)])]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#19 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#19 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#19}, E#18 |-> {X#1=C#7[(var X#2)];E#19}, E#4 |-> {X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(app A#23[(var X#11)] C#24[(var X#3)])]] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#20[A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#2)])]] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#21,A#19,C#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#2),A#20[A#22[(app A#23[(var X#11)] C#24)]]), ((var X#3),A#20[A#22[(app A#23[(var X#11)] C#24)]]), ((var X#2),A#20[A#22[(app A#23[(var X#11)] C#24[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|}, A#19 |-> A#20, C#7 |-> A#20[A#22[(app A#23[(var X#11)] C#24)]], C#21 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] C#24[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] C#24[(var X#3)])]];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] C#24[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#2)])]];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#20[(app A#21[A#14[(\ X#9.S#13)]] C#22[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[A#14[(var X#11)]] C#22)]), ((var X#3),A#20[(app A#21[A#14[(var X#11)]] C#22)]), ((var X#2),A#20[(app A#21[A#14[(var X#11)]] C#22[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] C#22[(var X#2)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|}, C#7 |-> A#20[(app A#21[A#14[(var X#11)]] C#22)], A#19 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(app A#21[A#14[(\ X#9.S#13)]] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#11)] C#22[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(\ X#9.S#13)] C#22[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[(var X#11)] C#22)]), ((var X#3),A#20[(app A#21[(var X#11)] C#22)]), ((var X#2),A#20[(app A#21[(var X#11)] C#22[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[(app A#21[[.]] C#22[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|}, A#19 |-> [.], C#7 |-> A#20[(app A#21[(var X#11)] C#22)], A#14 |-> A#20[(app A#21 C#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#11)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[(var X#11)] C#22[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#11)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(app A#21[(\ X#9.S#13)] C#22[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#20)] C#24[(var X#3)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#20,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#20)] C#24[(var X#2)])] ;X#2= (var X#3) ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#20,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[(var X#20)] C#24)]), ((var X#3),A#22[(app A#23[(var X#20)] C#24)]), ((var X#2),A#22[(app A#23[(var X#20)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] C#24[(var X#2)])];EE#21[X#20,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#22[(app A#23[(var X#20)] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#3)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#2)])];X#2=(var X#3);X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#20= A#24[(app A#25[(var X#21)] C#26[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= (var X#3) ;X#20= A#24[(app A#25[(var X#21)] C#26[(var X#2)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#24[(app A#25[(var X#21)] C#26)]), ((var X#3),A#24[(app A#25[(var X#21)] C#26)]), ((var X#2),A#24[(app A#25[(var X#21)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#2)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#24[(app A#25[(var X#21)] C#26)], A#19 |-> A#24[(app A#25 C#26[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#3)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=(var X#3);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#20= A#22[A#24[(app A#25[(var X#11)] C#26[(var X#3)])]] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= (var X#3) ;X#20= A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#2)])]] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#19,C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#2),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#3),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#2),A#22[A#24[(app A#25[(var X#11)] C#26[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|}, A#19 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#11)] C#26)]], C#23 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#20=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#2)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#20=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#3)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#20=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#2)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=(var X#3);X#20=A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#2)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#20= A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= (var X#3) ;X#20= A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#2)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#3),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#2),A#22[(app A#23[A#14[(var X#11)]] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] C#24[(var X#2)])];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|}, C#7 |-> A#22[(app A#23[A#14[(var X#11)]] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#20=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#20=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#3)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#20=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=(var X#3);X#20=A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#20= A#22[(app A#23[(var X#11)] C#24[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= (var X#3) ;X#20= A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#2)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[(var X#11)] C#24)]), ((var X#3),A#22[(app A#23[(var X#11)] C#24)]), ((var X#2),A#22[(app A#23[(var X#11)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=(var X#3);E#18}, EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|}, A#19 |-> [.], C#7 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#20=A#22[(app A#23[(var X#11)] C#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#2=(var X#3);X#20=A#22[(app A#23[(var X#11)] C#24[(var X#3)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=(var X#3);X#20=A#22[(app A#23[(var X#11)] C#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=(var X#3);X#20=A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#8= (\ X#9.C#19[(var X#8)]) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#8= (\ X#9.C#19[(var X#11)]) ;E#12 ;EE#16[X#10,A#14[(\ X#9.C#19[(var X#11)])]] in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#11),(\ X#9.C#19)), ((var X#8),(\ X#9.C#19)), ((var X#11),(\ X#9.C#19[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, X#1 |-> X#8, E#4 |-> {E#12;EE#16[X#10,A#14[(var X#11)]]}, C#7 |-> (\ X#9.C#19), S#13 |-> C#19[(var X#11)]} and instantiated rules: (letrec {X#11=(var X#8);X#8=(\ X#9.C#19[(var X#11)]);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#8=(\ X#9.C#19[(var X#8)]);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#8=(\ X#9.C#19[(var X#11)]);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#8=(\ X#9.C#19[(var X#11)]);E#12;EE#16[X#10,A#14[(\ X#9.C#19[(var X#11)])]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#8)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#19 ;EE#16[X#10,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#11)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#19 ;EE#16[X#10,A#14[(\ X#9.S#13)]] in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#11),C#7), ((var X#8),C#7), ((var X#11),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, E#12 |-> {X#1=C#7[(var X#11)];E#19}, E#4 |-> {X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]]}} and instantiated rules: (letrec {X#1=C#7[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#8)];X#11=(var X#8);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(\ X#9.S#13)]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(var X#8)]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[A#22[(\ X#9.S#13)]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {C#21,A#19,C#7,A#14,A#20,A#22} Delta2 = {} Delta3 = {((var X#11),A#20[A#22[[.]]]), ((var X#8),A#20[A#22[[.]]]), ((var X#11),A#20[A#22[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> A#20, C#7 |-> A#20[A#22[[.]]], A#14 |-> A#22, C#21 |-> A#22[[.]], C#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[A#22[(var X#8)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(\ X#9.S#13)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(var X#8)]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[A#22[(\ X#9.S#13)]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {C#21,A#19,C#7,A#14,A#20,A#22} Delta2 = {} Delta3 = {((var X#11),A#20[A#22]), ((var X#8),A#20[A#22]), ((var X#11),A#20[A#22[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> A#20, C#7 |-> A#20[A#22], A#14 |-> A#22[[.]], C#21 |-> A#22, A#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[A#22[(var X#8)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(\ X#9.S#13)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(app A#23[(var X#11)] C#24[(var X#8)])]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#11)])]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {C#21,A#19,C#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#11),A#20[A#22[(app A#23[(var X#11)] C#24)]]), ((var X#8),A#20[A#22[(app A#23[(var X#11)] C#24)]]), ((var X#11),A#20[A#22[(app A#23[(var X#11)] C#24[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> A#20, C#7 |-> A#20[A#22[(app A#23[(var X#11)] C#24)]], C#21 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#11)])]} and instantiated rules: (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] C#24[(var X#11)])]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] C#24[(var X#8)])]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] C#24[(var X#11)])]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#11)])]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#8)])] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[(app A#21[A#14[(\ X#9.S#13)]] C#22[(var X#11)])] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#20[(app A#21[A#14[(var X#11)]] C#22)]), ((var X#8),A#20[(app A#21[A#14[(var X#11)]] C#22)]), ((var X#11),A#20[(app A#21[A#14[(var X#11)]] C#22[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] C#22[(var X#11)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, C#7 |-> A#20[(app A#21[A#14[(var X#11)]] C#22)], A#19 |-> A#20[(app A#21 C#22[(var X#11)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#8)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] C#22[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(app A#21[A#14[(\ X#9.S#13)]] C#22[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(var X#8)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[(\ X#9.S#13)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#11),A#20[[.]]), ((var X#8),A#20[[.]]), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> [.], A#14 |-> A#20, C#7 |-> A#20[[.]], C#21 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(var X#8)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(\ X#9.S#13)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(var X#8)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[(\ X#9.S#13)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#11),A#20), ((var X#8),A#20), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> [.], A#14 |-> A#20[[.]], C#7 |-> A#20, A#21 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(var X#8)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(\ X#9.S#13)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#11)] C#22[(var X#8)])] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(\ X#9.S#13)] C#22[(var X#11)])] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#20[(app A#21[(var X#11)] C#22)]), ((var X#8),A#20[(app A#21[(var X#11)] C#22)]), ((var X#11),A#20[(app A#21[(var X#11)] C#22[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[(app A#21[[.]] C#22[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> [.], C#7 |-> A#20[(app A#21[(var X#11)] C#22)], A#14 |-> A#20[(app A#21 C#22[(var X#11)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#11)] C#22[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#20[(app A#21[(var X#11)] C#22[(var X#8)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#11)] C#22[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(app A#21[(\ X#9.S#13)] C#22[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#20)] C#24[(var X#8)])] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#20,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#20)] C#24[(var X#11)])] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#20,A#14[(\ X#9.S#13)]] in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#22[(app A#23[(var X#20)] C#24)]), ((var X#8),A#22[(app A#23[(var X#20)] C#24)]), ((var X#11),A#22[(app A#23[(var X#20)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] C#24[(var X#11)])];EE#21[X#20,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#20,A#14[(var X#11)]]}, C#7 |-> A#22[(app A#23[(var X#20)] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#11)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#21[X#20,A#14[(var X#11)]]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#8)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#21[X#20,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#21[X#20,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(var X#20)] C#24[(var X#11)])];X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#21[X#20,A#14[(\ X#9.S#13)]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#24[(app A#25[(var X#21)] C#26[(var X#8)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#24[(app A#25[(var X#21)] C#26[(var X#11)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#14[(\ X#9.S#13)]] in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#24[(app A#25[(var X#21)] C#26)]), ((var X#8),A#24[(app A#25[(var X#21)] C#26)]), ((var X#11),A#24[(app A#25[(var X#21)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] C#26[(var X#11)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]]}, C#7 |-> A#24[(app A#25[(var X#21)] C#26)], A#19 |-> A#24[(app A#25 C#26[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#8)])];X#8=(\ X#9.S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#24[(app A#25[(var X#21)] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(\ X#9.S#13)]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[A#24[(var X#8)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[A#24[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#19,C#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24[[.]]]), ((var X#8),A#22[A#24[[.]]]), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, C#7 |-> A#22[A#24[[.]]], A#14 |-> A#24, C#23 |-> A#24[[.]], C#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#8)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[A#24[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[A#24[(var X#8)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[A#24[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#19,C#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24]), ((var X#8),A#22[A#24]), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, C#7 |-> A#22[A#24], A#14 |-> A#24[[.]], C#23 |-> A#24, A#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#8)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[A#24[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[A#24[(app A#25[(var X#11)] C#26[(var X#8)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#11)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#19,C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#8),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#11),A#22[A#24[(app A#25[(var X#11)] C#26[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#11)] C#26)]], C#23 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#11)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#8)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#11)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#11)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#8)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#11)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {A#19,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#8),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#11),A#22[(app A#23[A#14[(var X#11)]] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] C#24[(var X#11)])];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, C#7 |-> A#22[(app A#23[A#14[(var X#11)]] C#24)], A#19 |-> A#22[(app A#23 C#24[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#8)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[(var X#8)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22[[.]]), ((var X#8),A#22[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> [.], A#14 |-> A#22, C#7 |-> A#22[[.]], C#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[(var X#8)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[(var X#8)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22), ((var X#8),A#22), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> [.], A#14 |-> A#22[[.]], C#7 |-> A#22, A#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[(var X#8)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#20= A#22[(app A#23[(var X#11)] C#24[(var X#8)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#11)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#22[(app A#23[(var X#11)] C#24)]), ((var X#8),A#22[(app A#23[(var X#11)] C#24)]), ((var X#11),A#22[(app A#23[(var X#11)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, X#3 |-> X#8, EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> [.], C#7 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[(app A#23[(var X#11)] C#24[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#20=A#22[(app A#23[(var X#11)] C#24[(var X#8)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[(app A#23[(var X#11)] C#24[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#8= (\ X#9.C#21[(var X#19)]) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#8= (\ X#9.C#21[(var X#11)]) ;E#12 ;EE#16[X#10,A#14[(\ X#9.C#21[(var X#11)])]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#11),(\ X#9.C#21)), ((var X#19),(\ X#9.C#21)), ((var X#11),(\ X#9.C#21[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, X#1 |-> X#8, E#4 |-> {E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|}, C#7 |-> (\ X#9.C#21), S#13 |-> C#21[(var X#11)]} and instantiated rules: (letrec {X#11=(var X#19);X#8=(\ X#9.C#21[(var X#11)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#8=(\ X#9.C#21[(var X#19)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#8=(\ X#9.C#21[(var X#11)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#8=(\ X#9.C#21[(var X#11)]);E#12;EE#16[X#10,A#14[(\ X#9.C#21[(var X#11)])]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#19)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(var X#11)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#11)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#11),C#7), ((var X#19),C#7), ((var X#11),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, E#12 |-> {X#1=C#7[(var X#11)];E#21}, E#4 |-> {X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|}} and instantiated rules: (letrec {X#1=C#7[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#19)];X#11=(var X#19);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(var X#19)]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(\ X#9.S#13)]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#21,C#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24[[.]]]), ((var X#19),A#22[A#24[[.]]]), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> A#22, C#7 |-> A#22[A#24[[.]]], A#14 |-> A#24, C#23 |-> A#24[[.]], C#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[A#24[(var X#19)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(\ X#9.S#13)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(var X#19)]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(\ X#9.S#13)]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#21,C#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24]), ((var X#19),A#22[A#24]), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> A#22, C#7 |-> A#22[A#24], A#14 |-> A#24[[.]], C#23 |-> A#24, A#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[A#24[(var X#19)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(\ X#9.S#13)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(app A#25[(var X#11)] C#26[(var X#19)])]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#11)])]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#21,C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#19),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#11),A#22[A#24[(app A#25[(var X#11)] C#26[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#11)] C#26)]], C#23 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#11)])]} and instantiated rules: (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#11)])]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#19)])]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#11)])]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#11)])]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#19)])] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#11)])] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#19),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#11),A#22[(app A#23[A#14[(var X#11)]] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] C#24[(var X#11)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, C#7 |-> A#22[(app A#23[A#14[(var X#11)]] C#24)], A#21 |-> A#22[(app A#23 C#24[(var X#11)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#19)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(var X#19)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(\ X#9.S#13)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22[[.]]), ((var X#19),A#22[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#22, C#7 |-> A#22[[.]], C#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(var X#19)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(\ X#9.S#13)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(var X#19)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(\ X#9.S#13)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22), ((var X#19),A#22), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#22[[.]], C#7 |-> A#22, A#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(var X#19)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(\ X#9.S#13)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#11)] C#24[(var X#19)])] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#11)])] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#22[(app A#23[(var X#11)] C#24)]), ((var X#19),A#22[(app A#23[(var X#11)] C#24)]), ((var X#11),A#22[(app A#23[(var X#11)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> [.], C#7 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#11)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#11)] C#24[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#11)] C#24[(var X#19)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#11)] C#24[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#22)] C#26[(var X#19)])] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(var X#11)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(var X#22)] C#26[(var X#11)])] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(\ X#9.S#13)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#24[(app A#25[(var X#22)] C#26)]), ((var X#19),A#24[(app A#25[(var X#22)] C#26)]), ((var X#11),A#24[(app A#25[(var X#22)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] C#26[(var X#11)])];EE#23[X#22,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#19,(var X#8)|}, C#7 |-> A#24[(app A#25[(var X#22)] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#11)])]} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#19)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#11)])];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(\ X#9.S#13)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(var X#11)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#11)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(\ X#9.S#13)]] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#26[(app A#27[(var X#23)] C#28)]), ((var X#19),A#26[(app A#27[(var X#23)] C#28)]), ((var X#11),A#26[(app A#27[(var X#23)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] C#28[(var X#11)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#19,(var X#8)|}, C#7 |-> A#26[(app A#27[(var X#23)] C#28)], A#21 |-> A#26[(app A#27 C#28[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(\ X#9.S#13)]];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[A#26[(var X#19)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[A#26[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#21,C#7,A#14,A#24,A#26} Delta2 = {} Delta3 = {((var X#11),A#24[A#26[[.]]]), ((var X#19),A#24[A#26[[.]]]), ((var X#11),A#24[A#26[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> A#24, C#7 |-> A#24[A#26[[.]]], A#14 |-> A#26, C#25 |-> A#26[[.]], C#27 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#19)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[A#26[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[A#26[(var X#19)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[A#26[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#21,C#7,A#14,A#24,A#26} Delta2 = {} Delta3 = {((var X#11),A#24[A#26]), ((var X#19),A#24[A#26]), ((var X#11),A#24[A#26[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> A#24, C#7 |-> A#24[A#26], A#14 |-> A#26[[.]], C#25 |-> A#26, A#27 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#19)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[A#26[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#11)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#21,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#11),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#11),A#24[A#26[(app A#27[(var X#11)] C#28[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> A#24, C#7 |-> A#24[A#26[(app A#27[(var X#11)] C#28)]], C#25 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#11)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#11)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#11)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#11)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#11),A#24[(app A#25[A#14[(var X#11)]] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] C#26[(var X#11)])];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, C#7 |-> A#24[(app A#25[A#14[(var X#11)]] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#11),A#24[[.]]), ((var X#19),A#24[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#24, C#7 |-> A#24[[.]], C#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#11),A#24), ((var X#19),A#24), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#24[[.]], C#7 |-> A#24, A#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#19) ;X#22= A#24[(app A#25[(var X#11)] C#26[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#11)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#11),A#24[(app A#25[(var X#11)] C#26)]), ((var X#19),A#24[(app A#25[(var X#11)] C#26)]), ((var X#11),A#24[(app A#25[(var X#11)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#11)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, X#3 |-> X#19, EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> [.], C#7 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#11)])]} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#19);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#11)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#20) ;X#8= (\ X#9.C#23[(var X#20)]) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#8= (\ X#9.C#23[(var X#19)]) ;E#12 ;EE#16[X#10,A#14[(\ X#9.C#23[(var X#19)])]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),(\ X#9.C#23)), ((var X#20),(\ X#9.C#23)), ((var X#19),(\ X#9.C#23[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, X#1 |-> X#8, E#4 |-> {E#12;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, C#7 |-> (\ X#9.C#23), S#13 |-> C#23[(var X#19)]} and instantiated rules: (letrec {X#19=(var X#20);X#8=(\ X#9.C#23[(var X#19)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#20);X#8=(\ X#9.C#23[(var X#20)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#8=(\ X#9.C#23[(var X#19)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#8=(\ X#9.C#23[(var X#19)]);E#12;EE#16[X#10,A#14[(\ X#9.C#23[(var X#19)])]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#20)] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#23 ;EE#16[X#10,A#14[(var X#11)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#19)] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#23 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),C#7), ((var X#20),C#7), ((var X#19),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, E#12 |-> {X#1=C#7[(var X#19)];E#23}, E#4 |-> {X#8=(\ X#9.S#13);E#23;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}} and instantiated rules: (letrec {X#1=C#7[(var X#19)];X#19=(var X#20);X#8=(\ X#9.S#13);E#23;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#20)];X#19=(var X#20);X#8=(\ X#9.S#13);E#23;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#19)];X#19=(var X#20);X#8=(\ X#9.S#13);E#23;EE#16[X#10,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#19)];X#19=(var X#20);X#8=(\ X#9.S#13);E#23;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#20) ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#20),[.]), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);[.1]=(var X#19);VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, VV#21|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|}, C#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#11=(var X#19);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#20);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#20) ;X#24= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#22|X#20,(var X#8)| ;VV#25|X#11,(var X#24)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#24= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#22|X#20,(var X#8)| ;VV#25|X#11,(var X#24)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#20),[.]), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);X#24=(var X#19);VV#22|X#20,[.2]|;VV#25|[.1],(var X#24)|}, X#2 |-> X#19, X#3 |-> X#20, VV#21|.1,.2| |-> {X#24=[.2];VV#25|[.1],(var X#24)|}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|}, C#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=(var X#20);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#20);X#24=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[A#26[(app A#27[(var X#11)] C#28[(var X#20)])]] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])]] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#23,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#20),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {[.1]=A#24[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, A#23 |-> A#24, C#7 |-> A#24[A#26[(app A#27[(var X#11)] C#28)]], C#25 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#10=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#20)])]];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])]];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#20)])] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#19)])] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#20),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {[.1]=A#24[(app A#25[[.2]] C#26[(var X#19)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, C#7 |-> A#24[(app A#25[A#14[(var X#11)]] C#26)], A#23 |-> A#24[(app A#25 C#26[(var X#19)])]} and instantiated rules: (letrec {X#10=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#20)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#11)] C#26[(var X#20)])] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[(var X#11)] C#26)]), ((var X#20),A#24[(app A#25[(var X#11)] C#26)]), ((var X#19),A#24[(app A#25[(var X#11)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, A#23 |-> [.], C#7 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#19)])]} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[(var X#11)] C#26[(var X#20)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#26[(app A#27[(var X#24)] C#28[(var X#20)])] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#24,A#14[(var X#11)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#26[(app A#27[(var X#24)] C#28[(var X#19)])] ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#24,A#14[(\ X#9.S#13)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#24)] C#28)]), ((var X#20),A#26[(app A#27[(var X#24)] C#28)]), ((var X#19),A#26[(app A#27[(var X#24)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {[.1]=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];EE#25[X#24,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#25[X#24,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, C#7 |-> A#26[(app A#27[(var X#24)] C#28)], A#23 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#25[X#24,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#20)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#25[X#24,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#25[X#24,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#25[X#24,A#14[(\ X#9.S#13)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#20) ;X#24= A#28[(app A#29[(var X#25)] C#30[(var X#20)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#26[X#10,(var X#24)] ;EE#27[X#25,A#14[(var X#11)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#24= A#28[(app A#29[(var X#25)] C#30[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#26[X#10,(var X#24)] ;EE#27[X#25,A#14[(\ X#9.S#13)]] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#28[(app A#29[(var X#25)] C#30)]), ((var X#20),A#28[(app A#29[(var X#25)] C#30)]), ((var X#19),A#28[(app A#29[(var X#25)] C#30[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];EE#26[[.1],(var X#24)];EE#27[X#25,[.2]]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#26[X#10,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, C#7 |-> A#28[(app A#29[(var X#25)] C#30)], A#23 |-> A#28[(app A#29 C#30[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#20);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#26[X#10,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#20);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#20)])];X#8=(\ X#9.S#13);E#12;EE#26[X#10,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#26[X#10,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#26[X#10,(var X#24)];EE#27[X#25,A#14[(\ X#9.S#13)]];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#20) ;X#24= A#26[A#28[(app A#29[(var X#11)] C#30[(var X#20)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#10,(var X#24)] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#24= A#26[A#28[(app A#29[(\ X#9.S#13)] C#30[(var X#19)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#10,(var X#24)] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#27,A#23,C#7,A#14,A#26} Delta2 = {} Delta3 = {((var X#19),A#26[A#28[(app A#29[(var X#11)] C#30)]]), ((var X#20),A#26[A#28[(app A#29[(var X#11)] C#30)]]), ((var X#19),A#26[A#28[(app A#29[(var X#11)] C#30[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#28[(app A#29[[.]] C#30[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {X#24=A#26[[.2]];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, A#23 |-> A#26, C#7 |-> A#26[A#28[(app A#29[(var X#11)] C#30)]], C#27 |-> A#28[(app A#29[(var X#11)] C#30)], A#14 |-> A#28[(app A#29 C#30[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#20);X#24=A#26[A#28[(app A#29[(var X#11)] C#30[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#20);X#24=A#26[A#28[(app A#29[(var X#11)] C#30[(var X#20)])]];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#24=A#26[A#28[(app A#29[(var X#11)] C#30[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#24=A#26[A#28[(app A#29[(\ X#9.S#13)] C#30[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#20) ;X#24= A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#20)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#10,(var X#24)] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#24= A#26[(app A#27[A#14[(\ X#9.S#13)]] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#10,(var X#24)] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[A#14[(var X#11)]] C#28)]), ((var X#20),A#26[(app A#27[A#14[(var X#11)]] C#28)]), ((var X#19),A#26[(app A#27[A#14[(var X#11)]] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {X#24=A#26[(app A#27[[.2]] C#28[(var X#19)])];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, C#7 |-> A#26[(app A#27[A#14[(var X#11)]] C#28)], A#23 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#20);X#24=A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#20);X#24=A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#20)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#24=A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#24=A#26[(app A#27[A#14[(\ X#9.S#13)]] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#20) ;X#24= A#26[(app A#27[(var X#11)] C#28[(var X#20)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#10,(var X#24)] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#24= A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#25[X#10,(var X#24)] ;VV#21|X#11,(var X#19)| ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#11)] C#28)]), ((var X#20),A#26[(app A#27[(var X#11)] C#28)]), ((var X#19),A#26[(app A#27[(var X#11)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#2 |-> X#19, X#3 |-> X#20, EE#16[.1,.2] |-> {X#24=[.2];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|}, A#23 |-> [.], C#7 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#20);X#24=A#26[(app A#27[(var X#11)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#20);X#24=A#26[(app A#27[(var X#11)] C#28[(var X#20)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#24=A#26[(app A#27[(var X#11)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#24=A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#25[X#10,(var X#24)];VV#21|X#11,(var X#19)|;VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#8= (\ X#9.C#21[(var X#8)]) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#8= (\ X#9.C#21[(var X#19)]) ;E#12 ;EE#16[X#10,A#14[(\ X#9.C#21[(var X#19)])]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),(\ X#9.C#21)), ((var X#8),(\ X#9.C#21)), ((var X#19),(\ X#9.C#21[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, X#1 |-> X#8, E#4 |-> {E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|}, C#7 |-> (\ X#9.C#21), S#13 |-> C#21[(var X#19)]} and instantiated rules: (letrec {X#19=(var X#8);X#8=(\ X#9.C#21[(var X#19)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#8);X#8=(\ X#9.C#21[(var X#8)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#8=(\ X#9.C#21[(var X#19)]);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#8=(\ X#9.C#21[(var X#19)]);E#12;EE#16[X#10,A#14[(\ X#9.C#21[(var X#19)])]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#8)] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(var X#11)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#19)] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),C#7), ((var X#8),C#7), ((var X#19),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, E#12 |-> {X#1=C#7[(var X#19)];E#21}, E#4 |-> {X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|}} and instantiated rules: (letrec {X#1=C#7[(var X#19)];X#19=(var X#8);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#8)];X#19=(var X#8);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#19)];X#19=(var X#8);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#19)];X#19=(var X#8);X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#8),[.]), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];[.1]=(var X#19)}, X#2 |-> X#19, X#3 |-> X#8, VV#20|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#11, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]}, C#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#11=(var X#19);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#11=(var X#8);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#22= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#23|X#11,(var X#22)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#22= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#23|X#11,(var X#22)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#8),[.]), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];X#22=(var X#19);VV#23|[.1],(var X#22)|}, X#2 |-> X#19, X#3 |-> X#8, VV#20|.1,.2| |-> {X#22=[.2];VV#23|[.1],(var X#22)|}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|}, C#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=(var X#8);X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#8);X#22=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(app A#25[(var X#11)] C#26[(var X#8)])]] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])]] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#21,C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#19),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#8),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#19),A#22[A#24[(app A#25[(var X#11)] C#26[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|}, A#21 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#11)] C#26)]], C#23 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#19)])]} and instantiated rules: (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#19)])]];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#8)])]];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#19)])]];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])]];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#8)])] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#19)])] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#8),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#19),A#22[(app A#23[A#14[(var X#11)]] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] C#24[(var X#19)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|}, C#7 |-> A#22[(app A#23[A#14[(var X#11)]] C#24)], A#21 |-> A#22[(app A#23 C#24[(var X#19)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#8)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#11)] C#24[(var X#8)])] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#19)])] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#22[(app A#23[(var X#11)] C#24)]), ((var X#8),A#22[(app A#23[(var X#11)] C#24)]), ((var X#19),A#22[(app A#23[(var X#11)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|}, A#21 |-> [.], C#7 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#19)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#11)] C#24[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#22[(app A#23[(var X#11)] C#24[(var X#8)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#11)] C#24[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#22)] C#26[(var X#8)])] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(var X#11)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(var X#22)] C#26[(var X#19)])] ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(\ X#9.S#13)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[(var X#22)] C#26)]), ((var X#8),A#24[(app A#25[(var X#22)] C#26)]), ((var X#19),A#24[(app A#25[(var X#22)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] C#26[(var X#19)])];EE#23[X#22,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#11,(var X#19)|}, C#7 |-> A#24[(app A#25[(var X#22)] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#19)])]} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#8)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[(var X#22)] C#26[(var X#19)])];X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(\ X#9.S#13)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#8)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(var X#11)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(\ X#9.S#13)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#23)] C#28)]), ((var X#8),A#26[(app A#27[(var X#23)] C#28)]), ((var X#19),A#26[(app A#27[(var X#23)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] C#28[(var X#19)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#11,(var X#19)|}, C#7 |-> A#26[(app A#27[(var X#23)] C#28)], A#21 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#8);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#8);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#8)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(\ X#9.S#13)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#22= A#24[A#26[(app A#27[(var X#11)] C#28[(var X#8)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#22= A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#21,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#8),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|}, A#21 |-> A#24, C#7 |-> A#24[A#26[(app A#27[(var X#11)] C#28)]], C#25 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#8);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#8);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#8)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#22=A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#22= A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#8)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#22= A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#8),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] C#26[(var X#19)])];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|}, C#7 |-> A#24[(app A#25[A#14[(var X#11)]] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#8);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#8);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#8)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#22=A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#22= A#24[(app A#25[(var X#11)] C#26[(var X#8)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#22= A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[(var X#11)] C#26)]), ((var X#8),A#24[(app A#25[(var X#11)] C#26)]), ((var X#19),A#24[(app A#25[(var X#11)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#2 |-> X#19, X#3 |-> X#8, EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|}, A#21 |-> [.], C#7 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#8);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#8);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#8)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#22=A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#8= (\ X#9.C#21[(var X#3)]) ;E#12 ;EE#20[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#8= (\ X#9.C#21[(var X#10)]) ;E#12 ;EE#20[X#3,A#14[(\ X#9.C#21[(var X#10)])]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#10),(\ X#9.C#21)), ((var X#3),(\ X#9.C#21)), ((var X#10),(\ X#9.C#21[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {[.1]=(var X#3);EE#20[X#3,[.2]]}, X#2 |-> X#10, X#1 |-> X#8, E#4 |-> {E#12;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> (\ X#9.C#21), S#13 |-> C#21[(var X#10)], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#8=(\ X#9.C#21[(var X#10)]);E#12;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#8=(\ X#9.C#21[(var X#3)]);E#12;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#8=(\ X#9.C#21[(var X#10)]);E#12;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#8=(\ X#9.C#21[(var X#10)]);E#12;EE#20[X#3,A#14[(\ X#9.C#21[(var X#10)])]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#10= (var X#3) ;X#8= (\ X#9.S#13) ;E#21 ;EE#20[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#10)] ;X#10= (var X#3) ;X#8= (\ X#9.S#13) ;E#21 ;EE#20[X#3,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#10),C#7), ((var X#3),C#7), ((var X#10),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {[.1]=(var X#3);EE#20[X#3,[.2]]}, X#2 |-> X#10, E#12 |-> {X#1=C#7[(var X#10)];E#21}, E#4 |-> {X#8=(\ X#9.S#13);E#21;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#10)];X#10=(var X#3);X#8=(\ X#9.S#13);E#21;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#10=(var X#3);X#8=(\ X#9.S#13);E#21;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#10)];X#10=(var X#3);X#8=(\ X#9.S#13);E#21;EE#20[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#10)];X#10=(var X#3);X#8=(\ X#9.S#13);E#21;EE#20[X#3,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#22[A#24[(app A#25[(var X#11)] C#26[(var X#3)])]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#10)])]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#23,A#21,C#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#10),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#3),A#22[A#24[(app A#25[(var X#11)] C#26)]]), ((var X#10),A#22[A#24[(app A#25[(var X#11)] C#26[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#10)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#3=A#22[[.2]];[.1]=(var X#3)}, X#2 |-> X#10, EE#20[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> A#22, C#7 |-> A#22[A#24[(app A#25[(var X#11)] C#26)]], A#18 |-> [.], X#19 |-> X#3, C#23 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#10)])]} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#10)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#3)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#22[A#24[(app A#25[(var X#11)] C#26[(var X#10)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#3=A#22[A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#10)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#10)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#10),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#3),A#22[(app A#23[A#14[(var X#11)]] C#24)]), ((var X#10),A#22[(app A#23[A#14[(var X#11)]] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#3=A#22[(app A#23[[.2]] C#24[(var X#10)])];[.1]=(var X#3)}, X#2 |-> X#10, EE#20[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] C#24[(var X#10)])]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, C#7 |-> A#22[(app A#23[A#14[(var X#11)]] C#24)], A#21 |-> A#22[(app A#23 C#24[(var X#10)])], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#10)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#3)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#22[(app A#23[A#14[(var X#11)]] C#24[(var X#10)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#3=A#22[(app A#23[A#14[(\ X#9.S#13)]] C#24[(var X#10)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#22[(app A#23[(var X#11)] C#24[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#10)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#10),A#22[(app A#23[(var X#11)] C#24)]), ((var X#3),A#22[(app A#23[(var X#11)] C#24)]), ((var X#10),A#22[(app A#23[(var X#11)] C#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] C#24[(var X#10)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#10, EE#20[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> [.], C#7 |-> A#22[(app A#23[(var X#11)] C#24)], A#14 |-> A#22[(app A#23 C#24[(var X#10)])], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#11)] C#24[(var X#10)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#11)] C#24[(var X#3)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(var X#11)] C#24[(var X#10)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#3=A#22[(app A#23[(\ X#9.S#13)] C#24[(var X#10)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#3= A#24[(app A#25[(var X#22)] C#26[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#3= A#24[(app A#25[(var X#22)] C#26[(var X#10)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#10),A#24[(app A#25[(var X#22)] C#26)]), ((var X#3),A#24[(app A#25[(var X#22)] C#26)]), ((var X#10),A#24[(app A#25[(var X#22)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#3=A#24[(app A#25[(var X#22)] C#26[(var X#10)])];[.1]=(var X#3);EE#23[X#22,[.2]]}, X#2 |-> X#10, EE#20[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] C#26[(var X#10)])];EE#23[X#22,[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#24[(app A#25[(var X#22)] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#10)])], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#3=A#24[(app A#25[(var X#22)] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#3,(var X#22)] ;EE#25[X#23,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#22= A#26[(app A#27[(var X#23)] C#28[(var X#10)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#3,(var X#22)] ;EE#25[X#23,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#10),A#26[(app A#27[(var X#23)] C#28)]), ((var X#3),A#26[(app A#27[(var X#23)] C#28)]), ((var X#10),A#26[(app A#27[(var X#23)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] C#28[(var X#10)])];[.1]=(var X#3);EE#24[X#3,(var X#22)];EE#25[X#23,[.2]]}, X#2 |-> X#10, EE#20[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] C#28[(var X#10)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#24[X#3,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#26[(app A#27[(var X#23)] C#28)], A#21 |-> A#26[(app A#27 C#28[(var X#10)])], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#24[X#3,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#24[X#3,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#24[X#3,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#22=A#26[(app A#27[(var X#23)] C#28[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#24[X#3,(var X#22)];EE#25[X#23,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#22= A#24[A#26[(app A#27[(var X#11)] C#28[(var X#3)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#3,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#22= A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#10)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#3,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#21,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#10),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#3),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#10),A#24[A#26[(app A#27[(var X#11)] C#28[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#10)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#22=A#24[[.2]];[.1]=(var X#3);EE#23[X#3,(var X#22)]}, X#2 |-> X#10, EE#20[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> A#24, C#7 |-> A#24[A#26[(app A#27[(var X#11)] C#28)]], A#18 |-> [.], X#19 |-> X#3, C#25 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#10)])]} and instantiated rules: (letrec {X#10=(var X#3);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#10)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#3)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#22=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#10)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#22=A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#10)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#22= A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#3,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#22= A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#10)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#3,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,C#7,A#14} Delta2 = {} Delta3 = {((var X#10),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#3),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#10),A#24[(app A#25[A#14[(var X#11)]] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] C#26[(var X#10)])];[.1]=(var X#3);EE#23[X#3,(var X#22)]}, X#2 |-> X#10, EE#20[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] C#26[(var X#10)])];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|}, C#7 |-> A#24[(app A#25[A#14[(var X#11)]] C#26)], A#21 |-> A#24[(app A#25 C#26[(var X#10)])], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#22=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#22=A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#22= A#24[(app A#25[(var X#11)] C#26[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#3,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#3) ;X#22= A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#10)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#3,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#10),A#24[(app A#25[(var X#11)] C#26)]), ((var X#3),A#24[(app A#25[(var X#11)] C#26)]), ((var X#10),A#24[(app A#25[(var X#11)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#10)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#22=[.2];[.1]=(var X#3);EE#23[X#3,(var X#22)]}, X#2 |-> X#10, EE#20[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> [.], C#7 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#10)])], A#18 |-> [.], X#19 |-> X#3} and instantiated rules: (letrec {X#10=(var X#3);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#3);X#22=A#24[(app A#25[(var X#11)] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#3);X#22=A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#10)])];X#8=(\ X#9.S#13);E#12;EE#23[X#3,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#8= (\ X#9.C#23[(var X#3)]) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#22[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#8= (\ X#9.C#23[(var X#19)]) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#22[X#3,A#14[(\ X#9.C#23[(var X#19)])]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),(\ X#9.C#23)), ((var X#3),(\ X#9.C#23)), ((var X#19),(\ X#9.C#23[[.]])), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);EE#21[[.1],(var X#19)];EE#22[X#3,[.2]]}, X#2 |-> X#19, X#1 |-> X#8, E#4 |-> {E#12;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> (\ X#9.C#23), S#13 |-> C#23[(var X#19)], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#8=(\ X#9.C#23[(var X#19)]);E#12;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#8=(\ X#9.C#23[(var X#3)]);E#12;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#8=(\ X#9.C#23[(var X#19)]);E#12;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#8=(\ X#9.C#23[(var X#19)]);E#12;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(\ X#9.C#23[(var X#19)])]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#23 ;EE#21[X#10,(var X#19)] ;EE#22[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#1= C#7[(var X#19)] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#23 ;EE#21[X#10,(var X#19)] ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),C#7), ((var X#3),C#7), ((var X#19),C#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);EE#21[[.1],(var X#19)];EE#22[X#3,[.2]]}, X#2 |-> X#19, E#12 |-> {X#1=C#7[(var X#19)];E#23}, E#4 |-> {X#8=(\ X#9.S#13);E#23;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#23;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#19=(var X#3);X#8=(\ X#9.S#13);E#23;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=C#7[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#23;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=C#7[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#23;EE#21[X#10,(var X#19)];EE#22[X#3,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(var X#3)] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(var X#19)] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24[[.]]), ((var X#3),A#24[[.]]), ((var X#19),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);[.1]=A#24[(var X#19)];EE#22[X#3,[.2]]}, X#2 |-> X#19, EE#21[.1,.2] |-> {[.1]=A#24[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, A#23 |-> A#24, C#7 |-> A#24[[.]], A#18 |-> [.], X#20 |-> X#3, C#25 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=A#24[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(var X#3)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(var X#3)] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(var X#19)] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24), ((var X#3),A#24), ((var X#19),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);[.1]=A#24[(var X#19)];EE#22[X#3,[.2]]}, X#2 |-> X#19, EE#21[.1,.2] |-> {[.1]=A#24[[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, A#23 |-> A#24[[.]], C#7 |-> A#24, A#18 |-> [.], X#20 |-> X#3, A#25 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=A#24[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(var X#3)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(var X#19)];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#19)] C#26[(var X#3)])] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(var X#19)] C#26[(var X#19)])] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[(var X#19)] C#26)]), ((var X#3),A#24[(app A#25[(var X#19)] C#26)]), ((var X#19),A#24[(app A#25[(var X#19)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);[.1]=A#24[(app A#25[(var X#19)] C#26[(var X#19)])];EE#22[X#3,[.2]]}, X#2 |-> X#19, EE#21[.1,.2] |-> {[.1]=A#24[(app A#25[[.2]] C#26[(var X#19)])]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#24[(app A#25[(var X#19)] C#26)], A#23 |-> A#24[(app A#25 C#26[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#19)] C#26[(var X#19)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#24[(app A#25[(var X#19)] C#26[(var X#3)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#19)] C#26[(var X#19)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[(var X#19)] C#26[(var X#19)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#3) ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#19) ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#3),[.]), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);[.1]=(var X#19);EE#22[X#3,[.2]]}, X#2 |-> X#19, EE#21[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> [.], A#23 |-> [.], X#19 |-> X#19, A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#10=(var X#19);X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=(var X#3);X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#19);X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#19);X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#26[(app A#27[(var X#24)] C#28[(var X#3)])] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;EE#25[X#24,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#26[(app A#27[(var X#24)] C#28[(var X#19)])] ;X#19= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;EE#25[X#24,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#24)] C#28)]), ((var X#3),A#26[(app A#27[(var X#24)] C#28)]), ((var X#19),A#26[(app A#27[(var X#24)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);[.1]=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];EE#22[X#3,[.2]];EE#25[X#24,(var X#19)]}, X#2 |-> X#19, EE#21[.1,.2] |-> {[.1]=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];EE#25[X#24,[.2]]}, X#1 |-> X#10, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#24,(var X#19)];VV#17|X#11,(var X#8)|}, C#7 |-> A#26[(app A#27[(var X#24)] C#28)], A#23 |-> A#26[(app A#27 C#28[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#24,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#3)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#24,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#24,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#19=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];EE#25[X#24,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#28[(app A#29[(var X#25)] C#30[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;EE#26[X#10,(var X#24)] ;EE#27[X#25,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#28[(app A#29[(var X#25)] C#30[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;EE#26[X#10,(var X#24)] ;EE#27[X#25,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#28[(app A#29[(var X#25)] C#30)]), ((var X#3),A#28[(app A#29[(var X#25)] C#30)]), ((var X#19),A#28[(app A#29[(var X#25)] C#30[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];EE#22[X#3,[.2]];EE#26[[.1],(var X#24)];EE#27[X#25,(var X#19)]}, X#2 |-> X#19, EE#21[.1,.2] |-> {X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];EE#26[[.1],(var X#24)];EE#27[X#25,[.2]]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#26[X#10,(var X#24)];EE#27[X#25,(var X#19)];VV#17|X#11,(var X#8)|}, C#7 |-> A#28[(app A#29[(var X#25)] C#30)], A#23 |-> A#28[(app A#29 C#30[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#26[X#10,(var X#24)];EE#27[X#25,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#26[X#10,(var X#24)];EE#27[X#25,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#26[X#10,(var X#24)];EE#27[X#25,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];EE#26[X#10,(var X#24)];EE#27[X#25,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#26[(var X#3)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#26[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14,A#26} Delta2 = {} Delta3 = {((var X#19),A#26[[.]]), ((var X#3),A#26[[.]]), ((var X#19),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#26[(var X#19)];EE#22[X#3,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, EE#21[.1,.2] |-> {X#24=A#26[[.2]];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, A#23 |-> A#26, C#7 |-> A#26[[.]], A#18 |-> [.], X#20 |-> X#3, C#27 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#26[(var X#3)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#26[(var X#3)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#26[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14,A#26} Delta2 = {} Delta3 = {((var X#19),A#26), ((var X#3),A#26), ((var X#19),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#26[(var X#19)];EE#22[X#3,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, EE#21[.1,.2] |-> {X#24=A#26[[.2]];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, A#23 |-> A#26[[.]], C#7 |-> A#26, A#18 |-> [.], X#20 |-> X#3, A#27 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#26[(var X#3)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#26[(app A#27[(var X#19)] C#28[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#26[(app A#27[(var X#19)] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#19)] C#28)]), ((var X#3),A#26[(app A#27[(var X#19)] C#28)]), ((var X#19),A#26[(app A#27[(var X#19)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#26[(app A#27[(var X#19)] C#28[(var X#19)])];EE#22[X#3,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, EE#21[.1,.2] |-> {X#24=A#26[(app A#27[[.2]] C#28[(var X#19)])];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, C#7 |-> A#26[(app A#27[(var X#19)] C#28)], A#23 |-> A#26[(app A#27 C#28[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#19)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#19)] C#28[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#19)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#19)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= (var X#3) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#3,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#3),[.]), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=(var X#19);EE#22[X#3,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, EE#21[.1,.2] |-> {X#24=[.2];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, C#7 |-> [.], A#23 |-> [.], X#19 |-> X#19, A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=(var X#3);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#22[X#3,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#3= A#24[A#26[(app A#27[(var X#11)] C#28[(var X#3)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#3= A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#25,A#23,C#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#3),A#24[A#26[(app A#27[(var X#11)] C#28)]]), ((var X#19),A#24[A#26[(app A#27[(var X#11)] C#28[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#3=A#24[[.2]];EE#21[[.1],(var X#19)]}, X#2 |-> X#19, EE#22[.1,.2] |-> {[.1]=A#24[[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|}, A#23 |-> A#24, C#7 |-> A#24[A#26[(app A#27[(var X#11)] C#28)]], A#18 |-> [.], X#20 |-> X#3, C#25 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#3);X#3=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#3=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#3)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#3=A#24[A#26[(app A#27[(var X#11)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#3=A#24[A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#3= A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#3= A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#3),A#24[(app A#25[A#14[(var X#11)]] C#26)]), ((var X#19),A#24[(app A#25[A#14[(var X#11)]] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#3=A#24[(app A#25[[.2]] C#26[(var X#19)])];EE#21[[.1],(var X#19)]}, X#2 |-> X#19, EE#22[.1,.2] |-> {[.1]=A#24[(app A#25[[.2]] C#26[(var X#19)])]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|}, C#7 |-> A#24[(app A#25[A#14[(var X#11)]] C#26)], A#23 |-> A#24[(app A#25 C#26[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#3=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#3=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#3=A#24[(app A#25[A#14[(var X#11)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#3=A#24[(app A#25[A#14[(\ X#9.S#13)]] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#3= A#24[(app A#25[(var X#11)] C#26[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#3= A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#24[(app A#25[(var X#11)] C#26)]), ((var X#3),A#24[(app A#25[(var X#11)] C#26)]), ((var X#19),A#24[(app A#25[(var X#11)] C#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] C#26[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#3=[.2];EE#21[[.1],(var X#19)]}, X#2 |-> X#19, EE#22[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|}, A#23 |-> [.], C#7 |-> A#24[(app A#25[(var X#11)] C#26)], A#14 |-> A#24[(app A#25 C#26[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#3=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#3=A#24[(app A#25[(var X#11)] C#26[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#3=A#24[(app A#25[(var X#11)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#3=A#24[(app A#25[(\ X#9.S#13)] C#26[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#3= A#26[(app A#27[(var X#24)] C#28[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#24,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#3= A#26[(app A#27[(var X#24)] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#24,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#24)] C#28)]), ((var X#3),A#26[(app A#27[(var X#24)] C#28)]), ((var X#19),A#26[(app A#27[(var X#24)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#3=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];EE#21[[.1],(var X#19)];EE#25[X#24,[.2]]}, X#2 |-> X#19, EE#22[.1,.2] |-> {[.1]=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];EE#25[X#24,[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#24,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#26[(app A#27[(var X#24)] C#28)], A#23 |-> A#26[(app A#27 C#28[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#3=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#24,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#3=A#26[(app A#27[(var X#24)] C#28[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#24,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#3=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#24,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#3=A#26[(app A#27[(var X#24)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#24,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#28[(app A#29[(var X#25)] C#30[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#26[X#3,(var X#24)] ;EE#27[X#25,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#28[(app A#29[(var X#25)] C#30[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#26[X#3,(var X#24)] ;EE#27[X#25,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#28[(app A#29[(var X#25)] C#30)]), ((var X#3),A#28[(app A#29[(var X#25)] C#30)]), ((var X#19),A#28[(app A#29[(var X#25)] C#30[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];EE#21[[.1],(var X#19)];EE#26[X#3,(var X#24)];EE#27[X#25,[.2]]}, X#2 |-> X#19, EE#22[.1,.2] |-> {X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];EE#26[[.1],(var X#24)];EE#27[X#25,[.2]]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#26[X#3,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, C#7 |-> A#28[(app A#29[(var X#25)] C#30)], A#23 |-> A#28[(app A#29 C#30[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#26[X#3,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#26[X#3,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#26[X#3,(var X#24)];EE#27[X#25,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#28[(app A#29[(var X#25)] C#30[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#26[X#3,(var X#24)];EE#27[X#25,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#26[A#28[(app A#29[(var X#11)] C#30[(var X#3)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#3,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#26[A#28[(app A#29[(\ X#9.S#13)] C#30[(var X#19)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#3,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#27,A#23,C#7,A#14,A#26} Delta2 = {} Delta3 = {((var X#19),A#26[A#28[(app A#29[(var X#11)] C#30)]]), ((var X#3),A#26[A#28[(app A#29[(var X#11)] C#30)]]), ((var X#19),A#26[A#28[(app A#29[(var X#11)] C#30[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#28[(app A#29[[.]] C#30[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#26[[.2]];EE#21[[.1],(var X#19)];EE#25[X#3,(var X#24)]}, X#2 |-> X#19, EE#22[.1,.2] |-> {X#24=A#26[[.2]];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|}, A#23 |-> A#26, C#7 |-> A#26[A#28[(app A#29[(var X#11)] C#30)]], A#18 |-> [.], X#20 |-> X#3, C#27 |-> A#28[(app A#29[(var X#11)] C#30)], A#14 |-> A#28[(app A#29 C#30[(var X#19)])]} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#26[A#28[(app A#29[(var X#11)] C#30[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#26[A#28[(app A#29[(var X#11)] C#30[(var X#3)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#26[A#28[(app A#29[(var X#11)] C#30[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#26[A#28[(app A#29[(\ X#9.S#13)] C#30[(var X#19)])]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#3,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#26[(app A#27[A#14[(\ X#9.S#13)]] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#3,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[A#14[(var X#11)]] C#28)]), ((var X#3),A#26[(app A#27[A#14[(var X#11)]] C#28)]), ((var X#19),A#26[(app A#27[A#14[(var X#11)]] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=A#26[(app A#27[[.2]] C#28[(var X#19)])];EE#21[[.1],(var X#19)];EE#25[X#3,(var X#24)]}, X#2 |-> X#19, EE#22[.1,.2] |-> {X#24=A#26[(app A#27[[.2]] C#28[(var X#19)])];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|}, C#7 |-> A#26[(app A#27[A#14[(var X#11)]] C#28)], A#23 |-> A#26[(app A#27 C#28[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#26[(app A#27[A#14[(var X#11)]] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#26[(app A#27[A#14[(\ X#9.S#13)]] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#3) ;X#24= A#26[(app A#27[(var X#11)] C#28[(var X#3)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#3,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= (var X#3) ;X#24= A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#19)] ;EE#25[X#3,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {C#7,A#14} Delta2 = {} Delta3 = {((var X#19),A#26[(app A#27[(var X#11)] C#28)]), ((var X#3),A#26[(app A#27[(var X#11)] C#28)]), ((var X#19),A#26[(app A#27[(var X#11)] C#28[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] C#28[(var X#19)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#2),C#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=(var X#3);X#24=[.2];EE#21[[.1],(var X#19)];EE#25[X#3,(var X#24)]}, X#2 |-> X#19, EE#22[.1,.2] |-> {X#24=[.2];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#4 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|}, A#23 |-> [.], C#7 |-> A#26[(app A#27[(var X#11)] C#28)], A#14 |-> A#26[(app A#27 C#28[(var X#19)])], A#18 |-> [.], X#20 |-> X#3} and instantiated rules: (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#11)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-cpx-e1- (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#11)] C#28[(var X#3)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(var X#11)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#3);X#24=A#26[(app A#27[(\ X#9.S#13)] C#28[(var X#19)])];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#19)];EE#25[X#3,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec E#8 in (letrec {E#9} in T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ) , (letrec E#8 ;E#9 in T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ) ) where Delta1 = {T#11,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), [{E#8},(letrec {E#9} in [.])], ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),[{E#8},(letrec {E#9} in [.])],((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (letrec {E#9} in T#12)), T#11 |-> (letrec {E#9} in T#12), S#10 |-> T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) <-cpx-e1- (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])) ................................................................................ (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) -SR,llet-in1-> (letrec {E#8;E#9} in T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) ================================================================================ Critical Pair: ( (letrec E#8 in (letrec X#13= T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#15 in S#10 ) ) , (letrec X#13= T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#15 ;E#8 in S#10 ) ) where Delta1 = {T#11,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), [{E#8},(letrec {X#13=T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#15} in [.])], ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),[{E#8},(letrec {E#9} in [.])],((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (letrec {X#13=T#12;E#15} in S#10)), T#11 |-> (letrec {X#13=T#12;E#15} in S#10), E#9 |-> {X#13=T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#8} in (letrec {X#13=T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#15} in S#10)) <-cpx-e1- (letrec {E#8} in (letrec {X#13=T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#15} in S#10)) ................................................................................ (letrec {E#8} in (letrec {X#13=T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#15} in S#10)) -SR,llet-in1-> (letrec {X#13=T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#15;E#8} in S#10) ================================================================================ Critical Pair: ( (letrec {E#8} in (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#13} in S#10)) , (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#13;E#8} in S#10) ) where Delta1 = {T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), [{E#8},(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#13} in [.])], ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),[{E#8},(letrec {E#9} in [.])],((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in [.]), T#11 |-> [.], S#5 |-> S#10, E#9 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#13}, E#12 |-> {X#1=C#7[(var X#2)];E#13}, E#4 |-> {E#13}} and instantiated rules: (letrec {E#8} in (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#13} in S#10)) <-cpx-e1- (letrec {E#8} in (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#13} in S#10)) ................................................................................ (letrec {E#8} in (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#13} in S#10)) -SR,llet-in1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#13;E#8} in S#10) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#14 in (letrec {E#9} in S#10) ) , (letrec X#12= T#11[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#14 ;E#9 in S#10 ) ) where Delta1 = {T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), [{X#12=T#11[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#14},(letrec {E#9} in [.])], ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),[{E#8},(letrec {E#9} in [.])],((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#12=T#11;E#14} in (letrec {E#9} in S#10)), E#8 |-> {X#12=T#11[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#14} in (letrec {E#9} in S#10)) <-cpx-e1- (letrec {X#12=T#11[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#14} in (letrec {E#9} in S#10)) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#14} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {X#12=T#11[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#14;E#9} in S#10) ================================================================================ Critical Pair: ( (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#12} in (letrec {E#9} in S#10)) , (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#12;E#9} in S#10) ) where Delta1 = {} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), [{X#1=C#7[(var X#2)];X#2=(var X#3);E#12},(letrec {E#9} in [.])], ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),[{E#8},(letrec {E#9} in [.])],((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> (letrec {E#9} in S#10), E#8 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#12}, E#11 |-> {X#1=C#7[(var X#2)];E#12}, E#4 |-> {E#12}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#12} in (letrec {E#9} in S#10)) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#12} in (letrec {E#9} in S#10)) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#12} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#12;E#9} in S#10) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#9} in S#11) ;E#10 in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec X#8= S#11 ;E#10 ;E#9 in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])],(letrec {E#9} in [.])), [{E#10},(letrec {E#9} in [.])], ((var X#2),C#7[[.]]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16)]), T#13 |-> A#14[(app A#15[(var X#8)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#9} in T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ;E#10 in A#12[(var X#8)] ) , (letrec X#8= T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#10 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10},(letrec {E#9} in [.])], ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#9} in T#16);E#10} in A#12[(var X#8)]), X#14 |-> X#8, E#15 |-> {E#10}, T#13 |-> (letrec {E#9} in T#16), S#11 |-> T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=(letrec {E#9} in T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#10} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#8=(letrec {E#9} in T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#8=(letrec {E#9} in T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec X#17= T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#19 in S#11 ) ;E#10 in A#12[(var X#8)] ) , (letrec X#17= T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= S#11 ;E#10 ;E#19 in A#12[(var X#8)] ) ) where Delta1 = {T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (A#12[(var X#8)],(letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#19} in [.])), [{E#10},(letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#19} in [.])], ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {X#17=T#16;E#19} in S#11);E#10} in A#12[(var X#8)]), X#14 |-> X#8, E#15 |-> {E#10}, T#13 |-> (letrec {X#17=T#16;E#19} in S#11), E#9 |-> {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#8=(letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#19} in S#11);E#10} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#8=(letrec {X#17=T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#19} in S#11);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#8=(letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#19} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#17=T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=S#11;E#10;E#19} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#17} in S#11) ;E#10 in A#12[(var X#8)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= S#11 ;E#10 ;E#17 in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (A#12[(var X#8)],(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#17} in [.])), [{E#10},(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#17} in [.])], ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=[.];E#10} in A#12[(var X#8)]), X#14 |-> X#8, E#15 |-> {E#10}, T#13 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#17}, E#16 |-> {X#1=C#7[(var X#2)];E#17}, E#4 |-> {E#17}} and instantiated rules: (letrec {X#8=(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#17} in S#11);E#10} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#8=(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#17} in S#11);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#8=(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#17} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=S#11;E#10;E#17} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;X#8= (letrec {E#9} in S#11) ;E#16 in A#12[(var X#8)] ) , (letrec X#14= T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= S#11 ;E#16 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16},(letrec {E#9} in [.])], ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]), E#10 |-> {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16}, E#15 |-> {X#8=(letrec {E#9} in S#11);E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=S#11;E#16;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (letrec {E#9} in C#14[(var X#3)]) ;E#13 in A#12[(var X#8)] ) , (letrec {X#2=(var X#3);X#8=C#14[(var X#2)];E#13;E#9} in A#12[(var X#8)]) ) where Delta1 = {C#7} Delta2 = {E#9} Delta3 = {((var X#2),(letrec {E#9} in C#14)), ((var X#3),(letrec {E#9} in C#14)), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#2=(var X#3);E#13},(letrec {E#9} in [.])], ((var X#2),(letrec {E#9} in C#14[[.]])), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#3);E#13}, X#1 |-> X#8, E#4 |-> {E#13}, C#7 |-> (letrec {E#9} in C#14), S#11 |-> C#14[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(letrec {E#9} in C#14[(var X#2)]);E#13} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(letrec {E#9} in C#14[(var X#3)]);E#13} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(letrec {E#9} in C#14[(var X#2)]);E#13} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#2=(var X#3);X#8=C#14[(var X#2)];E#13;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (letrec {X#15=C#14[(var X#3)];E#17} in S#11) ;E#13 in A#12[(var X#8)] ) , (letrec X#15= C#14[(var X#2)] ;X#2= (var X#3) ;X#8= S#11 ;E#13 ;E#17 in A#12[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#9} Delta3 = {((var X#2),(letrec {X#15=C#14;E#17} in S#11)), ((var X#3),(letrec {X#15=C#14;E#17} in S#11)), (A#12[(var X#8)],(letrec {X#15=C#14[(var X#2)];E#17} in [.])), [{X#2=(var X#3);E#13},(letrec {X#15=C#14[(var X#2)];E#17} in [.])], ((var X#2),(letrec {X#15=C#14[[.]];E#17} in S#11)), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#3);E#13}, X#1 |-> X#8, E#4 |-> {E#13}, C#7 |-> (letrec {X#15=C#14;E#17} in S#11), E#9 |-> {X#15=C#14[(var X#2)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#2=(var X#3);X#8=(letrec {X#15=C#14[(var X#2)];E#17} in S#11);E#13} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(letrec {X#15=C#14[(var X#3)];E#17} in S#11);E#13} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(letrec {X#15=C#14[(var X#2)];E#17} in S#11);E#13} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#15=C#14[(var X#2)];X#2=(var X#3);X#8=S#11;E#13;E#17} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;X#8= (letrec {E#9} in S#11) ;E#14 in A#12[(var X#8)] ) , (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=S#11;E#14;E#9} in A#12[(var X#8)]) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#1=C#7[(var X#2)];X#2=(var X#3);E#14},(letrec {E#9} in [.])], ((var X#2),C#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),C#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#14}, E#13 |-> {X#1=C#7[(var X#2)];E#14}, E#4 |-> {X#8=(letrec {E#9} in S#11);E#14}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=S#11;E#14;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;E#11 ;EE#14[X#9,(var X#8)] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec X#8= S#12 ;E#10 ;E#11 ;EE#14[X#9,(var X#8)] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])],(letrec {E#10} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),[.]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18)]), T#15 |-> A#16[(app A#17[(var X#9)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#8= T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#10 ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in T#18);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), X#16 |-> X#8, E#17 |-> {E#11;EE#14[X#9,(var X#8)]}, T#15 |-> (letrec {E#10} in T#18), S#12 |-> T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=(letrec {E#10} in T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {E#10} in T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec X#19= T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#21 in S#12 ) ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#19= T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= S#12 ;E#11 ;E#21 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#11;E#21;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#21} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#21} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {X#19=T#18;E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), X#16 |-> X#8, E#17 |-> {E#11;EE#14[X#9,(var X#8)]}, T#15 |-> (letrec {X#19=T#18;E#21} in S#12), E#10 |-> {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#8=(letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {X#19=T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=S#12;E#11;E#21;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#19} in S#12) ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= S#12 ;E#11 ;E#19 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#11;E#19;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#19} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#19} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=[.];E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), X#16 |-> X#8, E#17 |-> {E#11;EE#14[X#9,(var X#8)]}, T#15 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#19}, E#18 |-> {X#1=C#7[(var X#2)];E#19}, E#4 |-> {E#19}} and instantiated rules: (letrec {X#8=(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#19} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#19} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#19} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=S#12;E#11;E#19;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;X#8= (letrec {E#10} in S#12) ;E#18 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;X#8= S#12 ;E#10 ;E#18 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#10;E#18;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), E#11 |-> {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18}, E#17 |-> {X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];X#8=S#12;E#10;E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#11 in A#13[(var X#9)] ) , (letrec X#8= S#12 ;X#9= A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21)];E#11} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]}, X#16 |-> X#9, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11}, T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#11 ;EE#20[X#19,(var X#8)] in A#13[(var X#9)] ) , (letrec X#8= S#12 ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#10 ;E#11 ;EE#20[X#19,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;E#11;EE#20[X#19,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11;EE#20[X#19,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23)];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#9, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#19,(var X#8)]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,(var X#8)] in A#13[(var X#9)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=S#12;E#10;E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];X#8=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (letrec {E#10} in C#16[(var X#3)]) ;E#15 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#2= (var X#3) ;X#8= C#16[(var X#2)] ;E#10 ;E#15 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#2),(letrec {E#10} in C#16)), ((var X#3),(letrec {E#10} in C#16)), ((var X#8),(letrec {X#2=(var X#3);E#10;E#15;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=(var X#3);E#15;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),(letrec {E#10} in C#16[[.]])), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=(var X#3);E#15}, X#1 |-> X#8, E#4 |-> {E#15;EE#14[X#9,(var X#8)]}, C#7 |-> (letrec {E#10} in C#16), S#12 |-> C#16[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(letrec {E#10} in C#16[(var X#2)]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(letrec {E#10} in C#16[(var X#3)]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(letrec {E#10} in C#16[(var X#2)]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#2=(var X#3);X#8=C#16[(var X#2)];E#10;E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (letrec {X#17=C#16[(var X#3)];E#19} in S#12) ;E#15 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#17= C#16[(var X#2)] ;X#2= (var X#3) ;X#8= S#12 ;E#15 ;E#19 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#2),(letrec {X#17=C#16;E#19} in S#12)), ((var X#3),(letrec {X#17=C#16;E#19} in S#12)), ((var X#8),(letrec {X#17=C#16[(var X#2)];X#2=(var X#3);E#15;E#19;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#17=C#16[(var X#2)];E#19} in [.])), [{X#2=(var X#3);E#15;EE#14[X#9,(var X#8)]},(letrec {X#17=C#16[(var X#2)];E#19} in [.])], ((var X#2),(letrec {X#17=C#16[[.]];E#19} in S#12)), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=(var X#3);E#15}, X#1 |-> X#8, E#4 |-> {E#15;EE#14[X#9,(var X#8)]}, C#7 |-> (letrec {X#17=C#16;E#19} in S#12), E#10 |-> {X#17=C#16[(var X#2)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#2=(var X#3);X#8=(letrec {X#17=C#16[(var X#2)];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(letrec {X#17=C#16[(var X#3)];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(letrec {X#17=C#16[(var X#2)];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=C#16[(var X#2)];X#2=(var X#3);X#8=S#12;E#15;E#19;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;X#8= (letrec {E#10} in S#12) ;E#16 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;X#8= S#12 ;E#10 ;E#16 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#10;E#16;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#16}, E#15 |-> {X#1=C#7[(var X#2)];E#16}, E#4 |-> {X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);X#8=S#12;E#10;E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= A#17[(app A#18[(var X#8)] C#19[(var X#3)])] ;E#15 in A#13[(var X#9)] ) , (letrec X#2= (var X#3) ;X#8= S#12 ;X#9= A#17[(app A#18[(var X#8)] C#19[(var X#2)])] ;E#10 ;E#15 in A#13[(var X#9)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app A#18[(var X#8)] C#19)]), ((var X#3),A#17[(app A#18[(var X#8)] C#19)]), ((var X#8),(letrec {X#2=(var X#3);X#9=A#17[(app A#18[(var X#8)] C#19[(var X#2)])];E#10;E#15} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=(var X#3);X#9=A#17[(app A#18[(var X#8)] C#19[(var X#2)])];E#15},(letrec {E#10} in [.])], ((var X#2),A#17[(app A#18[(var X#8)] C#19[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] C#19[(var X#2)])]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#15}, C#7 |-> A#17[(app A#18[(var X#8)] C#19)], A#16 |-> A#17[(app A#18 C#19[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] C#19[(var X#2)])];E#15} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] C#19[(var X#3)])];E#15} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] C#19[(var X#2)])];E#15} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#2=(var X#3);X#8=S#12;X#9=A#17[(app A#18[(var X#8)] C#19[(var X#2)])];E#10;E#15} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= A#19[(app A#20[(var X#17)] C#21[(var X#3)])] ;E#15 ;EE#18[X#17,(var X#8)] in A#13[(var X#9)] ) , (letrec X#2= (var X#3) ;X#8= S#12 ;X#9= A#19[(app A#20[(var X#17)] C#21[(var X#2)])] ;E#10 ;E#15 ;EE#18[X#17,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(var X#17)] C#21)]), ((var X#3),A#19[(app A#20[(var X#17)] C#21)]), ((var X#8),(letrec {X#2=(var X#3);X#9=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#10;E#15;EE#18[X#17,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=(var X#3);X#9=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),A#19[(app A#20[(var X#17)] C#21[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];EE#18[X#17,[.2]]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#15;EE#18[X#17,(var X#8)]}, C#7 |-> A#19[(app A#20[(var X#17)] C#21)], A#16 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] C#21[(var X#3)])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#2=(var X#3);X#8=S#12;X#9=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#10;E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] C#23[(var X#3)])] ;X#2= (var X#3) ;X#8= (letrec {E#10} in S#12) ;E#15 ;EE#19[X#9,(var X#17)] ;EE#20[X#18,(var X#8)] in A#13[(var X#9)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] C#23[(var X#2)])] ;X#2= (var X#3) ;X#8= S#12 ;E#10 ;E#15 ;EE#19[X#9,(var X#17)] ;EE#20[X#18,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#21[(app A#22[(var X#18)] C#23)]), ((var X#3),A#21[(app A#22[(var X#18)] C#23)]), ((var X#8),(letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#10;E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),A#21[(app A#22[(var X#18)] C#23[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, E#4 |-> {X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]}, C#7 |-> A#21[(app A#22[(var X#18)] C#23)], A#16 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#3)])];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);X#8=S#12;E#10;E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#8)] C#21[(var X#3)])] ;X#2= (var X#3) ;X#8= (letrec {E#10} in S#12) ;E#15 ;EE#18[X#9,(var X#17)] in A#13[(var X#9)] ) , (letrec X#17= A#19[(app A#20[(var X#8)] C#21[(var X#2)])] ;X#2= (var X#3) ;X#8= S#12 ;E#10 ;E#15 ;EE#18[X#9,(var X#17)] in A#13[(var X#9)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(var X#8)] C#21)]), ((var X#3),A#19[(app A#20[(var X#8)] C#21)]), ((var X#8),(letrec {X#17=A#19[(app A#20[(var X#8)] C#21[(var X#2)])];X#2=(var X#3);E#10;E#15;EE#18[X#9,(var X#17)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#17=A#19[(app A#20[(var X#8)] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#9,(var X#17)]},(letrec {E#10} in [.])], ((var X#2),A#19[(app A#20[(var X#8)] C#21[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] C#21[(var X#2)])];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]}, C#7 |-> A#19[(app A#20[(var X#8)] C#21)], A#16 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#8)] C#21[(var X#2)])];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#17=A#19[(app A#20[(var X#8)] C#21[(var X#3)])];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#8)] C#21[(var X#2)])];X#2=(var X#3);X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=A#19[(app A#20[(var X#8)] C#21[(var X#2)])];X#2=(var X#3);X#8=S#12;E#10;E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#3= (letrec {E#10} in C#16[(var X#3)]) ;X#9= (var X#3) ;E#11 in A#13[(var X#9)] ) , (letrec {X#3=C#16[(var X#9)];X#9=(var X#3);E#10;E#11} in A#13[(var X#9)]) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#9),(letrec {E#10} in C#16)), ((var X#3),(letrec {E#10} in C#16)), ((var X#3),(letrec {X#9=(var X#3);E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=(var X#3);E#11},(letrec {E#10} in [.])], ((var X#9),(letrec {E#10} in C#16[[.]])), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {[.1]=[.2]}, X#2 |-> X#9, X#1 |-> X#3, E#4 |-> {E#11}, C#7 |-> (letrec {E#10} in C#16), S#12 |-> C#16[(var X#9)], A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#3=(letrec {E#10} in C#16[(var X#9)]);X#9=(var X#3);E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#3=(letrec {E#10} in C#16[(var X#3)]);X#9=(var X#3);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#3=(letrec {E#10} in C#16[(var X#9)]);X#9=(var X#3);E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#3=C#16[(var X#9)];X#9=(var X#3);E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#3= (letrec {X#17=C#16[(var X#3)];E#19} in S#12) ;X#9= (var X#3) ;E#11 in A#13[(var X#9)] ) , (letrec X#17= C#16[(var X#9)] ;X#3= S#12 ;X#9= (var X#3) ;E#11 ;E#19 in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#9),(letrec {X#17=C#16;E#19} in S#12)), ((var X#3),(letrec {X#17=C#16;E#19} in S#12)), ((var X#3),(letrec {X#17=C#16[(var X#9)];X#9=(var X#3);E#11;E#19} in [.])), (A#13[(var X#9)],(letrec {X#17=C#16[(var X#9)];E#19} in [.])), [{X#9=(var X#3);E#11},(letrec {X#17=C#16[(var X#9)];E#19} in [.])], ((var X#9),(letrec {X#17=C#16[[.]];E#19} in S#12)), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {[.1]=[.2]}, X#2 |-> X#9, X#1 |-> X#3, E#4 |-> {E#11}, C#7 |-> (letrec {X#17=C#16;E#19} in S#12), E#10 |-> {X#17=C#16[(var X#9)];E#19}, E#18 |-> {E#19}, A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#3=(letrec {X#17=C#16[(var X#9)];E#19} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#3=(letrec {X#17=C#16[(var X#3)];E#19} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#3=(letrec {X#17=C#16[(var X#9)];E#19} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=C#16[(var X#9)];X#3=S#12;X#9=(var X#3);E#11;E#19} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#3= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#16 in A#13[(var X#9)] ) , (letrec X#1= C#7[(var X#9)] ;X#3= S#12 ;X#9= (var X#3) ;E#10 ;E#16 in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#9),C#7), ((var X#3),C#7), ((var X#3),(letrec {X#1=C#7[(var X#9)];X#9=(var X#3);E#10;E#16} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=C#7[(var X#9)];X#9=(var X#3);E#16},(letrec {E#10} in [.])], ((var X#9),C#7[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {[.1]=[.2]}, X#2 |-> X#9, E#11 |-> {X#1=C#7[(var X#9)];E#16}, E#4 |-> {X#3=(letrec {E#10} in S#12);E#16}, A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#9)];X#3=(letrec {E#10} in S#12);X#9=(var X#3);E#16} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#3=(letrec {E#10} in S#12);X#9=(var X#3);E#16} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#7[(var X#9)];X#3=(letrec {E#10} in S#12);X#9=(var X#3);E#16} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=C#7[(var X#9)];X#3=S#12;X#9=(var X#3);E#10;E#16} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in C#18[(var X#3)]) ;X#9= (var X#3) ;E#11 ;EE#17[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#8= C#18[(var X#9)] ;X#9= (var X#3) ;E#10 ;E#11 ;EE#17[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#9),(letrec {E#10} in C#18)), ((var X#3),(letrec {E#10} in C#18)), ((var X#8),(letrec {X#9=(var X#3);E#10;E#11;EE#17[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#9),(letrec {E#10} in C#18[[.]])), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {[.1]=(var X#3);EE#17[X#3,[.2]]}, X#2 |-> X#9, X#1 |-> X#8, E#4 |-> {E#11;EE#17[X#3,(var X#8)]}, C#7 |-> (letrec {E#10} in C#18), S#12 |-> C#18[(var X#9)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#8=(letrec {E#10} in C#18[(var X#9)]);X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {E#10} in C#18[(var X#3)]);X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in C#18[(var X#9)]);X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=C#18[(var X#9)];X#9=(var X#3);E#10;E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#19=C#18[(var X#3)];E#21} in S#12) ;X#9= (var X#3) ;E#11 ;EE#17[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#19= C#18[(var X#9)] ;X#8= S#12 ;X#9= (var X#3) ;E#11 ;E#21 ;EE#17[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#9),(letrec {X#19=C#18;E#21} in S#12)), ((var X#3),(letrec {X#19=C#18;E#21} in S#12)), ((var X#8),(letrec {X#19=C#18[(var X#9)];X#9=(var X#3);E#11;E#21;EE#17[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#19=C#18[(var X#9)];E#21} in [.])), [{X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]},(letrec {X#19=C#18[(var X#9)];E#21} in [.])], ((var X#9),(letrec {X#19=C#18[[.]];E#21} in S#12)), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {[.1]=(var X#3);EE#17[X#3,[.2]]}, X#2 |-> X#9, X#1 |-> X#8, E#4 |-> {E#11;EE#17[X#3,(var X#8)]}, C#7 |-> (letrec {X#19=C#18;E#21} in S#12), E#10 |-> {X#19=C#18[(var X#9)];E#21}, E#20 |-> {E#21}, A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#8=(letrec {X#19=C#18[(var X#9)];E#21} in S#12);X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#8=(letrec {X#19=C#18[(var X#3)];E#21} in S#12);X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {X#19=C#18[(var X#9)];E#21} in S#12);X#9=(var X#3);E#11;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=C#18[(var X#9)];X#8=S#12;X#9=(var X#3);E#11;E#21;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#8= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#18 ;EE#17[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#1= C#7[(var X#9)] ;X#8= S#12 ;X#9= (var X#3) ;E#10 ;E#18 ;EE#17[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#9),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#1=C#7[(var X#9)];X#9=(var X#3);E#10;E#18;EE#17[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=C#7[(var X#9)];X#9=(var X#3);E#18;EE#17[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#9),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {[.1]=(var X#3);EE#17[X#3,[.2]]}, X#2 |-> X#9, E#11 |-> {X#1=C#7[(var X#9)];E#18}, E#4 |-> {X#8=(letrec {E#10} in S#12);E#18;EE#17[X#3,(var X#8)]}, A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#9)];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#18;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#18;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#7[(var X#9)];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#18;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=C#7[(var X#9)];X#8=S#12;X#9=(var X#3);E#10;E#18;EE#17[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app A#20[(var X#8)] C#21[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#11 in A#13[(var X#9)] ) , (letrec X#3= A#19[(app A#20[(var X#8)] C#21[(var X#9)])] ;X#8= S#12 ;X#9= (var X#3) ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#9),A#19[(app A#20[(var X#8)] C#21)]), ((var X#3),A#19[(app A#20[(var X#8)] C#21)]), ((var X#8),(letrec {X#3=A#19[(app A#20[(var X#8)] C#21[(var X#9)])];X#9=(var X#3);E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#3=A#19[(app A#20[(var X#8)] C#21[(var X#9)])];X#9=(var X#3);E#11},(letrec {E#10} in [.])], ((var X#9),A#19[(app A#20[(var X#8)] C#21[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#3=A#19[(app A#20[[.2]] C#21[(var X#9)])];[.1]=(var X#3)}, X#2 |-> X#9, EE#17[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] C#21[(var X#9)])]}, X#1 |-> X#3, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11}, C#7 |-> A#19[(app A#20[(var X#8)] C#21)], A#18 |-> A#19[(app A#20 C#21[(var X#9)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=A#19[(app A#20[(var X#8)] C#21[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#3=A#19[(app A#20[(var X#8)] C#21[(var X#3)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#3=A#19[(app A#20[(var X#8)] C#21[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#3=A#19[(app A#20[(var X#8)] C#21[(var X#9)])];X#8=S#12;X#9=(var X#3);E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#3= A#21[(app A#22[(var X#19)] C#23[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#11 ;EE#20[X#19,(var X#8)] in A#13[(var X#9)] ) , (letrec X#3= A#21[(app A#22[(var X#19)] C#23[(var X#9)])] ;X#8= S#12 ;X#9= (var X#3) ;E#10 ;E#11 ;EE#20[X#19,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#9),A#21[(app A#22[(var X#19)] C#23)]), ((var X#3),A#21[(app A#22[(var X#19)] C#23)]), ((var X#8),(letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];X#9=(var X#3);E#10;E#11;EE#20[X#19,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#3=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];X#9=(var X#3);E#11;EE#20[X#19,(var X#8)]},(letrec {E#10} in [.])], ((var X#9),A#21[(app A#22[(var X#19)] C#23[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];[.1]=(var X#3);EE#20[X#19,[.2]]}, X#2 |-> X#9, EE#17[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];EE#20[X#19,[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#19,(var X#8)]}, C#7 |-> A#21[(app A#22[(var X#19)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#9)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#3)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#9)])];X#8=S#12;X#9=(var X#3);E#10;E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#11 ;EE#21[X#3,(var X#19)] ;EE#22[X#20,(var X#8)] in A#13[(var X#9)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#9)])] ;X#8= S#12 ;X#9= (var X#3) ;E#10 ;E#11 ;EE#21[X#3,(var X#19)] ;EE#22[X#20,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#9),A#23[(app A#24[(var X#20)] C#25)]), ((var X#3),A#23[(app A#24[(var X#20)] C#25)]), ((var X#8),(letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];X#9=(var X#3);E#10;E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];X#9=(var X#3);E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]},(letrec {E#10} in [.])], ((var X#9),A#23[(app A#24[(var X#20)] C#25[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];[.1]=(var X#3);EE#21[X#3,(var X#19)];EE#22[X#20,[.2]]}, X#2 |-> X#9, EE#17[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#1 |-> X#19, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]}, C#7 |-> A#23[(app A#24[(var X#20)] C#25)], A#18 |-> A#23[(app A#24 C#25[(var X#9)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#3)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#9)])];X#8=S#12;X#9=(var X#3);E#10;E#11;EE#21[X#3,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] C#23[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#11 ;EE#20[X#3,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[(var X#8)] C#23[(var X#9)])] ;X#8= S#12 ;X#9= (var X#3) ;E#10 ;E#11 ;EE#20[X#3,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#9),A#21[(app A#22[(var X#8)] C#23)]), ((var X#3),A#21[(app A#22[(var X#8)] C#23)]), ((var X#8),(letrec {X#19=A#21[(app A#22[(var X#8)] C#23[(var X#9)])];X#9=(var X#3);E#10;E#11;EE#20[X#3,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#19=A#21[(app A#22[(var X#8)] C#23[(var X#9)])];X#9=(var X#3);E#11;EE#20[X#3,(var X#19)]},(letrec {E#10} in [.])], ((var X#9),A#21[(app A#22[(var X#8)] C#23[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#9)])];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#9, EE#17[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#9)])];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#3,(var X#19)]}, C#7 |-> A#21[(app A#22[(var X#8)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#9)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] C#23[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#20[X#3,(var X#19)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#19=A#21[(app A#22[(var X#8)] C#23[(var X#3)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#20[X#3,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] C#23[(var X#9)])];X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#20[X#3,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=A#21[(app A#22[(var X#8)] C#23[(var X#9)])];X#8=S#12;X#9=(var X#3);E#10;E#11;EE#20[X#3,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {E#10} in C#20[(var X#3)]) ;E#11 ;EE#18[X#9,(var X#16)] ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#8= C#20[(var X#16)] ;E#10 ;E#11 ;EE#18[X#9,(var X#16)] ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#16),(letrec {E#10} in C#20)), ((var X#3),(letrec {E#10} in C#20)), ((var X#8),(letrec {X#16=(var X#3);E#10;E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),(letrec {E#10} in C#20[[.]])), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);EE#18[[.1],(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, X#1 |-> X#8, E#4 |-> {E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]}, C#7 |-> (letrec {E#10} in C#20), S#12 |-> C#20[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {E#10} in C#20[(var X#16)]);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {E#10} in C#20[(var X#3)]);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {E#10} in C#20[(var X#16)]);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#8=C#20[(var X#16)];E#10;E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {X#21=C#20[(var X#3)];E#23} in S#12) ;E#11 ;EE#18[X#9,(var X#16)] ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= C#20[(var X#16)] ;X#8= S#12 ;E#11 ;E#23 ;EE#18[X#9,(var X#16)] ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#16),(letrec {X#21=C#20;E#23} in S#12)), ((var X#3),(letrec {X#21=C#20;E#23} in S#12)), ((var X#8),(letrec {X#16=(var X#3);X#21=C#20[(var X#16)];E#11;E#23;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#21=C#20[(var X#16)];E#23} in [.])), [{X#16=(var X#3);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]},(letrec {X#21=C#20[(var X#16)];E#23} in [.])], ((var X#16),(letrec {X#21=C#20[[.]];E#23} in S#12)), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);EE#18[[.1],(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, X#1 |-> X#8, E#4 |-> {E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]}, C#7 |-> (letrec {X#21=C#20;E#23} in S#12), E#10 |-> {X#21=C#20[(var X#16)];E#23}, E#22 |-> {E#23}, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {X#21=C#20[(var X#16)];E#23} in S#12);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {X#21=C#20[(var X#3)];E#23} in S#12);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {X#21=C#20[(var X#16)];E#23} in S#12);E#11;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=C#20[(var X#16)];X#8=S#12;E#11;E#23;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#16= (var X#3) ;X#8= (letrec {E#10} in S#12) ;E#20 ;EE#18[X#9,(var X#16)] ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#1= C#7[(var X#16)] ;X#16= (var X#3) ;X#8= S#12 ;E#10 ;E#20 ;EE#18[X#9,(var X#16)] ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),C#7), ((var X#3),C#7), ((var X#8),(letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#10;E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),C#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);EE#18[[.1],(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, E#11 |-> {X#1=C#7[(var X#16)];E#20}, E#4 |-> {X#8=(letrec {E#10} in S#12);E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]}, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);X#8=(letrec {E#10} in S#12);E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#16=(var X#3);X#8=(letrec {E#10} in S#12);E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);X#8=(letrec {E#10} in S#12);E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);X#8=S#12;E#10;E#20;EE#18[X#9,(var X#16)];EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= A#21[(var X#3)] ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#8= S#12 ;X#9= A#21[(var X#16)] ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), ((var X#3),A#21[[.]]), ((var X#8),(letrec {X#16=(var X#3);X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#21[(var X#16)];E#11;EE#19[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)]}, A#20 |-> A#21, C#7 |-> A#21[[.]], A#15 |-> [.], X#17 |-> X#3, C#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#3)];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#8=S#12;X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= A#21[(var X#3)] ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#8= S#12 ;X#9= A#21[(var X#16)] ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), ((var X#3),A#21), ((var X#8),(letrec {X#16=(var X#3);X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#21[(var X#16)];E#11;EE#19[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)]}, A#20 |-> A#21[[.]], C#7 |-> A#21, A#15 |-> [.], X#17 |-> X#3, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#3)];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#8=S#12;X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= A#21[(app A#22[(var X#16)] C#23[(var X#3)])] ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#8= S#12 ;X#9= A#21[(app A#22[(var X#16)] C#23[(var X#16)])] ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app A#22[(var X#16)] C#23)]), ((var X#3),A#21[(app A#22[(var X#16)] C#23)]), ((var X#8),(letrec {X#16=(var X#3);X#9=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#10;E#11;EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#11;EE#19[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#21[(app A#22[(var X#16)] C#23[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#16)])]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)]}, C#7 |-> A#21[(app A#22[(var X#16)] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#16)] C#23[(var X#3)])];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#8=S#12;X#9=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#10;E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#8= S#12 ;X#9= (var X#16) ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), ((var X#3),[.]), ((var X#8),(letrec {X#16=(var X#3);X#9=(var X#16);E#10;E#11;EE#19[X#3,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=(var X#16);E#11;EE#19[X#3,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=(var X#16);EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)]}, C#7 |-> [.], A#20 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=(var X#16);E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=(var X#3);E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=(var X#16);E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#8=S#12;X#9=(var X#16);E#10;E#11;EE#19[X#3,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (letrec {E#10} in S#12) ;X#9= A#23[(app A#24[(var X#21)] C#25[(var X#3)])] ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#21,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#8= S#12 ;X#9= A#23[(app A#24[(var X#21)] C#25[(var X#16)])] ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#21,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#21)] C#25)]), ((var X#3),A#23[(app A#24[(var X#21)] C#25)]), ((var X#8),(letrec {X#16=(var X#3);X#9=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#19[X#3,[.2]];EE#22[X#21,(var X#16)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#22[X#21,[.2]]}, X#1 |-> X#9, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]}, C#7 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#23[(app A#24[(var X#21)] C#25[(var X#3)])];E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(letrec {E#10} in S#12);X#9=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#8=S#12;X#9=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#21,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#3,(var X#8)] ;EE#23[X#9,(var X#21)] ;EE#24[X#22,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#16)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] ;EE#23[X#9,(var X#21)] ;EE#24[X#22,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#25[(app A#26[(var X#22)] C#27)]), ((var X#3),A#25[(app A#26[(var X#22)] C#27)]), ((var X#8),(letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#19[X#3,[.2]];EE#23[[.1],(var X#21)];EE#24[X#22,(var X#16)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]}, C#7 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#3)])];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];X#8=S#12;E#10;E#11;EE#19[X#3,(var X#8)];EE#23[X#9,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(var X#3)] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(var X#16)] ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[[.]]), ((var X#3),A#23[[.]]), ((var X#8),(letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=A#23[(var X#16)];E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),A#23[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(var X#16)];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[[.]], A#15 |-> [.], X#17 |-> X#3, C#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(var X#3)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];X#8=S#12;E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(var X#3)] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(var X#16)] ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23), ((var X#3),A#23), ((var X#8),(letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=A#23[(var X#16)];E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),A#23[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(var X#16)];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]}, A#20 |-> A#23[[.]], C#7 |-> A#23, A#15 |-> [.], X#17 |-> X#3, A#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(var X#3)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];X#8=S#12;E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#16)] C#25[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#16)] C#25[(var X#16)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#16)] C#25)]), ((var X#3),A#23[(app A#24[(var X#16)] C#25)]), ((var X#8),(letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),A#23[(app A#24[(var X#16)] C#25[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]}, C#7 |-> A#23[(app A#24[(var X#16)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#3)])];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];X#8=S#12;E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (var X#3) ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= (var X#16) ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#3,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), ((var X#3),[.]), ((var X#8),(letrec {X#16=(var X#3);X#21=(var X#16);E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=(var X#16);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=(var X#16);EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]}, C#7 |-> [.], A#20 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(var X#16);X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(var X#3);X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(var X#16);X#8=(letrec {E#10} in S#12);E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=(var X#16);X#8=S#12;E#10;E#11;EE#19[X#3,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app A#22[(var X#8)] C#23[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#18[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(app A#22[(var X#8)] C#23[(var X#16)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#18[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app A#22[(var X#8)] C#23)]), ((var X#3),A#21[(app A#22[(var X#8)] C#23)]), ((var X#8),(letrec {X#16=(var X#3);X#3=A#21[(app A#22[(var X#8)] C#23[(var X#16)])];E#10;E#11;EE#18[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#3=A#21[(app A#22[(var X#8)] C#23[(var X#16)])];E#11;EE#18[X#9,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),A#21[(app A#22[(var X#8)] C#23[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[(app A#22[[.2]] C#23[(var X#16)])];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#16)])]}, X#1 |-> X#3, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)]}, C#7 |-> A#21[(app A#22[(var X#8)] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(var X#8)] C#23[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(var X#8)] C#23[(var X#3)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(var X#8)] C#23[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(var X#8)] C#23[(var X#16)])];X#8=S#12;E#10;E#11;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#23[(app A#24[(var X#21)] C#25[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#18[X#9,(var X#16)] ;EE#22[X#21,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= A#23[(app A#24[(var X#21)] C#25[(var X#16)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#18[X#9,(var X#16)] ;EE#22[X#21,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#21)] C#25)]), ((var X#3),A#23[(app A#24[(var X#21)] C#25)]), ((var X#8),(letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#10;E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#18[[.1],(var X#16)];EE#22[X#21,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#22[X#21,[.2]]}, X#1 |-> X#3, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]}, C#7 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#3)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];X#8=S#12;E#10;E#11;EE#18[X#9,(var X#16)];EE#22[X#21,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#18[X#9,(var X#16)] ;EE#23[X#3,(var X#21)] ;EE#24[X#22,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#16)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#18[X#9,(var X#16)] ;EE#23[X#3,(var X#21)] ;EE#24[X#22,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#25[(app A#26[(var X#22)] C#27)]), ((var X#3),A#25[(app A#26[(var X#22)] C#27)]), ((var X#8),(letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#10;E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#18[[.1],(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]}, C#7 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#3)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];X#8=S#12;E#10;E#11;EE#18[X#9,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#8)] C#25[(var X#3)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#18[X#9,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#8)] C#25[(var X#16)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#18[X#9,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#8)] C#25)]), ((var X#3),A#23[(app A#24[(var X#8)] C#25)]), ((var X#8),(letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#8)] C#25[(var X#16)])];E#10;E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#21=A#23[(app A#24[(var X#8)] C#25[(var X#16)])];E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),A#23[(app A#24[(var X#8)] C#25[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]}, C#7 |-> A#23[(app A#24[(var X#8)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#8)] C#25[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#8)] C#25[(var X#3)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#8)] C#25[(var X#16)])];X#8=(letrec {E#10} in S#12);E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#8)] C#25[(var X#16)])];X#8=S#12;E#10;E#11;EE#18[X#9,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in C#18[(var X#3)]) ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= C#18[(var X#16)] ;E#10 ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#16),(letrec {E#10} in C#18)), ((var X#3),(letrec {E#10} in C#18)), ((var X#3),(letrec {X#16=(var X#3);E#10;E#11;EE#17[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);E#11;EE#17[X#9,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),(letrec {E#10} in C#18[[.]])), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#2 |-> X#16, X#1 |-> X#3, E#4 |-> {E#11;EE#17[X#9,(var X#16)]}, C#7 |-> (letrec {E#10} in C#18), S#12 |-> C#18[(var X#16)], A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {E#10} in C#18[(var X#16)]);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {E#10} in C#18[(var X#3)]);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {E#10} in C#18[(var X#16)]);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=C#18[(var X#16)];E#10;E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {X#19=C#18[(var X#3)];E#21} in S#12) ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#19= C#18[(var X#16)] ;X#3= S#12 ;E#11 ;E#21 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#16),(letrec {X#19=C#18;E#21} in S#12)), ((var X#3),(letrec {X#19=C#18;E#21} in S#12)), ((var X#3),(letrec {X#16=(var X#3);X#19=C#18[(var X#16)];E#11;E#21;EE#17[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {X#19=C#18[(var X#16)];E#21} in [.])), [{X#16=(var X#3);E#11;EE#17[X#9,(var X#16)]},(letrec {X#19=C#18[(var X#16)];E#21} in [.])], ((var X#16),(letrec {X#19=C#18[[.]];E#21} in S#12)), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#2 |-> X#16, X#1 |-> X#3, E#4 |-> {E#11;EE#17[X#9,(var X#16)]}, C#7 |-> (letrec {X#19=C#18;E#21} in S#12), E#10 |-> {X#19=C#18[(var X#16)];E#21}, E#20 |-> {E#21}, A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {X#19=C#18[(var X#16)];E#21} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {X#19=C#18[(var X#3)];E#21} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {X#19=C#18[(var X#16)];E#21} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#19=C#18[(var X#16)];X#3=S#12;E#11;E#21;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#16= (var X#3) ;X#3= (letrec {E#10} in S#12) ;E#18 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#1= C#7[(var X#16)] ;X#16= (var X#3) ;X#3= S#12 ;E#10 ;E#18 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),C#7), ((var X#3),C#7), ((var X#3),(letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#10;E#18;EE#17[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=C#7[(var X#16)];X#16=(var X#3);E#18;EE#17[X#9,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),C#7[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#2 |-> X#16, E#11 |-> {X#1=C#7[(var X#16)];E#18}, E#4 |-> {X#3=(letrec {E#10} in S#12);E#18;EE#17[X#9,(var X#16)]}, A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);X#3=(letrec {E#10} in S#12);E#18;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#16=(var X#3);X#3=(letrec {E#10} in S#12);E#18;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);X#3=(letrec {E#10} in S#12);E#18;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);X#3=S#12;E#10;E#18;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in S#12) ;X#9= A#19[(var X#3)] ;E#11 in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= S#12 ;X#9= A#19[(var X#16)] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#16),A#19[[.]]), ((var X#3),A#19[[.]]), ((var X#3),(letrec {X#16=(var X#3);X#9=A#19[(var X#16)];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#19[(var X#16)];E#11},(letrec {E#10} in [.])], ((var X#16),A#19[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#9, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11}, A#18 |-> A#19, C#7 |-> A#19[[.]], A#15 |-> [.], X#8 |-> X#3, C#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(var X#3)];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=S#12;X#9=A#19[(var X#16)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in S#12) ;X#9= A#19[(var X#3)] ;E#11 in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= S#12 ;X#9= A#19[(var X#16)] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#16),A#19), ((var X#3),A#19), ((var X#3),(letrec {X#16=(var X#3);X#9=A#19[(var X#16)];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#19[(var X#16)];E#11},(letrec {E#10} in [.])], ((var X#16),A#19[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#9, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11}, A#18 |-> A#19[[.]], C#7 |-> A#19, A#15 |-> [.], X#8 |-> X#3, A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(var X#3)];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=S#12;X#9=A#19[(var X#16)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in S#12) ;X#9= A#19[(app A#20[(var X#16)] C#21[(var X#3)])] ;E#11 in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= S#12 ;X#9= A#19[(app A#20[(var X#16)] C#21[(var X#16)])] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#19[(app A#20[(var X#16)] C#21)]), ((var X#3),A#19[(app A#20[(var X#16)] C#21)]), ((var X#3),(letrec {X#16=(var X#3);X#9=A#19[(app A#20[(var X#16)] C#21[(var X#16)])];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#19[(app A#20[(var X#16)] C#21[(var X#16)])];E#11},(letrec {E#10} in [.])], ((var X#16),A#19[(app A#20[(var X#16)] C#21[[.]])]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];[.1]=A#19[(app A#20[(var X#16)] C#21[(var X#16)])]}, X#2 |-> X#16, EE#17[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] C#21[(var X#16)])]}, X#1 |-> X#9, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11}, C#7 |-> A#19[(app A#20[(var X#16)] C#21)], A#18 |-> A#19[(app A#20 C#21[(var X#16)])], A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#16)] C#21[(var X#16)])];E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#16)] C#21[(var X#3)])];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#16)] C#21[(var X#16)])];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=S#12;X#9=A#19[(app A#20[(var X#16)] C#21[(var X#16)])];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in S#12) ;X#9= (var X#3) ;E#11 in A#13[(var X#9)] ) , (letrec {X#16=(var X#3);X#3=S#12;X#9=(var X#16);E#10;E#11} in A#13[(var X#9)]) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), ((var X#3),[.]), ((var X#3),(letrec {X#16=(var X#3);X#9=(var X#16);E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=(var X#16);E#11},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];[.1]=(var X#16)}, X#2 |-> X#16, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11}, C#7 |-> [.], A#18 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=(var X#16);E#11} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=(var X#3);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=(var X#16);E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=S#12;X#9=(var X#16);E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in S#12) ;X#9= A#21[(app A#22[(var X#19)] C#23[(var X#3)])] ;E#11 ;EE#20[X#19,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#3= S#12 ;X#9= A#21[(app A#22[(var X#19)] C#23[(var X#16)])] ;E#10 ;E#11 ;EE#20[X#19,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app A#22[(var X#19)] C#23)]), ((var X#3),A#21[(app A#22[(var X#19)] C#23)]), ((var X#3),(letrec {X#16=(var X#3);X#9=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];E#10;E#11;EE#20[X#19,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#9=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];E#11;EE#20[X#19,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),A#21[(app A#22[(var X#19)] C#23[[.]])]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];[.1]=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];EE#20[X#19,(var X#16)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];EE#20[X#19,[.2]]}, X#1 |-> X#9, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11;EE#20[X#19,(var X#16)]}, C#7 |-> A#21[(app A#22[(var X#19)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];E#11;EE#20[X#19,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] C#23[(var X#3)])];E#11;EE#20[X#19,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];E#11;EE#20[X#19,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#3=S#12;X#9=A#21[(app A#22[(var X#19)] C#23[(var X#16)])];E#10;E#11;EE#20[X#19,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#19= A#23[(app A#24[(var X#20)] C#25[(var X#3)])] ;X#3= (letrec {E#10} in S#12) ;E#11 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#19= A#23[(app A#24[(var X#20)] C#25[(var X#16)])] ;X#3= S#12 ;E#10 ;E#11 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#20)] C#25)]), ((var X#3),A#23[(app A#24[(var X#20)] C#25)]), ((var X#3),(letrec {X#16=(var X#3);X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];E#10;E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]},(letrec {E#10} in [.])], ((var X#16),A#23[(app A#24[(var X#20)] C#25[[.]])]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];EE#21[[.1],(var X#19)];EE#22[X#20,(var X#16)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#1 |-> X#19, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]}, C#7 |-> A#23[(app A#24[(var X#20)] C#25)], A#18 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];X#3=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#19=A#23[(app A#24[(var X#20)] C#25[(var X#3)])];X#3=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];X#3=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#19=A#23[(app A#24[(var X#20)] C#25[(var X#16)])];X#3=S#12;E#10;E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#19= A#21[(var X#3)] ;X#3= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#19= A#21[(var X#16)] ;X#3= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), ((var X#3),A#21[[.]]), ((var X#3),(letrec {X#16=(var X#3);X#19=A#21[(var X#16)];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#19=A#21[(var X#16)];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, A#18 |-> A#21, C#7 |-> A#21[[.]], A#15 |-> [.], X#8 |-> X#3, C#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#19=A#21[(var X#16)];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#19=A#21[(var X#3)];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#19=A#21[(var X#16)];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#19=A#21[(var X#16)];X#3=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#19= A#21[(var X#3)] ;X#3= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#19= A#21[(var X#16)] ;X#3= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), ((var X#3),A#21), ((var X#3),(letrec {X#16=(var X#3);X#19=A#21[(var X#16)];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#19=A#21[(var X#16)];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, A#18 |-> A#21[[.]], C#7 |-> A#21, A#15 |-> [.], X#8 |-> X#3, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#19=A#21[(var X#16)];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#19=A#21[(var X#3)];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#19=A#21[(var X#16)];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#19=A#21[(var X#16)];X#3=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#19= A#21[(app A#22[(var X#16)] C#23[(var X#3)])] ;X#3= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#19= A#21[(app A#22[(var X#16)] C#23[(var X#16)])] ;X#3= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app A#22[(var X#16)] C#23)]), ((var X#3),A#21[(app A#22[(var X#16)] C#23)]), ((var X#3),(letrec {X#16=(var X#3);X#19=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#19=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),A#21[(app A#22[(var X#16)] C#23[[.]])]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];X#19=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#16)])];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, C#7 |-> A#21[(app A#22[(var X#16)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#19=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#19=A#21[(app A#22[(var X#16)] C#23[(var X#3)])];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#19=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#19=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];X#3=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#19= (var X#3) ;X#3= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= (var X#3) ;X#19= (var X#16) ;X#3= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), ((var X#3),[.]), ((var X#3),(letrec {X#16=(var X#3);X#19=(var X#16);E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#3);X#19=(var X#16);E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#3),[.]), ((var X#9),A#13[[.]]), ((var X#3),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),C#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=[.2];X#19=(var X#16);EE#20[[.1],(var X#19)]}, X#2 |-> X#16, EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, C#7 |-> [.], A#18 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#8 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#19=(var X#16);X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-cpx-e1- (letrec {X#16=(var X#3);X#19=(var X#3);X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#3);X#19=(var X#16);X#3=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#3);X#19=(var X#16);X#3=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( A#12[(app (letrec {E#8} in T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#9)] , A#12[(letrec E#8 in (app T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#9) )] ) where Delta1 = {T#14,T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {E#8} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (letrec {E#8} in T#15) S#9)], T#13 |-> (app (letrec {E#8} in T#15) S#9), T#14 |-> (letrec {E#8} in T#15), S#10 |-> T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: A#12[(app (letrec {E#8} in T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#9)] <-cpx-e1- A#12[(app (letrec {E#8} in T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#9)] ................................................................................ A#12[(app (letrec {E#8} in T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#9)] -SR,lapp1-> A#12[(letrec {E#8} in (app T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#9))] ================================================================================ Critical Pair: ( A#12[(app (letrec X#16= T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#18 in S#10 ) S#9)] , A#12[(letrec X#16= T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#18 in (app S#10 S#9) )] ) where Delta1 = {T#14,T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (letrec {X#16=T#15;E#18} in S#10) S#9)], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#10) S#9), T#14 |-> (letrec {X#16=T#15;E#18} in S#10), E#8 |-> {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18}, E#17 |-> {E#18}} and instantiated rules: A#12[(app (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in S#10) S#9)] <-cpx-e1- A#12[(app (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#18} in S#10) S#9)] ................................................................................ A#12[(app (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in S#10) S#9)] -SR,lapp1-> A#12[(letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in (app S#10 S#9))] ================================================================================ Critical Pair: ( A#12[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#16} in S#10) S#9)] , A#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in (app S#10 S#9))] ) where Delta1 = {T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app [.] S#9)], T#13 |-> (app [.] S#9), T#14 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#16}, E#15 |-> {X#1=C#7[(var X#2)];E#16}, E#4 |-> {E#16}} and instantiated rules: A#12[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in S#10) S#9)] <-cpx-e1- A#12[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#16} in S#10) S#9)] ................................................................................ A#12[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in S#10) S#9)] -SR,lapp1-> A#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in (app S#10 S#9))] ================================================================================ Critical Pair: ( A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] , A#12[(letrec E#8 in (app S#10 T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) )] ) where Delta1 = {T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#8} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (letrec {E#8} in S#10) T#14)], T#13 |-> (app (letrec {E#8} in S#10) T#14), S#9 |-> T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] <-cpx-e1- A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ................................................................................ A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] -SR,lapp1-> A#12[(letrec {E#8} in (app S#10 T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]))] ================================================================================ Critical Pair: ( A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] , A#12[(app A#13[(letrec {E#8} in (app S#10 S#9))] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) where Delta1 = {A#11,T#6} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {E#8} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14)], A#11 |-> A#12[(app A#13 T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] <-cpx-e1- A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ................................................................................ A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] -SR,lapp1-> A#12[(app A#13[(letrec {E#8} in (app S#10 S#9))] T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ================================================================================ Critical Pair: ( (app (letrec {E#8} in T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#9) , (letrec E#8 in (app T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#9) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {E#8} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (letrec {E#8} in T#13) S#9), T#12 |-> (letrec {E#8} in T#13), S#10 |-> T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (app (letrec {E#8} in T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#9) <-cpx-e1- (app (letrec {E#8} in T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#9) ................................................................................ (app (letrec {E#8} in T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#9) -SR,lapp1-> (letrec {E#8} in (app T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#9)) ================================================================================ Critical Pair: ( (app (letrec X#14= T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#16 in S#10 ) S#9) , (letrec X#14= T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#16 in (app S#10 S#9) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (letrec {X#14=T#13;E#16} in S#10) S#9), T#12 |-> (letrec {X#14=T#13;E#16} in S#10), E#8 |-> {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16}, E#15 |-> {E#16}} and instantiated rules: (app (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in S#10) S#9) <-cpx-e1- (app (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#16} in S#10) S#9) ................................................................................ (app (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in S#10) S#9) -SR,lapp1-> (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in (app S#10 S#9)) ================================================================================ Critical Pair: ( (app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#14} in S#10) S#9) , (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in (app S#10 S#9)) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#9,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app [.] S#9), T#12 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#14}, E#13 |-> {X#1=C#7[(var X#2)];E#14}, E#4 |-> {E#14}} and instantiated rules: (app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in S#10) S#9) <-cpx-e1- (app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#14} in S#10) S#9) ................................................................................ (app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in S#10) S#9) -SR,lapp1-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in (app S#10 S#9)) ================================================================================ Critical Pair: ( (app (letrec {E#8} in S#10) T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) , (letrec E#8 in (app S#10 T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) ) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#8} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#9,(letrec {E#8} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (letrec {E#8} in S#10) T#12), S#9 |-> T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (app (letrec {E#8} in S#10) T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) <-cpx-e1- (app (letrec {E#8} in S#10) T#12[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ................................................................................ (app (letrec {E#8} in S#10) T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) -SR,lapp1-> (letrec {E#8} in (app S#10 T#12[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#10)] ) , (letrec E#8 in A#14[(letrec E#9 in (app T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#10) )] ) ) where Delta1 = {T#16,T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app (letrec {E#9} in T#17) S#10)]), A#12 |-> A#14, T#13 |-> A#14[(app (letrec {E#9} in T#17) S#10)], T#15 |-> (app (letrec {E#9} in T#17) S#10), T#16 |-> (letrec {E#9} in T#17), S#11 |-> T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#10)]) <-cpx-e1- (letrec {E#8} in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#10)]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#10)]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {E#9} in (app T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#10))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec X#18= T#17[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#20 in S#11 ) S#10)] ) , (letrec E#8 in A#14[(letrec X#18= T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#20 in (app S#11 S#10) )] ) ) where Delta1 = {T#16,T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {X#18=T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#20} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app (letrec {X#18=T#17;E#20} in S#11) S#10)]), A#12 |-> A#14, T#13 |-> A#14[(app (letrec {X#18=T#17;E#20} in S#11) S#10)], T#15 |-> (app (letrec {X#18=T#17;E#20} in S#11) S#10), T#16 |-> (letrec {X#18=T#17;E#20} in S#11), E#9 |-> {X#18=T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {X#18=T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#20} in S#11) S#10)]) <-cpx-e1- (letrec {E#8} in A#14[(app (letrec {X#18=T#17[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#20} in S#11) S#10)]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {X#18=T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#20} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {X#18=T#17[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#20} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#18} in S#11) S#10)] ) , (letrec E#8 in A#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#18} in (app S#11 S#10))] ) ) where Delta1 = {T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#18} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app [.] S#10)]), A#12 |-> A#14, T#13 |-> A#14[(app [.] S#10)], T#15 |-> (app [.] S#10), T#16 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#18}, E#17 |-> {X#1=C#7[(var X#2)];E#18}, E#4 |-> {E#18}} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#18} in S#11) S#10)]) <-cpx-e1- (letrec {E#8} in A#14[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#18} in S#11) S#10)]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#18} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#18} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec E#8 in A#14[(letrec E#9 in (app S#11 T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) )] ) ) where Delta1 = {T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16)]), A#12 |-> A#14, T#13 |-> A#14[(app (letrec {E#9} in S#11) T#16)], T#15 |-> (app (letrec {E#9} in S#11) T#16), S#10 |-> T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {E#9} in (app S#11 T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec E#8 in A#14[(app A#15[(letrec {E#9} in (app S#11 S#10))] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16)]), T#13 |-> A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,lapp2-> (letrec {E#8} in A#14[(app A#15[(letrec {E#9} in (app S#11 S#10))] T#16[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec {E#9} in T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#10) ) , (letrec E#8 in (letrec E#9 in (app T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#10) ) ) ) where Delta1 = {T#14,T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (letrec {E#9} in T#15) S#10)), A#12 |-> [.], T#13 |-> (app (letrec {E#9} in T#15) S#10), T#14 |-> (letrec {E#9} in T#15), S#11 |-> T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#8} in (app (letrec {E#9} in T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#10)) <-cpx-e1- (letrec {E#8} in (app (letrec {E#9} in T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#10)) ................................................................................ (letrec {E#8} in (app (letrec {E#9} in T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#10)) -SR,lapp2-> (letrec {E#8} in (letrec {E#9} in (app T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#10))) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec X#16= T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#18 in S#11 ) S#10) ) , (letrec E#8 in (letrec X#16= T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#18 in (app S#11 S#10) ) ) ) where Delta1 = {T#14,T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (letrec {X#16=T#15;E#18} in S#11) S#10)), A#12 |-> [.], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#11) S#10), T#14 |-> (letrec {X#16=T#15;E#18} in S#11), E#9 |-> {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {E#8} in (app (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in S#11) S#10)) <-cpx-e1- (letrec {E#8} in (app (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#18} in S#11) S#10)) ................................................................................ (letrec {E#8} in (app (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in S#11) S#10)) -SR,lapp2-> (letrec {E#8} in (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18} in (app S#11 S#10))) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#16} in S#11) S#10) ) , (letrec E#8 in (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in (app S#11 S#10)) ) ) where Delta1 = {T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app [.] S#10)), A#12 |-> [.], T#13 |-> (app [.] S#10), T#14 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#16}, E#15 |-> {X#1=C#7[(var X#2)];E#16}, E#4 |-> {E#16}} and instantiated rules: (letrec {E#8} in (app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in S#11) S#10)) <-cpx-e1- (letrec {E#8} in (app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#16} in S#11) S#10)) ................................................................................ (letrec {E#8} in (app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in S#11) S#10)) -SR,lapp2-> (letrec {E#8} in (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16} in (app S#11 S#10))) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ) , (letrec E#8 in (letrec E#9 in (app S#11 T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) ) ) ) where Delta1 = {T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (letrec {E#9} in S#11) T#14)), A#12 |-> [.], T#13 |-> (app (letrec {E#9} in S#11) T#14), S#10 |-> T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {E#8} in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) <-cpx-e1- (letrec {E#8} in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])) ................................................................................ (letrec {E#8} in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])) -SR,lapp2-> (letrec {E#8} in (letrec {E#9} in (app S#11 T#14[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]))) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#16 in A#12[(app (letrec {E#9} in S#11) S#10)] ) , (letrec X#14= T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#16 in A#12[(letrec {E#9} in (app S#11 S#10))] ) ) where Delta1 = {T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]), E#8 |-> {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]) <-cpx-e1- (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {X#14=T#13[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#16} in A#12[(letrec {E#9} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;E#14 in A#12[(app (letrec {E#9} in S#11) S#10)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;E#14 in A#12[(letrec {E#9} in (app S#11 S#10))] ) ) where Delta1 = {} Delta2 = {E#8,E#9} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#10,(letrec {E#9} in [.])), ((var X#2),C#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#10,(letrec {E#9} in [.])),((var X#2),C#7[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(app (letrec {E#9} in S#11) S#10)], E#8 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#14}, E#13 |-> {X#1=C#7[(var X#2)];E#14}, E#4 |-> {E#14}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#14} in A#12[(letrec {E#9} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec E#9 ;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ) , (letrec E#9 ;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18)]), T#15 |-> A#16[(app A#17[(var X#8)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) <-cpx-e1- (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])]) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#18 ;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#18 ;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]), E#9 |-> {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18}, E#17 |-> {E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=T#15[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#18;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11)] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec E#10 in (app T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11) )] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (letrec {E#10} in T#22) S#11)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app (letrec {E#10} in T#22) S#11)], T#20 |-> (app (letrec {E#10} in T#22) S#11), T#21 |-> (letrec {E#10} in T#22), S#12 |-> T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=A#19[(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11)];E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {E#10} in (app T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec X#23= T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#25 in S#12 ) S#11)] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec X#23= T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#25 in (app S#12 S#11) )] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)], T#20 |-> (app (letrec {X#23=T#22;E#25} in S#12) S#11), T#21 |-> (letrec {X#23=T#22;E#25} in S#12), E#10 |-> {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#8=A#19[(app (letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app (letrec {X#23=T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in (app S#12 S#11))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#23} in S#12) S#11)] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in (app S#12 S#11))] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app [.] S#11)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app [.] S#11)], T#20 |-> (app [.] S#11), T#21 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#23}, E#22 |-> {X#1=C#7[(var X#2)];E#23}, E#4 |-> {E#23}} and instantiated rules: (letrec {X#8=A#19[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in S#12) S#11)];E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#23} in S#12) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in S#12) S#11)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in (app S#12 S#11))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec E#10 in (app S#12 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) )] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app (letrec {E#10} in S#12) T#21)], T#20 |-> (app (letrec {E#10} in S#12) T#21), S#11 |-> T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {E#10} in (app S#12 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]}, X#16 |-> X#8, E#17 |-> {E#9}, T#15 |-> A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {E#10} in T#20[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec E#10 in (app T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11) ) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (letrec {E#10} in T#20) S#11);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in T#20) S#11), T#19 |-> (letrec {E#10} in T#20), S#12 |-> T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=(app (letrec {E#10} in T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=(app (letrec {E#10} in T#20[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {E#10} in T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {E#10} in (app T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec X#21= T#20[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#23 in S#12 ) S#11) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec X#21= T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#23 in (app S#12 S#11) ) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#21=T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#23} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (letrec {X#21=T#20;E#23} in S#12) S#11);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app (letrec {X#21=T#20;E#23} in S#12) S#11), T#19 |-> (letrec {X#21=T#20;E#23} in S#12), E#10 |-> {X#21=T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#8=(app (letrec {X#21=T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#23} in S#12) S#11);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=(app (letrec {X#21=T#20[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#23} in S#12) S#11);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {X#21=T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#23} in S#12) S#11);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {X#21=T#20[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#23} in (app S#12 S#11));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#21} in S#12) S#11) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#21} in (app S#12 S#11)) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#21} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app [.] S#11);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app [.] S#11), T#19 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#21}, E#20 |-> {X#1=C#7[(var X#2)];E#21}, E#4 |-> {E#21}} and instantiated rules: (letrec {X#8=(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#21} in S#12) S#11);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#21} in S#12) S#11);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#21} in S#12) S#11);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#21} in (app S#12 S#11));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {E#10} in S#12) T#19[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec E#10 in (app S#12 T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) ) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (letrec {E#10} in S#12) T#19);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in S#12) T#19), S#11 |-> T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#8=(app (letrec {E#10} in S#12) T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=(app (letrec {E#10} in S#12) T#19[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {E#10} in S#12) T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {E#10} in (app S#12 T#19[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#20[X#19,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#8, E#17 |-> {E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#19,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {E#10} in T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec E#10 in (app T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11) )] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#23,T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (letrec {E#10} in T#24) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (letrec {E#10} in T#24) S#11)], T#22 |-> (app (letrec {E#10} in T#24) S#11), T#23 |-> (letrec {E#10} in T#24), S#12 |-> T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#19=A#21[(app (letrec {E#10} in T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {E#10} in T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {E#10} in T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {E#10} in (app T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec X#25= T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#27 in S#12 ) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec X#25= T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#27 in (app S#12 S#11) )] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#23,T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#25=T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#27} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (letrec {X#25=T#24;E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (letrec {X#25=T#24;E#27} in S#12) S#11)], T#22 |-> (app (letrec {X#25=T#24;E#27} in S#12) S#11), T#23 |-> (letrec {X#25=T#24;E#27} in S#12), E#10 |-> {X#25=T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#27}, E#26 |-> {E#27}} and instantiated rules: (letrec {X#19=A#21[(app (letrec {X#25=T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {X#25=T#24[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {X#25=T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {X#25=T#24[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#27} in (app S#12 S#11))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#25} in S#12) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#25} in (app S#12 S#11))] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#25} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app [.] S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app [.] S#11)], T#22 |-> (app [.] S#11), T#23 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#25}, E#24 |-> {X#1=C#7[(var X#2)];E#25}, E#4 |-> {E#25}} and instantiated rules: (letrec {X#19=A#21[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#25} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#25} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#25} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#25} in (app S#12 S#11))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec E#10 in (app S#12 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) )] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (letrec {E#10} in S#12) T#23)], T#22 |-> (app (letrec {E#10} in S#12) T#23), S#11 |-> T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {E#10} in (app S#12 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, T#15 |-> A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] T#23[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec E#10 in (app T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11) ) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (letrec {E#10} in T#22) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in T#22) S#11), T#21 |-> (letrec {E#10} in T#22), S#12 |-> T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#19=(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {E#10} in T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {E#10} in (app T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] S#11));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec X#23= T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] ;E#25 in S#12 ) S#11) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec X#23= T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] ;E#25 in (app S#12 S#11) ) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (letrec {X#23=T#22;E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (letrec {X#23=T#22;E#25} in S#12) S#11), T#21 |-> (letrec {X#23=T#22;E#25} in S#12), E#10 |-> {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#19=(app (letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {X#23=T#22[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)];E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {X#23=T#22[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)];E#25} in (app S#12 S#11));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#23} in S#12) S#11) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in (app S#12 S#11)) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app [.] S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app [.] S#11), T#21 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#23}, E#22 |-> {X#1=C#7[(var X#2)];E#23}, E#4 |-> {E#23}} and instantiated rules: (letrec {X#19=(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#23} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#23} in (app S#12 S#11));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec E#10 in (app S#12 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]) ) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)],(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (letrec {E#10} in S#12) T#21);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in S#12) T#21), S#11 |-> T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]} and instantiated rules: (letrec {X#19=(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)]);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {E#10} in S#12) T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {E#10} in (app S#12 T#21[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)]));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#2= (var X#3) ;E#16 ;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= C#7[(var X#2)] ;X#2= (var X#3) ;E#16 ;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#2),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#2),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#1=C#7[(var X#2)];X#2=(var X#3);E#16}, E#15 |-> {X#1=C#7[(var X#2)];E#16}, E#4 |-> {E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]}} and instantiated rules: (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#16;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app (letrec {E#10} in C#20[(var X#3)]) S#11)] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(letrec {E#10} in (app C#20[(var X#2)] S#11))] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#18,A#16,C#7,A#17} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app (letrec {E#10} in C#20) S#11)]), ((var X#3),A#17[(app (letrec {E#10} in C#20) S#11)]), (S#11,(letrec {E#10} in [.])), ((var X#2),A#17[(app (letrec {E#10} in C#20[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> A#17, C#7 |-> A#17[(app (letrec {E#10} in C#20) S#11)], C#18 |-> (app (letrec {E#10} in C#20) S#11), C#19 |-> (letrec {E#10} in C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {E#10} in C#20[(var X#2)]) S#11)];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {E#10} in C#20[(var X#3)]) S#11)];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {E#10} in C#20[(var X#2)]) S#11)];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=A#17[(letrec {E#10} in (app C#20[(var X#2)] S#11))];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app (letrec {X#21=C#20[(var X#3)];E#23} in S#12) S#11)] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(letrec {X#21=C#20[(var X#2)];E#23} in (app S#12 S#11))] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#18,A#16,C#7,A#17} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app (letrec {X#21=C#20;E#23} in S#12) S#11)]), ((var X#3),A#17[(app (letrec {X#21=C#20;E#23} in S#12) S#11)]), (S#11,(letrec {X#21=C#20[(var X#2)];E#23} in [.])), ((var X#2),A#17[(app (letrec {X#21=C#20[[.]];E#23} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> A#17, C#7 |-> A#17[(app (letrec {X#21=C#20;E#23} in S#12) S#11)], C#18 |-> (app (letrec {X#21=C#20;E#23} in S#12) S#11), C#19 |-> (letrec {X#21=C#20;E#23} in S#12), E#10 |-> {X#21=C#20[(var X#2)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {X#21=C#20[(var X#2)];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {X#21=C#20[(var X#3)];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {X#21=C#20[(var X#2)];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=A#17[(letrec {X#21=C#20[(var X#2)];E#23} in (app S#12 S#11))];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app (letrec {E#10} in S#12) C#19[(var X#3)])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(letrec {E#10} in (app S#12 C#19[(var X#2)]))] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#18,A#16,C#7,A#17} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app (letrec {E#10} in S#12) C#19)]), ((var X#3),A#17[(app (letrec {E#10} in S#12) C#19)]), (C#19[(var X#2)],(letrec {E#10} in [.])), ((var X#2),A#17[(app (letrec {E#10} in S#12) C#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> A#17, C#7 |-> A#17[(app (letrec {E#10} in S#12) C#19)], C#18 |-> (app (letrec {E#10} in S#12) C#19), S#11 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {E#10} in S#12) C#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {E#10} in S#12) C#19[(var X#3)])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app (letrec {E#10} in S#12) C#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=A#17[(letrec {E#10} in (app S#12 C#19[(var X#2)]))];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19[(var X#3)])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#17[(app A#18[(letrec {E#10} in (app S#12 S#11))] C#19[(var X#2)])] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19)]), ((var X#3),A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19)]), (S#11,(letrec {E#10} in [.])), ((var X#2),A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] C#19[(var X#2)])]}, X#1 |-> X#8, E#4 |-> {E#15}, C#7 |-> A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19)], A#16 |-> A#17[(app A#18 C#19[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19[(var X#3)])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] C#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=A#17[(app A#18[(letrec {E#10} in (app S#12 S#11))] C#19[(var X#2)])];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (app (letrec {E#10} in C#18[(var X#3)]) S#11) ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= (letrec {E#10} in (app C#18[(var X#2)] S#11)) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#17,C#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in C#18) S#11)), ((var X#3),(app (letrec {E#10} in C#18) S#11)), (S#11,(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in C#18[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> [.], C#7 |-> (app (letrec {E#10} in C#18) S#11), C#17 |-> (letrec {E#10} in C#18), S#12 |-> C#18[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(app (letrec {E#10} in C#18[(var X#2)]) S#11);E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(app (letrec {E#10} in C#18[(var X#3)]) S#11);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(app (letrec {E#10} in C#18[(var X#2)]) S#11);E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=(letrec {E#10} in (app C#18[(var X#2)] S#11));E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (app (letrec {X#19=C#18[(var X#3)];E#21} in S#12) S#11) ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= (letrec {X#19=C#18[(var X#2)];E#21} in (app S#12 S#11)) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#17,C#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {X#19=C#18;E#21} in S#12) S#11)), ((var X#3),(app (letrec {X#19=C#18;E#21} in S#12) S#11)), (S#11,(letrec {X#19=C#18[(var X#2)];E#21} in [.])), ((var X#2),(app (letrec {X#19=C#18[[.]];E#21} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> [.], C#7 |-> (app (letrec {X#19=C#18;E#21} in S#12) S#11), C#17 |-> (letrec {X#19=C#18;E#21} in S#12), E#10 |-> {X#19=C#18[(var X#2)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#2=(var X#3);X#8=(app (letrec {X#19=C#18[(var X#2)];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(app (letrec {X#19=C#18[(var X#3)];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(app (letrec {X#19=C#18[(var X#2)];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=(letrec {X#19=C#18[(var X#2)];E#21} in (app S#12 S#11));E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= (app (letrec {E#10} in S#12) C#17[(var X#3)]) ;E#15 in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= (letrec {E#10} in (app S#12 C#17[(var X#2)])) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in S#12) C#17)), ((var X#3),(app (letrec {E#10} in S#12) C#17)), (C#17[(var X#2)],(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in S#12) C#17[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#15}, A#16 |-> [.], C#7 |-> (app (letrec {E#10} in S#12) C#17), S#11 |-> C#17[(var X#2)]} and instantiated rules: (letrec {X#2=(var X#3);X#8=(app (letrec {E#10} in S#12) C#17[(var X#2)]);E#15} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=(app (letrec {E#10} in S#12) C#17[(var X#3)]);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=(app (letrec {E#10} in S#12) C#17[(var X#2)]);E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=(letrec {E#10} in (app S#12 C#17[(var X#2)]));E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#3) ;X#8= A#19[(app A#20[(var X#17)] C#21[(var X#3)])] ;E#15 ;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#2= (var X#3) ;X#8= A#19[(app A#20[(var X#17)] C#21[(var X#2)])] ;E#15 ;EE#18[X#17,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(var X#17)] C#21)]), ((var X#3),A#19[(app A#20[(var X#17)] C#21)]), (S#11,(letrec {E#10} in [.])), ((var X#2),A#19[(app A#20[(var X#17)] C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];EE#18[X#17,[.2]]}, X#1 |-> X#8, E#4 |-> {E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#19[(app A#20[(var X#17)] C#21)], A#16 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#3)])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=(var X#3);X#8=A#19[(app A#20[(var X#17)] C#21[(var X#2)])];E#15;EE#18[X#17,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] C#23[(var X#3)])] ;X#2= (var X#3) ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] C#23[(var X#2)])] ;X#2= (var X#3) ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#21[(app A#22[(var X#18)] C#23)]), ((var X#3),A#21[(app A#22[(var X#18)] C#23)]), (S#11,(letrec {E#10} in [.])), ((var X#2),A#21[(app A#22[(var X#18)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, E#4 |-> {E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#21[(app A#22[(var X#18)] C#23)], A#16 |-> A#21[(app A#22 C#23[(var X#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#3)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#21[(app A#22[(var X#18)] C#23[(var X#2)])];X#2=(var X#3);E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#10} in C#22[(var X#3)]) S#11)] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {E#10} in (app C#22[(var X#2)] S#11))] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#20,A#16,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app (letrec {E#10} in C#22) S#11)]), ((var X#3),A#19[(app (letrec {E#10} in C#22) S#11)]), (S#11,(letrec {E#10} in [.])), ((var X#2),A#19[(app (letrec {E#10} in C#22[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, C#7 |-> A#19[(app (letrec {E#10} in C#22) S#11)], C#20 |-> (app (letrec {E#10} in C#22) S#11), C#21 |-> (letrec {E#10} in C#22), S#12 |-> C#22[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#10} in C#22[(var X#2)]) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app (letrec {E#10} in C#22[(var X#3)]) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#10} in C#22[(var X#2)]) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#10} in (app C#22[(var X#2)] S#11))];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11)] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {X#23=C#22[(var X#2)];E#25} in (app S#12 S#11))] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#20,A#16,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app (letrec {X#23=C#22;E#25} in S#12) S#11)]), ((var X#3),A#19[(app (letrec {X#23=C#22;E#25} in S#12) S#11)]), (S#11,(letrec {X#23=C#22[(var X#2)];E#25} in [.])), ((var X#2),A#19[(app (letrec {X#23=C#22[[.]];E#25} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, C#7 |-> A#19[(app (letrec {X#23=C#22;E#25} in S#12) S#11)], C#20 |-> (app (letrec {X#23=C#22;E#25} in S#12) S#11), C#21 |-> (letrec {X#23=C#22;E#25} in S#12), E#10 |-> {X#23=C#22[(var X#2)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#17=A#19[(app (letrec {X#23=C#22[(var X#2)];E#25} in S#12) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {X#23=C#22[(var X#2)];E#25} in S#12) S#11)];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {X#23=C#22[(var X#2)];E#25} in (app S#12 S#11))];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#10} in S#12) C#21[(var X#3)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {E#10} in (app S#12 C#21[(var X#2)]))] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#20,A#16,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app (letrec {E#10} in S#12) C#21)]), ((var X#3),A#19[(app (letrec {E#10} in S#12) C#21)]), (C#21[(var X#2)],(letrec {E#10} in [.])), ((var X#2),A#19[(app (letrec {E#10} in S#12) C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, C#7 |-> A#19[(app (letrec {E#10} in S#12) C#21)], C#20 |-> (app (letrec {E#10} in S#12) C#21), S#11 |-> C#21[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#10} in S#12) C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app (letrec {E#10} in S#12) C#21[(var X#3)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#10} in S#12) C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#10} in (app S#12 C#21[(var X#2)]))];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#3)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] C#21[(var X#2)])] ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,C#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21)]), ((var X#3),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21)]), (S#11,(letrec {E#10} in [.])), ((var X#2),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] C#21[(var X#2)])];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, C#7 |-> A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21)], A#16 |-> A#19[(app A#20 C#21[(var X#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#3)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] C#21[(var X#2)])];X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#10} in C#20[(var X#3)]) S#11) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {E#10} in (app C#20[(var X#2)] S#11)) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in C#20) S#11)), ((var X#3),(app (letrec {E#10} in C#20) S#11)), (S#11,(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in C#20[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], C#7 |-> (app (letrec {E#10} in C#20) S#11), C#19 |-> (letrec {E#10} in C#20), S#12 |-> C#20[(var X#2)]} and instantiated rules: (letrec {X#17=(app (letrec {E#10} in C#20[(var X#2)]) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=(app (letrec {E#10} in C#20[(var X#3)]) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (letrec {E#10} in C#20[(var X#2)]) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=(letrec {E#10} in (app C#20[(var X#2)] S#11));X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {X#21=C#20[(var X#3)];E#23} in S#12) S#11) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {X#21=C#20[(var X#2)];E#23} in (app S#12 S#11)) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {X#21=C#20;E#23} in S#12) S#11)), ((var X#3),(app (letrec {X#21=C#20;E#23} in S#12) S#11)), (S#11,(letrec {X#21=C#20[(var X#2)];E#23} in [.])), ((var X#2),(app (letrec {X#21=C#20[[.]];E#23} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], C#7 |-> (app (letrec {X#21=C#20;E#23} in S#12) S#11), C#19 |-> (letrec {X#21=C#20;E#23} in S#12), E#10 |-> {X#21=C#20[(var X#2)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#17=(app (letrec {X#21=C#20[(var X#2)];E#23} in S#12) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=(app (letrec {X#21=C#20[(var X#3)];E#23} in S#12) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (letrec {X#21=C#20[(var X#2)];E#23} in S#12) S#11);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=(letrec {X#21=C#20[(var X#2)];E#23} in (app S#12 S#11));X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#10} in S#12) C#19[(var X#3)]) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {E#10} in (app S#12 C#19[(var X#2)])) ;X#2= (var X#3) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in S#12) C#19)), ((var X#3),(app (letrec {E#10} in S#12) C#19)), (C#19[(var X#2)],(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in S#12) C#19[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=(var X#3);E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#4 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], C#7 |-> (app (letrec {E#10} in S#12) C#19), S#11 |-> C#19[(var X#2)]} and instantiated rules: (letrec {X#17=(app (letrec {E#10} in S#12) C#19[(var X#2)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#17=(app (letrec {E#10} in S#12) C#19[(var X#3)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (letrec {E#10} in S#12) C#19[(var X#2)]);X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=(letrec {E#10} in (app S#12 C#19[(var X#2)]));X#2=(var X#3);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#8= (var X#3) ;E#18 ;EE#17[X#3,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= C#7[(var X#8)] ;X#8= (var X#3) ;E#18 ;EE#17[X#3,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#8),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#8),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {[.1]=(var X#3);EE#17[X#3,[.2]]}, X#2 |-> X#8, E#9 |-> {X#1=C#7[(var X#8)];E#18}, E#4 |-> {E#18;EE#17[X#3,(app (letrec {E#10} in S#12) S#11)]}, A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#8)];X#8=(var X#3);E#18;EE#17[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#8=(var X#3);E#18;EE#17[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#8)];X#8=(var X#3);E#18;EE#17[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#1=C#7[(var X#8)];X#8=(var X#3);E#18;EE#17[X#3,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app (letrec {E#10} in C#22[(var X#3)]) S#11)] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= A#19[(letrec {E#10} in (app C#22[(var X#8)] S#11))] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#20,A#18,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#8),A#19[(app (letrec {E#10} in C#22) S#11)]), ((var X#3),A#19[(app (letrec {E#10} in C#22) S#11)]), (S#11,(letrec {E#10} in [.])), ((var X#8),A#19[(app (letrec {E#10} in C#22[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[[.2]];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#3, E#4 |-> {E#9}, A#18 |-> A#19, C#7 |-> A#19[(app (letrec {E#10} in C#22) S#11)], A#15 |-> [.], X#16 |-> X#3, C#20 |-> (app (letrec {E#10} in C#22) S#11), C#21 |-> (letrec {E#10} in C#22), S#12 |-> C#22[(var X#8)]} and instantiated rules: (letrec {X#3=A#19[(app (letrec {E#10} in C#22[(var X#8)]) S#11)];X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app (letrec {E#10} in C#22[(var X#3)]) S#11)];X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app (letrec {E#10} in C#22[(var X#8)]) S#11)];X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=A#19[(letrec {E#10} in (app C#22[(var X#8)] S#11))];X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11)] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= A#19[(letrec {X#23=C#22[(var X#8)];E#25} in (app S#12 S#11))] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#20,A#18,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#8),A#19[(app (letrec {X#23=C#22;E#25} in S#12) S#11)]), ((var X#3),A#19[(app (letrec {X#23=C#22;E#25} in S#12) S#11)]), (S#11,(letrec {X#23=C#22[(var X#8)];E#25} in [.])), ((var X#8),A#19[(app (letrec {X#23=C#22[[.]];E#25} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[[.2]];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#3, E#4 |-> {E#9}, A#18 |-> A#19, C#7 |-> A#19[(app (letrec {X#23=C#22;E#25} in S#12) S#11)], A#15 |-> [.], X#16 |-> X#3, C#20 |-> (app (letrec {X#23=C#22;E#25} in S#12) S#11), C#21 |-> (letrec {X#23=C#22;E#25} in S#12), E#10 |-> {X#23=C#22[(var X#8)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#3=A#19[(app (letrec {X#23=C#22[(var X#8)];E#25} in S#12) S#11)];X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11)];X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app (letrec {X#23=C#22[(var X#8)];E#25} in S#12) S#11)];X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=A#19[(letrec {X#23=C#22[(var X#8)];E#25} in (app S#12 S#11))];X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app (letrec {E#10} in S#12) C#21[(var X#3)])] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= A#19[(letrec {E#10} in (app S#12 C#21[(var X#8)]))] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {C#20,A#18,C#7,A#19} Delta2 = {E#10} Delta3 = {((var X#8),A#19[(app (letrec {E#10} in S#12) C#21)]), ((var X#3),A#19[(app (letrec {E#10} in S#12) C#21)]), (C#21[(var X#8)],(letrec {E#10} in [.])), ((var X#8),A#19[(app (letrec {E#10} in S#12) C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[[.2]];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#3, E#4 |-> {E#9}, A#18 |-> A#19, C#7 |-> A#19[(app (letrec {E#10} in S#12) C#21)], A#15 |-> [.], X#16 |-> X#3, C#20 |-> (app (letrec {E#10} in S#12) C#21), S#11 |-> C#21[(var X#8)]} and instantiated rules: (letrec {X#3=A#19[(app (letrec {E#10} in S#12) C#21[(var X#8)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app (letrec {E#10} in S#12) C#21[(var X#3)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app (letrec {E#10} in S#12) C#21[(var X#8)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=A#19[(letrec {E#10} in (app S#12 C#21[(var X#8)]))];X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#3)])] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] C#21[(var X#8)])] ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#8),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21)]), ((var X#3),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21)]), (S#11,(letrec {E#10} in [.])), ((var X#8),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#19[(app A#20[[.2]] C#21[(var X#8)])];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] C#21[(var X#8)])]}, X#1 |-> X#3, E#4 |-> {E#9}, C#7 |-> A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21)], A#18 |-> A#19[(app A#20 C#21[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#8)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#3)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] C#21[(var X#8)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] C#21[(var X#8)])];X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= (app (letrec {E#10} in C#20[(var X#3)]) S#11) ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= (letrec {E#10} in (app C#20[(var X#8)] S#11)) ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#7} Delta2 = {E#10} Delta3 = {((var X#8),(app (letrec {E#10} in C#20) S#11)), ((var X#3),(app (letrec {E#10} in C#20) S#11)), (S#11,(letrec {E#10} in [.])), ((var X#8),(app (letrec {E#10} in C#20[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#9}, A#18 |-> [.], C#7 |-> (app (letrec {E#10} in C#20) S#11), C#19 |-> (letrec {E#10} in C#20), S#12 |-> C#20[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=(app (letrec {E#10} in C#20[(var X#8)]) S#11);X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=(app (letrec {E#10} in C#20[(var X#3)]) S#11);X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=(app (letrec {E#10} in C#20[(var X#8)]) S#11);X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=(letrec {E#10} in (app C#20[(var X#8)] S#11));X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= (app (letrec {X#21=C#20[(var X#3)];E#23} in S#12) S#11) ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= (letrec {X#21=C#20[(var X#8)];E#23} in (app S#12 S#11)) ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {C#19,C#7} Delta2 = {E#10} Delta3 = {((var X#8),(app (letrec {X#21=C#20;E#23} in S#12) S#11)), ((var X#3),(app (letrec {X#21=C#20;E#23} in S#12) S#11)), (S#11,(letrec {X#21=C#20[(var X#8)];E#23} in [.])), ((var X#8),(app (letrec {X#21=C#20[[.]];E#23} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#9}, A#18 |-> [.], C#7 |-> (app (letrec {X#21=C#20;E#23} in S#12) S#11), C#19 |-> (letrec {X#21=C#20;E#23} in S#12), E#10 |-> {X#21=C#20[(var X#8)];E#23}, E#22 |-> {E#23}, A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=(app (letrec {X#21=C#20[(var X#8)];E#23} in S#12) S#11);X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=(app (letrec {X#21=C#20[(var X#3)];E#23} in S#12) S#11);X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=(app (letrec {X#21=C#20[(var X#8)];E#23} in S#12) S#11);X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=(letrec {X#21=C#20[(var X#8)];E#23} in (app S#12 S#11));X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= (app (letrec {E#10} in S#12) C#19[(var X#3)]) ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) , (letrec X#3= (letrec {E#10} in (app S#12 C#19[(var X#8)])) ;X#8= (var X#3) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#8),(app (letrec {E#10} in S#12) C#19)), ((var X#3),(app (letrec {E#10} in S#12) C#19)), (C#19[(var X#8)],(letrec {E#10} in [.])), ((var X#8),(app (letrec {E#10} in S#12) C#19[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=[.2];[.1]=(var X#3)}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#9}, A#18 |-> [.], C#7 |-> (app (letrec {E#10} in S#12) C#19), S#11 |-> C#19[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=(app (letrec {E#10} in S#12) C#19[(var X#8)]);X#8=(var X#3);E#9} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=(app (letrec {E#10} in S#12) C#19[(var X#3)]);X#8=(var X#3);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=(app (letrec {E#10} in S#12) C#19[(var X#8)]);X#8=(var X#3);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=(letrec {E#10} in (app S#12 C#19[(var X#8)]));X#8=(var X#3);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#3= A#21[(app A#22[(var X#19)] C#23[(var X#3)])] ;X#8= (var X#3) ;E#9 ;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#3= A#21[(app A#22[(var X#19)] C#23[(var X#8)])] ;X#8= (var X#3) ;E#9 ;EE#20[X#19,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#8),A#21[(app A#22[(var X#19)] C#23)]), ((var X#3),A#21[(app A#22[(var X#19)] C#23)]), (S#11,(letrec {E#10} in [.])), ((var X#8),A#21[(app A#22[(var X#19)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];[.1]=(var X#3);EE#20[X#19,[.2]]}, X#2 |-> X#8, EE#17[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];EE#20[X#19,[.2]]}, X#1 |-> X#3, E#4 |-> {E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#21[(app A#22[(var X#19)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#3)])];X#8=(var X#3);E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#3=A#21[(app A#22[(var X#19)] C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#19,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#3)])] ;X#8= (var X#3) ;E#9 ;EE#21[X#3,(var X#19)] ;EE#22[X#20,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] C#25[(var X#8)])] ;X#8= (var X#3) ;E#9 ;EE#21[X#3,(var X#19)] ;EE#22[X#20,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#8),A#23[(app A#24[(var X#20)] C#25)]), ((var X#3),A#23[(app A#24[(var X#20)] C#25)]), (S#11,(letrec {E#10} in [.])), ((var X#8),A#23[(app A#24[(var X#20)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];[.1]=(var X#3);EE#21[X#3,(var X#19)];EE#22[X#20,[.2]]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#1 |-> X#19, E#4 |-> {E#9;EE#21[X#3,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#23[(app A#24[(var X#20)] C#25)], A#18 |-> A#23[(app A#24 C#25[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];X#8=(var X#3);E#9;EE#21[X#3,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#3)])];X#8=(var X#3);E#9;EE#21[X#3,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];X#8=(var X#3);E#9;EE#21[X#3,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#23[(app A#24[(var X#20)] C#25[(var X#8)])];X#8=(var X#3);E#9;EE#21[X#3,(var X#19)];EE#22[X#20,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {E#10} in C#24[(var X#3)]) S#11)] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {E#10} in (app C#24[(var X#8)] S#11))] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#22,A#18,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#8),A#21[(app (letrec {E#10} in C#24) S#11)]), ((var X#3),A#21[(app (letrec {E#10} in C#24) S#11)]), (S#11,(letrec {E#10} in [.])), ((var X#8),A#21[(app (letrec {E#10} in C#24[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[[.2]];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, A#18 |-> A#21, C#7 |-> A#21[(app (letrec {E#10} in C#24) S#11)], A#15 |-> [.], X#16 |-> X#3, C#22 |-> (app (letrec {E#10} in C#24) S#11), C#23 |-> (letrec {E#10} in C#24), S#12 |-> C#24[(var X#8)]} and instantiated rules: (letrec {X#19=A#21[(app (letrec {E#10} in C#24[(var X#8)]) S#11)];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {E#10} in C#24[(var X#3)]) S#11)];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {E#10} in C#24[(var X#8)]) S#11)];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {E#10} in (app C#24[(var X#8)] S#11))];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {X#25=C#24[(var X#3)];E#27} in S#12) S#11)] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {X#25=C#24[(var X#8)];E#27} in (app S#12 S#11))] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#22,A#18,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#8),A#21[(app (letrec {X#25=C#24;E#27} in S#12) S#11)]), ((var X#3),A#21[(app (letrec {X#25=C#24;E#27} in S#12) S#11)]), (S#11,(letrec {X#25=C#24[(var X#8)];E#27} in [.])), ((var X#8),A#21[(app (letrec {X#25=C#24[[.]];E#27} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[[.2]];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, A#18 |-> A#21, C#7 |-> A#21[(app (letrec {X#25=C#24;E#27} in S#12) S#11)], A#15 |-> [.], X#16 |-> X#3, C#22 |-> (app (letrec {X#25=C#24;E#27} in S#12) S#11), C#23 |-> (letrec {X#25=C#24;E#27} in S#12), E#10 |-> {X#25=C#24[(var X#8)];E#27}, E#26 |-> {E#27}} and instantiated rules: (letrec {X#19=A#21[(app (letrec {X#25=C#24[(var X#8)];E#27} in S#12) S#11)];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {X#25=C#24[(var X#3)];E#27} in S#12) S#11)];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {X#25=C#24[(var X#8)];E#27} in S#12) S#11)];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {X#25=C#24[(var X#8)];E#27} in (app S#12 S#11))];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {E#10} in S#12) C#23[(var X#3)])] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {E#10} in (app S#12 C#23[(var X#8)]))] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#22,A#18,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#8),A#21[(app (letrec {E#10} in S#12) C#23)]), ((var X#3),A#21[(app (letrec {E#10} in S#12) C#23)]), (C#23[(var X#8)],(letrec {E#10} in [.])), ((var X#8),A#21[(app (letrec {E#10} in S#12) C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[[.2]];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, A#18 |-> A#21, C#7 |-> A#21[(app (letrec {E#10} in S#12) C#23)], A#15 |-> [.], X#16 |-> X#3, C#22 |-> (app (letrec {E#10} in S#12) C#23), S#11 |-> C#23[(var X#8)]} and instantiated rules: (letrec {X#19=A#21[(app (letrec {E#10} in S#12) C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app (letrec {E#10} in S#12) C#23[(var X#3)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {E#10} in S#12) C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {E#10} in (app S#12 C#23[(var X#8)]))];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#3)])] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] C#23[(var X#8)])] ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,C#7} Delta2 = {E#10} Delta3 = {((var X#8),A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23)]), ((var X#3),A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23)]), (S#11,(letrec {E#10} in [.])), ((var X#8),A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#8)])];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] C#23[(var X#8)])];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, C#7 |-> A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23)], A#18 |-> A#21[(app A#22 C#23[(var X#8)])], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#3)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] C#23[(var X#8)])];X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {E#10} in C#22[(var X#3)]) S#11) ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {E#10} in (app C#22[(var X#8)] S#11)) ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#7} Delta2 = {E#10} Delta3 = {((var X#8),(app (letrec {E#10} in C#22) S#11)), ((var X#3),(app (letrec {E#10} in C#22) S#11)), (S#11,(letrec {E#10} in [.])), ((var X#8),(app (letrec {E#10} in C#22[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=[.2];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, A#18 |-> [.], C#7 |-> (app (letrec {E#10} in C#22) S#11), C#21 |-> (letrec {E#10} in C#22), S#12 |-> C#22[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=(app (letrec {E#10} in C#22[(var X#8)]) S#11);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {E#10} in C#22[(var X#3)]) S#11);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {E#10} in C#22[(var X#8)]) S#11);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {E#10} in (app C#22[(var X#8)] S#11));X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11) ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {X#23=C#22[(var X#8)];E#25} in (app S#12 S#11)) ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#7} Delta2 = {E#10} Delta3 = {((var X#8),(app (letrec {X#23=C#22;E#25} in S#12) S#11)), ((var X#3),(app (letrec {X#23=C#22;E#25} in S#12) S#11)), (S#11,(letrec {X#23=C#22[(var X#8)];E#25} in [.])), ((var X#8),(app (letrec {X#23=C#22[[.]];E#25} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=[.2];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, A#18 |-> [.], C#7 |-> (app (letrec {X#23=C#22;E#25} in S#12) S#11), C#21 |-> (letrec {X#23=C#22;E#25} in S#12), E#10 |-> {X#23=C#22[(var X#8)];E#25}, E#24 |-> {E#25}, A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=(app (letrec {X#23=C#22[(var X#8)];E#25} in S#12) S#11);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {X#23=C#22[(var X#8)];E#25} in S#12) S#11);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {X#23=C#22[(var X#8)];E#25} in (app S#12 S#11));X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {E#10} in S#12) C#21[(var X#3)]) ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {E#10} in (app S#12 C#21[(var X#8)])) ;X#8= (var X#3) ;E#9 ;EE#20[X#3,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#8),(app (letrec {E#10} in S#12) C#21)), ((var X#3),(app (letrec {E#10} in S#12) C#21)), (C#21[(var X#8)],(letrec {E#10} in [.])), ((var X#8),(app (letrec {E#10} in S#12) C#21[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#19=[.2];[.1]=(var X#3);EE#20[X#3,(var X#19)]}, X#2 |-> X#8, EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#4 |-> {E#9;EE#20[X#3,(var X#19)]}, A#18 |-> [.], C#7 |-> (app (letrec {E#10} in S#12) C#21), S#11 |-> C#21[(var X#8)], A#15 |-> [.], X#16 |-> X#3} and instantiated rules: (letrec {X#19=(app (letrec {E#10} in S#12) C#21[(var X#8)]);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#19=(app (letrec {E#10} in S#12) C#21[(var X#3)]);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {E#10} in S#12) C#21[(var X#8)]);X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {E#10} in (app S#12 C#21[(var X#8)]));X#8=(var X#3);E#9;EE#20[X#3,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= C#7[(var X#3)] ;X#16= (var X#3) ;E#20 ;EE#18[X#8,(var X#16)] ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= C#7[(var X#16)] ;X#16= (var X#3) ;E#20 ;EE#18[X#8,(var X#16)] ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),C#7), ((var X#3),C#7), (S#11,(letrec {E#10} in [.])), ((var X#16),C#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);EE#18[[.1],(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, E#9 |-> {X#1=C#7[(var X#16)];E#20}, E#4 |-> {E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]}, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#1=C#7[(var X#3)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#1=C#7[(var X#16)];X#16=(var X#3);E#20;EE#18[X#8,(var X#16)];EE#19[X#3,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#21[(var X#3)] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#21[(var X#16)] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), ((var X#3),A#21[[.]]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]}, A#20 |-> A#21, C#7 |-> A#21[[.]], A#15 |-> [.], X#17 |-> X#3, C#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#21[(var X#3)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#21[(var X#3)] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#21[(var X#16)] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), ((var X#3),A#21), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(var X#16)];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]}, A#20 |-> A#21[[.]], C#7 |-> A#21, A#15 |-> [.], X#17 |-> X#3, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#21[(var X#3)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#8=A#21[(var X#16)];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#21[(app A#22[(var X#16)] C#23[(var X#3)])] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#21[(app A#22[(var X#16)] C#23[(var X#16)])] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app A#22[(var X#16)] C#23)]), ((var X#3),A#21[(app A#22[(var X#16)] C#23)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[(app A#22[(var X#16)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#16)])]}, X#1 |-> X#8, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#21[(app A#22[(var X#16)] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#3)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#8=A#21[(app A#22[(var X#16)] C#23[(var X#16)])];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= (var X#3) ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= (var X#16) ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), ((var X#3),[.]), (S#11,(letrec {E#10} in [.])), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=(var X#16);EE#19[X#3,[.2]]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> [.], A#20 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=(var X#16);E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=(var X#3);E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=(var X#16);E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#8=(var X#16);E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#8= A#23[(app A#24[(var X#21)] C#25[(var X#3)])] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#21,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#8= A#23[(app A#24[(var X#21)] C#25[(var X#16)])] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#21,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#21)] C#25)]), ((var X#3),A#23[(app A#24[(var X#21)] C#25)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#19[X#3,[.2]];EE#22[X#21,(var X#16)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#22[X#21,[.2]]}, X#1 |-> X#8, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#21,(var X#16)]}, C#7 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#3)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#8=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))];EE#22[X#21,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#3)])] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] ;EE#23[X#8,(var X#21)] ;EE#24[X#22,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#16)])] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] ;EE#23[X#8,(var X#21)] ;EE#24[X#22,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#25[(app A#26[(var X#22)] C#27)]), ((var X#3),A#25[(app A#26[(var X#22)] C#27)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#19[X#3,[.2]];EE#23[[.1],(var X#21)];EE#24[X#22,(var X#16)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]}, C#7 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#3)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))];EE#23[X#8,(var X#21)];EE#24[X#22,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(var X#3)] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(var X#16)] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[[.]]), ((var X#3),A#23[[.]]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(var X#16)];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[[.]], A#15 |-> [.], X#17 |-> X#3, C#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(var X#3)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(var X#3)] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(var X#16)] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23), ((var X#3),A#23), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(var X#16)];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23[[.]], C#7 |-> A#23, A#15 |-> [.], X#17 |-> X#3, A#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(var X#3)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(var X#16)];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#16)] C#25[(var X#3)])] ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(var X#16)] C#25[(var X#16)])] ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#16)] C#25)]), ((var X#3),A#23[(app A#24[(var X#16)] C#25)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[(app A#24[(var X#16)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, C#7 |-> A#23[(app A#24[(var X#16)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#3)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(var X#16)] C#25[(var X#16)])];E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (var X#3) ;E#9 ;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (var X#16) ;E#9 ;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), ((var X#3),[.]), (S#11,(letrec {E#10} in [.])), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=(var X#16);EE#19[X#3,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, EE#18[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, C#7 |-> [.], A#20 |-> [.], X#16 |-> X#16, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(var X#16);E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(var X#3);E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(var X#16);E#9;EE#19[X#3,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=(var X#16);E#9;EE#19[X#3,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app (letrec {E#10} in C#24[(var X#3)]) S#11)] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(letrec {E#10} in (app C#24[(var X#16)] S#11))] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#22,A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app (letrec {E#10} in C#24) S#11)]), ((var X#3),A#21[(app (letrec {E#10} in C#24) S#11)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[(app (letrec {E#10} in C#24[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[[.2]];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, A#20 |-> A#21, C#7 |-> A#21[(app (letrec {E#10} in C#24) S#11)], A#15 |-> [.], X#17 |-> X#3, C#22 |-> (app (letrec {E#10} in C#24) S#11), C#23 |-> (letrec {E#10} in C#24), S#12 |-> C#24[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {E#10} in C#24[(var X#16)]) S#11)];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {E#10} in C#24[(var X#3)]) S#11)];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {E#10} in C#24[(var X#16)]) S#11)];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=A#21[(letrec {E#10} in (app C#24[(var X#16)] S#11))];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app (letrec {X#25=C#24[(var X#3)];E#27} in S#12) S#11)] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(letrec {X#25=C#24[(var X#16)];E#27} in (app S#12 S#11))] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#22,A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app (letrec {X#25=C#24;E#27} in S#12) S#11)]), ((var X#3),A#21[(app (letrec {X#25=C#24;E#27} in S#12) S#11)]), (S#11,(letrec {X#25=C#24[(var X#16)];E#27} in [.])), ((var X#16),A#21[(app (letrec {X#25=C#24[[.]];E#27} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[[.2]];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, A#20 |-> A#21, C#7 |-> A#21[(app (letrec {X#25=C#24;E#27} in S#12) S#11)], A#15 |-> [.], X#17 |-> X#3, C#22 |-> (app (letrec {X#25=C#24;E#27} in S#12) S#11), C#23 |-> (letrec {X#25=C#24;E#27} in S#12), E#10 |-> {X#25=C#24[(var X#16)];E#27}, E#26 |-> {E#27}} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {X#25=C#24[(var X#16)];E#27} in S#12) S#11)];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {X#25=C#24[(var X#3)];E#27} in S#12) S#11)];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {X#25=C#24[(var X#16)];E#27} in S#12) S#11)];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=A#21[(letrec {X#25=C#24[(var X#16)];E#27} in (app S#12 S#11))];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app (letrec {E#10} in S#12) C#23[(var X#3)])] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(letrec {E#10} in (app S#12 C#23[(var X#16)]))] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#22,A#20,C#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app (letrec {E#10} in S#12) C#23)]), ((var X#3),A#21[(app (letrec {E#10} in S#12) C#23)]), (C#23[(var X#16)],(letrec {E#10} in [.])), ((var X#16),A#21[(app (letrec {E#10} in S#12) C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[[.2]];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, A#20 |-> A#21, C#7 |-> A#21[(app (letrec {E#10} in S#12) C#23)], A#15 |-> [.], X#17 |-> X#3, C#22 |-> (app (letrec {E#10} in S#12) C#23), S#11 |-> C#23[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {E#10} in S#12) C#23[(var X#16)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {E#10} in S#12) C#23[(var X#3)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app (letrec {E#10} in S#12) C#23[(var X#16)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=A#21[(letrec {E#10} in (app S#12 C#23[(var X#16)]))];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#3)])] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] C#23[(var X#16)])] ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23)]), ((var X#3),A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#21[(app A#22[[.2]] C#23[(var X#16)])];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] C#23[(var X#16)])]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, C#7 |-> A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23)], A#20 |-> A#21[(app A#22 C#23[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#16)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#3)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] C#23[(var X#16)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] C#23[(var X#16)])];E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (app (letrec {E#10} in C#22[(var X#3)]) S#11) ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in (app C#22[(var X#16)] S#11)) ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#7} Delta2 = {E#10} Delta3 = {((var X#16),(app (letrec {E#10} in C#22) S#11)), ((var X#3),(app (letrec {E#10} in C#22) S#11)), (S#11,(letrec {E#10} in [.])), ((var X#16),(app (letrec {E#10} in C#22[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=[.2];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, A#20 |-> [.], C#7 |-> (app (letrec {E#10} in C#22) S#11), C#21 |-> (letrec {E#10} in C#22), S#12 |-> C#22[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(app (letrec {E#10} in C#22[(var X#16)]) S#11);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(app (letrec {E#10} in C#22[(var X#3)]) S#11);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(app (letrec {E#10} in C#22[(var X#16)]) S#11);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=(letrec {E#10} in (app C#22[(var X#16)] S#11));E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11) ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= (letrec {X#23=C#22[(var X#16)];E#25} in (app S#12 S#11)) ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#21,C#7} Delta2 = {E#10} Delta3 = {((var X#16),(app (letrec {X#23=C#22;E#25} in S#12) S#11)), ((var X#3),(app (letrec {X#23=C#22;E#25} in S#12) S#11)), (S#11,(letrec {X#23=C#22[(var X#16)];E#25} in [.])), ((var X#16),(app (letrec {X#23=C#22[[.]];E#25} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=[.2];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, A#20 |-> [.], C#7 |-> (app (letrec {X#23=C#22;E#25} in S#12) S#11), C#21 |-> (letrec {X#23=C#22;E#25} in S#12), E#10 |-> {X#23=C#22[(var X#16)];E#25}, E#24 |-> {E#25}, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(app (letrec {X#23=C#22[(var X#16)];E#25} in S#12) S#11);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(app (letrec {X#23=C#22[(var X#3)];E#25} in S#12) S#11);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(app (letrec {X#23=C#22[(var X#16)];E#25} in S#12) S#11);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=(letrec {X#23=C#22[(var X#16)];E#25} in (app S#12 S#11));E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= (app (letrec {E#10} in S#12) C#21[(var X#3)]) ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= (letrec {E#10} in (app S#12 C#21[(var X#16)])) ;E#9 ;EE#18[X#8,(var X#16)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#16),(app (letrec {E#10} in S#12) C#21)), ((var X#3),(app (letrec {E#10} in S#12) C#21)), (C#21[(var X#16)],(letrec {E#10} in [.])), ((var X#16),(app (letrec {E#10} in S#12) C#21[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=[.2];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)]}, A#20 |-> [.], C#7 |-> (app (letrec {E#10} in S#12) C#21), S#11 |-> C#21[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=(app (letrec {E#10} in S#12) C#21[(var X#16)]);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=(app (letrec {E#10} in S#12) C#21[(var X#3)]);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=(app (letrec {E#10} in S#12) C#21[(var X#16)]);E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=(letrec {E#10} in (app S#12 C#21[(var X#16)]));E#9;EE#18[X#8,(var X#16)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#3= A#23[(app A#24[(var X#21)] C#25[(var X#3)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#21,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#3= A#23[(app A#24[(var X#21)] C#25[(var X#16)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#21,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(var X#21)] C#25)]), ((var X#3),A#23[(app A#24[(var X#21)] C#25)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[(app A#24[(var X#21)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#18[[.1],(var X#16)];EE#22[X#21,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];EE#22[X#21,[.2]]}, X#1 |-> X#3, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#21,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#23[(app A#24[(var X#21)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#21,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#3)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#21,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#21,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#3=A#23[(app A#24[(var X#21)] C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#21,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#3)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#23[X#3,(var X#21)] ;EE#24[X#22,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#25[(app A#26[(var X#22)] C#27[(var X#16)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#23[X#3,(var X#21)] ;EE#24[X#22,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#25[(app A#26[(var X#22)] C#27)]), ((var X#3),A#25[(app A#26[(var X#22)] C#27)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#25[(app A#26[(var X#22)] C#27[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#18[[.1],(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (letrec {E#10} in S#12) S#11)]}, C#7 |-> A#25[(app A#26[(var X#22)] C#27)], A#20 |-> A#25[(app A#26 C#27[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#3)])];E#9;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#25[(app A#26[(var X#22)] C#27[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#23[X#3,(var X#21)];EE#24[X#22,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app (letrec {E#10} in C#26[(var X#3)]) S#11)] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(letrec {E#10} in (app C#26[(var X#16)] S#11))] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#25,C#24,A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app (letrec {E#10} in C#26) S#11)]), ((var X#3),A#23[(app (letrec {E#10} in C#26) S#11)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[(app (letrec {E#10} in C#26[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[[.2]];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[(app (letrec {E#10} in C#26) S#11)], A#15 |-> [.], X#17 |-> X#3, C#24 |-> (app (letrec {E#10} in C#26) S#11), C#25 |-> (letrec {E#10} in C#26), S#12 |-> C#26[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {E#10} in C#26[(var X#16)]) S#11)];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {E#10} in C#26[(var X#3)]) S#11)];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {E#10} in C#26[(var X#16)]) S#11)];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(letrec {E#10} in (app C#26[(var X#16)] S#11))];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app (letrec {X#27=C#26[(var X#3)];E#29} in S#12) S#11)] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(letrec {X#27=C#26[(var X#16)];E#29} in (app S#12 S#11))] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#25,C#24,A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app (letrec {X#27=C#26;E#29} in S#12) S#11)]), ((var X#3),A#23[(app (letrec {X#27=C#26;E#29} in S#12) S#11)]), (S#11,(letrec {X#27=C#26[(var X#16)];E#29} in [.])), ((var X#16),A#23[(app (letrec {X#27=C#26[[.]];E#29} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[[.2]];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[(app (letrec {X#27=C#26;E#29} in S#12) S#11)], A#15 |-> [.], X#17 |-> X#3, C#24 |-> (app (letrec {X#27=C#26;E#29} in S#12) S#11), C#25 |-> (letrec {X#27=C#26;E#29} in S#12), E#10 |-> {X#27=C#26[(var X#16)];E#29}, E#28 |-> {E#29}} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {X#27=C#26[(var X#16)];E#29} in S#12) S#11)];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {X#27=C#26[(var X#3)];E#29} in S#12) S#11)];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {X#27=C#26[(var X#16)];E#29} in S#12) S#11)];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(letrec {X#27=C#26[(var X#16)];E#29} in (app S#12 S#11))];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app (letrec {E#10} in S#12) C#25[(var X#3)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(letrec {E#10} in (app S#12 C#25[(var X#16)]))] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#24,A#20,C#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app (letrec {E#10} in S#12) C#25)]), ((var X#3),A#23[(app (letrec {E#10} in S#12) C#25)]), (C#25[(var X#16)],(letrec {E#10} in [.])), ((var X#16),A#23[(app (letrec {E#10} in S#12) C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[[.2]];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> A#23, C#7 |-> A#23[(app (letrec {E#10} in S#12) C#25)], A#15 |-> [.], X#17 |-> X#3, C#24 |-> (app (letrec {E#10} in S#12) C#25), S#11 |-> C#25[(var X#16)]} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {E#10} in S#12) C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {E#10} in S#12) C#25[(var X#3)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app (letrec {E#10} in S#12) C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(letrec {E#10} in (app S#12 C#25[(var X#16)]))];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25[(var X#3)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= A#23[(app A#24[(letrec {E#10} in (app S#12 S#11))] C#25[(var X#16)])] ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,C#7} Delta2 = {E#10} Delta3 = {((var X#16),A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25)]), ((var X#3),A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25)]), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] C#25[(var X#16)])];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, C#7 |-> A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25)], A#20 |-> A#23[(app A#24 C#25[(var X#16)])], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25[(var X#3)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(app (letrec {E#10} in S#12) S#11)] C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=A#23[(app A#24[(letrec {E#10} in (app S#12 S#11))] C#25[(var X#16)])];E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (app (letrec {E#10} in C#24[(var X#3)]) S#11) ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (letrec {E#10} in (app C#24[(var X#16)] S#11)) ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#7} Delta2 = {E#10} Delta3 = {((var X#16),(app (letrec {E#10} in C#24) S#11)), ((var X#3),(app (letrec {E#10} in C#24) S#11)), (S#11,(letrec {E#10} in [.])), ((var X#16),(app (letrec {E#10} in C#24[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=[.2];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> [.], C#7 |-> (app (letrec {E#10} in C#24) S#11), C#23 |-> (letrec {E#10} in C#24), S#12 |-> C#24[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(app (letrec {E#10} in C#24[(var X#16)]) S#11);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(app (letrec {E#10} in C#24[(var X#3)]) S#11);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(app (letrec {E#10} in C#24[(var X#16)]) S#11);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=(letrec {E#10} in (app C#24[(var X#16)] S#11));E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (app (letrec {X#25=C#24[(var X#3)];E#27} in S#12) S#11) ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (letrec {X#25=C#24[(var X#16)];E#27} in (app S#12 S#11)) ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#23,C#7} Delta2 = {E#10} Delta3 = {((var X#16),(app (letrec {X#25=C#24;E#27} in S#12) S#11)), ((var X#3),(app (letrec {X#25=C#24;E#27} in S#12) S#11)), (S#11,(letrec {X#25=C#24[(var X#16)];E#27} in [.])), ((var X#16),(app (letrec {X#25=C#24[[.]];E#27} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=[.2];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> [.], C#7 |-> (app (letrec {X#25=C#24;E#27} in S#12) S#11), C#23 |-> (letrec {X#25=C#24;E#27} in S#12), E#10 |-> {X#25=C#24[(var X#16)];E#27}, E#26 |-> {E#27}, A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(app (letrec {X#25=C#24[(var X#16)];E#27} in S#12) S#11);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(app (letrec {X#25=C#24[(var X#3)];E#27} in S#12) S#11);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(app (letrec {X#25=C#24[(var X#16)];E#27} in S#12) S#11);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=(letrec {X#25=C#24[(var X#16)];E#27} in (app S#12 S#11));E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#3) ;X#21= (app (letrec {E#10} in S#12) C#23[(var X#3)]) ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= (var X#3) ;X#21= (letrec {E#10} in (app S#12 C#23[(var X#16)])) ;E#9 ;EE#18[X#8,(var X#16)] ;EE#22[X#3,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {C#7} Delta2 = {E#10} Delta3 = {((var X#16),(app (letrec {E#10} in S#12) C#23)), ((var X#3),(app (letrec {E#10} in S#12) C#23)), (C#23[(var X#16)],(letrec {E#10} in [.])), ((var X#16),(app (letrec {E#10} in S#12) C#23[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -cpx-e1-> with input rules: T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] <-cpx-e1- T#6[(letrec {X#1=C#7[(var X#3)];X#2=(var X#3);E#4} in S#5)] and constraints: ((var X#2),C#7), ((var X#3),C#7) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=C#7[(var X#2)];X#2=(var X#3);E#4} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),C#7),((var X#3),C#7),(S#11,(letrec {E#10} in [.])),((var X#2),C#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=(var X#3);X#21=[.2];EE#18[[.1],(var X#16)];EE#22[X#3,(var X#21)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#4 |-> {E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]}, A#20 |-> [.], C#7 |-> (app (letrec {E#10} in S#12) C#23), S#11 |-> C#23[(var X#16)], A#15 |-> [.], X#17 |-> X#3} and instantiated rules: (letrec {X#16=(var X#3);X#21=(app (letrec {E#10} in S#12) C#23[(var X#16)]);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) <-cpx-e1- (letrec {X#16=(var X#3);X#21=(app (letrec {E#10} in S#12) C#23[(var X#3)]);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=(var X#3);X#21=(app (letrec {E#10} in S#12) C#23[(var X#16)]);E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=(var X#3);X#21=(letrec {E#10} in (app S#12 C#23[(var X#16)]));E#9;EE#18[X#8,(var X#16)];EE#22[X#3,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] , A#11[(letrec {X#7=T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#9)] ) where Delta1 = {T#12,A#10,T#6,A#11} Delta2 = {} Delta3 = {(T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#7.[.])), (T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#7=[.]} in S#9)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {} Delta3= {(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (\ X#7.S#9) T#13)], T#12 |-> (app (\ X#7.S#9) T#13), S#8 |-> T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] <-xch1- A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ................................................................................ A#11[(app (\ X#7.S#9) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] -SR,lbeta1-> A#11[(letrec {X#7=T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#9)] ================================================================================ Critical Pair: ( A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] , A#11[(app A#12[(letrec {X#7=S#8} in S#9)] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) where Delta1 = {A#10,T#6} Delta2 = {} Delta3 = {(S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {} Delta3= {(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13)], A#10 |-> A#11[(app A#12 T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] <-xch1- A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ................................................................................ A#11[(app A#12[(app (\ X#7.S#9) S#8)] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] -SR,lbeta1-> A#11[(app A#12[(letrec {X#7=S#8} in S#9)] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ================================================================================ Critical Pair: ( (app (\ X#7.S#9) T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) , (letrec {X#7=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#9) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {(T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#7.[.])), (T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#7=[.]} in S#9)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (\ X#7.S#9) S#8)] -SR,lbeta1-> A#10[(letrec {X#7=S#8} in S#9)] and constraints: (S#8,(\ X#7.[.])), (S#8,(letrec {X#7=[.]} in S#9)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (\ X#7.S#9) S#8)]} Delta1= {} Delta2= {} Delta3= {(S#8,(\ X#7.[.])),(S#8,(letrec {X#7=[.]} in S#9)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (\ X#7.S#9) T#11), S#8 |-> T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (app (\ X#7.S#9) T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) <-xch1- (app (\ X#7.S#9) T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ................................................................................ (app (\ X#7.S#9) T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) -SR,lbeta1-> (letrec {X#7=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#9) ================================================================================ Critical Pair: ( (letrec E#8 in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec E#8 in A#13[(letrec {X#7=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#10)] ) ) where Delta1 = {T#14,A#11,T#12,T#6,A#13} Delta2 = {E#8} Delta3 = {(T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#7.[.])), (T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#7=[.]} in S#10)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15)]), A#11 |-> A#13, T#12 |-> A#13[(app (\ X#7.S#10) T#15)], T#14 |-> (app (\ X#7.S#10) T#15), S#9 |-> T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {E#8} in A#13[(app (\ X#7.S#10) T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,lbeta2-> (letrec {E#8} in A#13[(letrec {X#7=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#10)]) ================================================================================ Critical Pair: ( (letrec E#8 in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec E#8 in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#8} Delta3 = {(S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15)]), T#12 |-> A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {E#8} in A#13[(app A#14[(app (\ X#7.S#10) S#9)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,lbeta2-> (letrec {E#8} in A#13[(app A#14[(letrec {X#7=S#9} in S#10)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec E#8 in (app (\ X#7.S#10) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ) , (letrec E#8 in (letrec {X#7=T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#10) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {(T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#7.[.])), (T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#7=[.]} in S#10)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (\ X#7.S#10) T#13)), A#11 |-> [.], T#12 |-> (app (\ X#7.S#10) T#13), S#9 |-> T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) <-xch1- (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])) ................................................................................ (letrec {E#8} in (app (\ X#7.S#10) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) -SR,lbeta2-> (letrec {E#8} in (letrec {X#7=T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#10)) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;E#15 in A#11[(app (\ X#7.S#10) S#9)] ) , (letrec X#13= T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#15 in A#11[(letrec {X#7=S#9} in S#10)] ) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {(S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;E#15} in A#11[(app (\ X#7.S#10) S#9)]), E#8 |-> {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in A#11[(app (\ X#7.S#10) S#9)]) <-xch1- (letrec {X#13=T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#15} in A#11[(app (\ X#7.S#10) S#9)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in A#11[(letrec {X#7=S#9} in S#10)]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);X#2=S#4;E#13} in A#11[(app (\ X#7.S#10) S#9)]) , (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(letrec {X#7=S#9} in S#10)]) ) where Delta1 = {} Delta2 = {E#8} Delta3 = {(S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lbeta2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {E#8} in A#11[(letrec {X#7=S#9} in S#10)]) and constraints: E#8/= {}, (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8} in A#11[(app (\ X#7.S#10) S#9)])} Delta1= {} Delta2= {E#8} Delta3= {(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(app (\ X#7.S#10) S#9)], E#8 |-> {X#1=S#4;X#2=(var X#1);E#13}, E#12 |-> {X#1=S#4;E#13}, E#3 |-> {E#13}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(app (\ X#7.S#10) S#9)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;E#13} in A#11[(app (\ X#7.S#10) S#9)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(app (\ X#7.S#10) S#9)]) -SR,lbeta2-> (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(letrec {X#7=S#9} in S#10)]) ================================================================================ Critical Pair: ( (letrec E#9 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec E#9 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17)]), T#14 |-> A#15[(app A#16[(var X#7)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;E#17 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#17 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), E#9 |-> {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17}, E#16 |-> {E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#9 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {X#8=T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11)] ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#6,A#18} Delta2 = {} Delta3 = {(T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#8.[.])), (T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (\ X#8.S#11) T#20)];E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#9}, A#17 |-> A#18, T#14 |-> A#18[(app (\ X#8.S#11) T#20)], T#19 |-> (app (\ X#8.S#11) T#20), S#10 |-> T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#18[(letrec {X#8=T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11)];E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#9 in A#12[(var X#7)] ) , (letrec X#7= A#18[(app A#19[(letrec {X#8=S#10} in S#11)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20)];E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]}, X#15 |-> X#7, E#16 |-> {E#9}, T#14 |-> A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app A#19[(app (\ X#8.S#11) S#10)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#18[(app A#19[(letrec {X#8=S#10} in S#11)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (\ X#8.S#11) T#18[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ;E#9 in A#12[(var X#7)] ) , (letrec X#7= (letrec {X#8=T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11) ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {} Delta3 = {(T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#8.[.])), (T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (\ X#8.S#11) T#18);E#9} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#9}, A#17 |-> [.], T#14 |-> (app (\ X#8.S#11) T#18), S#10 |-> T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#9} in A#12[(var X#7)]) <-xch1- (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]);E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (\ X#8.S#11) T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=(letrec {X#8=T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11);E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#19[X#18,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#9 ;EE#19[X#18,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22)];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#19[X#18,[.2]]}, X#15 |-> X#7, E#16 |-> {E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#18,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#9 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#20[X#7,(var X#18)];EE#21[X#19,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {X#8=T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11)] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#6,A#20} Delta2 = {} Delta3 = {(T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#8.[.])), (T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (\ X#8.S#11) T#22)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (\ X#8.S#11) T#22)], T#21 |-> (app (\ X#8.S#11) T#22), S#10 |-> T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (\ X#8.S#11) T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#20[(letrec {X#8=T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(app A#21[(letrec {X#8=S#10} in S#11)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22)];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, T#14 |-> A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (\ X#8.S#11) S#10)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=A#20[(app A#21[(letrec {X#8=S#10} in S#11)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (\ X#8.S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {X#8=T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11) ;E#9 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {} Delta3 = {(T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(\ X#8.[.])), (T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (\ X#8.S#11) T#20);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#9;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (\ X#8.S#11) T#20), S#10 |-> T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (\ X#8.S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#18=(letrec {X#8=T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} in S#11);E#9;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;E#15 ;EE#13[X#7,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;E#15 ;EE#13[X#7,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#9 |-> {X#1=S#4;X#2=(var X#1);E#15}, E#14 |-> {X#1=S#4;E#15}, E#3 |-> {E#15;EE#13[X#7,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);E#15;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;E#15;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);E#15;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#1=S#4;X#2=(var X#1);E#15;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#2= A#15[(app (\ X#8.S#11) S#10)] ;X#7= (var X#2) ;E#14 in A#12[(var X#7)] ) , (letrec X#2= (var X#7) ;X#7= A#15[(letrec {X#8=S#10} in S#11)] ;E#14 in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#9 |-> {X#2=(var X#7);E#14}, EE#13[.1,.2] |-> {[.1]=A#15[[.2]]}, X#1 |-> X#7, S#4 |-> A#15[(app (\ X#8.S#11) S#10)], E#3 |-> {E#14}} and instantiated rules: (letrec {X#2=(var X#7);X#7=A#15[(app (\ X#8.S#11) S#10)];E#14} in A#12[(var X#7)]) <-xch1- (letrec {X#2=A#15[(app (\ X#8.S#11) S#10)];X#7=(var X#2);E#14} in A#12[(var X#7)]) ................................................................................ (letrec {X#2=(var X#7);X#7=A#15[(app (\ X#8.S#11) S#10)];E#14} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#2=(var X#7);X#7=A#15[(letrec {X#8=S#10} in S#11)];E#14} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#2= A#15[(var X#16)] ;X#7= (var X#2) ;E#14 ;EE#17[X#16,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#2= (var X#7) ;X#7= A#15[(var X#16)] ;E#14 ;EE#17[X#16,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#9 |-> {X#2=(var X#7);E#14}, EE#13[.1,.2] |-> {[.1]=A#15[(var X#16)];EE#17[X#16,[.2]]}, X#1 |-> X#7, S#4 |-> A#15[(var X#16)], E#3 |-> {E#14;EE#17[X#16,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#2=(var X#7);X#7=A#15[(var X#16)];E#14;EE#17[X#16,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#2=A#15[(var X#16)];X#7=(var X#2);E#14;EE#17[X#16,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#2=(var X#7);X#7=A#15[(var X#16)];E#14;EE#17[X#16,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#2=(var X#7);X#7=A#15[(var X#16)];E#14;EE#17[X#16,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= A#15[(var X#17)] ;E#14 ;EE#18[X#7,(var X#16)] ;EE#19[X#17,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#16= A#15[(var X#17)] ;X#2= (var X#16) ;E#14 ;EE#18[X#7,(var X#16)] ;EE#19[X#17,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#16),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#9 |-> {X#2=(var X#16);E#14}, EE#13[.1,.2] |-> {X#16=A#15[(var X#17)];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#1 |-> X#16, S#4 |-> A#15[(var X#17)], E#3 |-> {E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (\ X#8.S#11) S#10)]}} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#16=(var X#2);X#2=A#15[(var X#17)];E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= A#15[(app (\ X#8.S#11) S#10)] ;E#14 ;EE#17[X#7,(var X#16)] in A#12[(var X#7)] ) , (letrec X#16= A#15[(letrec {X#8=S#10} in S#11)] ;X#2= (var X#16) ;E#14 ;EE#17[X#7,(var X#16)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#16),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#9 |-> {X#2=(var X#16);E#14}, EE#13[.1,.2] |-> {X#16=A#15[[.2]];EE#17[[.1],(var X#16)]}, X#1 |-> X#16, S#4 |-> A#15[(app (\ X#8.S#11) S#10)], E#3 |-> {E#14;EE#17[X#7,(var X#16)]}} and instantiated rules: (letrec {X#16=A#15[(app (\ X#8.S#11) S#10)];X#2=(var X#16);E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) <-xch1- (letrec {X#16=(var X#2);X#2=A#15[(app (\ X#8.S#11) S#10)];E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#8.S#11) S#10)];X#2=(var X#16);E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#8=S#10} in S#11)];X#2=(var X#16);E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#7) ;X#7= A#17[(app (\ X#8.S#11) S#10)] ;E#9 in A#12[(var X#7)] ) , (letrec X#15= A#17[(letrec {X#8=S#10} in S#11)] ;X#7= (var X#15) ;E#9 in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#15),[.]), ((var X#7),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=A#17[[.2]];[.1]=(var X#15)}, X#2 |-> X#7, EE#16[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#15, S#4 |-> A#17[(app (\ X#8.S#11) S#10)], E#3 |-> {E#9}, A#14 |-> [.], X#15 |-> X#15} and instantiated rules: (letrec {X#15=A#17[(app (\ X#8.S#11) S#10)];X#7=(var X#15);E#9} in A#12[(var X#7)]) <-xch1- (letrec {X#15=(var X#7);X#7=A#17[(app (\ X#8.S#11) S#10)];E#9} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=A#17[(app (\ X#8.S#11) S#10)];X#7=(var X#15);E#9} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=A#17[(letrec {X#8=S#10} in S#11)];X#7=(var X#15);E#9} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#7) ;X#7= A#17[(var X#18)] ;E#9 ;EE#19[X#18,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= A#17[(var X#18)] ;X#7= (var X#15) ;E#9 ;EE#19[X#18,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#15),[.]), ((var X#7),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=A#17[(var X#18)];[.1]=(var X#15);EE#19[X#18,[.2]]}, X#2 |-> X#7, EE#16[.1,.2] |-> {[.1]=A#17[(var X#18)];EE#19[X#18,[.2]]}, X#1 |-> X#15, S#4 |-> A#17[(var X#18)], E#3 |-> {E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]}, A#14 |-> [.], X#15 |-> X#15} and instantiated rules: (letrec {X#15=A#17[(var X#18)];X#7=(var X#15);E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=(var X#7);X#7=A#17[(var X#18)];E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=A#17[(var X#18)];X#7=(var X#15);E#9;EE#19[X#18,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=A#17[(var X#18)];X#7=(var X#15);E#9;EE#19[X#18,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(app (\ X#8.S#11) S#10)] ;X#16= (var X#15) ;E#9 ;EE#17[X#7,(var X#15)] in A#12[(var X#7)] ) , (letrec X#15= (var X#16) ;X#16= A#19[(letrec {X#8=S#10} in S#11)] ;E#9 ;EE#17[X#7,(var X#15)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#16),[.]), ((var X#15),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=(var X#16);X#16=A#19[[.2]];EE#17[[.1],(var X#15)]}, X#2 |-> X#15, EE#18[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#16, S#4 |-> A#19[(app (\ X#8.S#11) S#10)], E#3 |-> {E#9;EE#17[X#7,(var X#15)]}, A#14 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#15=(var X#16);X#16=A#19[(app (\ X#8.S#11) S#10)];E#9;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=A#19[(app (\ X#8.S#11) S#10)];X#16=(var X#15);E#9;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=(var X#16);X#16=A#19[(app (\ X#8.S#11) S#10)];E#9;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=(var X#16);X#16=A#19[(letrec {X#8=S#10} in S#11)];E#9;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(var X#20)] ;X#16= (var X#15) ;E#9 ;EE#17[X#7,(var X#15)] ;EE#21[X#20,(app (\ X#8.S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= (var X#16) ;X#16= A#19[(var X#20)] ;E#9 ;EE#17[X#7,(var X#15)] ;EE#21[X#20,(letrec {X#8=S#10} in S#11)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {(S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#16),[.]), ((var X#15),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {E#9;EE#13[X#7,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) and constraints: (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#9;EE#13[X#7,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {} Delta3= {(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=(var X#16);X#16=A#19[(var X#20)];EE#17[[.1],(var X#15)];EE#21[X#20,[.2]]}, X#2 |-> X#15, EE#18[.1,.2] |-> {[.1]=A#19[(var X#20)];EE#21[X#20,[.2]]}, X#1 |-> X#16, S#4 |-> A#19[(var X#20)], E#3 |-> {E#9;EE#17[X#7,(var X#15)];EE#21[X#20,(app (\ X#8.S#11) S#10)]}, A#14 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#9;EE#17[X#7,(var X#15)];EE#21[X#20,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=A#19[(var X#20)];X#16=(var X#15);E#9;EE#17[X#7,(var X#15)];EE#21[X#20,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#9;EE#17[X#7,(var X#15)];EE#21[X#20,(app (\ X#8.S#11) S#10)]} in A#12[(var X#7)]) -SR,lbeta3-> (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#9;EE#17[X#7,(var X#15)];EE#21[X#20,(letrec {X#8=S#10} in S#11)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#10) ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#10) ;E#9 in A#13[(app A#14[(\ X#8.S#10)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#13[(app A#14[(\ X#8.S#10)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;X#7= (\ X#8.S#10) ;E#15 in A#11[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= (\ X#8.S#10) ;E#15 in A#11[(\ X#8.S#10)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]), E#9 |-> {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15}, E#14 |-> {X#7=(\ X#8.S#10);E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) <-xch1- (letrec {X#13=T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#10);E#15} in A#11[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#2=(\ X#8.S#10);X#7=(var X#2);E#12} in A#11[(var X#7)]) , (letrec {X#2=(var X#7);X#7=(\ X#8.S#10);E#12} in A#11[(\ X#8.S#10)]) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], E#9 |-> {X#2=(var X#7);E#12}, X#1 |-> X#7, S#4 |-> (\ X#8.S#10), E#3 |-> {E#12}} and instantiated rules: (letrec {X#2=(var X#7);X#7=(\ X#8.S#10);E#12} in A#11[(var X#7)]) <-xch1- (letrec {X#2=(\ X#8.S#10);X#7=(var X#2);E#12} in A#11[(var X#7)]) ................................................................................ (letrec {X#2=(var X#7);X#7=(\ X#8.S#10);E#12} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#2=(var X#7);X#7=(\ X#8.S#10);E#12} in A#11[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);X#2=S#4;X#7=(\ X#8.S#10);E#13} in A#11[(var X#7)]) , (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#10);E#13} in A#11[(\ X#8.S#10)]) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(\ X#8.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], E#9 |-> {X#1=S#4;X#2=(var X#1);E#13}, E#12 |-> {X#1=S#4;E#13}, E#3 |-> {X#7=(\ X#8.S#10);E#13}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#10);E#13} in A#11[(var X#7)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;X#7=(\ X#8.S#10);E#13} in A#11[(var X#7)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#10);E#13} in A#11[(var X#7)]) -SR,cp-in1-> (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#10);E#13} in A#11[(\ X#8.S#10)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;VV#13|X#9,(var X#7)| in A#15[(app A#16[(\ X#8.S#11)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17)]), T#14 |-> A#15[(app A#16[(var X#9)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(var X#9)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#15[(app A#16[(\ X#8.S#11)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#17 ;VV#13|X#9,(var X#7)| in A#12[(var X#9)] ) , (letrec X#15= T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#17 ;VV#13|X#9,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]), E#10 |-> {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17}, E#16 |-> {X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#11);E#17;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#8.S#11) ;X#7= (var X#2) ;E#14 ;VV#13|X#9,(var X#7)| in A#12[(var X#9)] ) , (letrec X#2= (var X#7) ;X#7= (\ X#8.S#11) ;E#14 ;VV#13|X#9,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#2=(var X#7);E#14}, X#1 |-> X#7, S#4 |-> (\ X#8.S#11), E#3 |-> {E#14;VV#13|X#9,(var X#7)|}} and instantiated rules: (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#2=(\ X#8.S#11);X#7=(var X#2);E#14;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);E#14;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;X#7= (\ X#8.S#11) ;E#15 ;VV#13|X#9,(var X#7)| in A#12[(var X#9)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;X#7= (\ X#8.S#11) ;E#15 ;VV#13|X#9,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#1=S#4;X#2=(var X#1);E#15}, E#14 |-> {X#1=S#4;E#15}, E#3 |-> {X#7=(\ X#8.S#11);E#15;VV#13|X#9,(var X#7)|}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#11);E#15;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;X#7=(\ X#8.S#11);E#15;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#11);E#15;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#11);E#15;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);X#9=(var X#2);E#14} in A#12[(var X#9)]) , (letrec X#2= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= (var X#7) ;E#14 in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#9),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#2=(var X#9);E#14}, VV#13|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#9, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#11);E#14}} and instantiated rules: (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#7);E#14} in A#12[(var X#9)]) <-xch1- (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);X#9=(var X#2);E#14} in A#12[(var X#9)]) ................................................................................ (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#7);E#14} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#7);E#14} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#2= (var X#16) ;X#7= (\ X#8.S#11) ;X#9= (var X#2) ;E#14 ;VV#17|X#16,(var X#7)| in A#12[(var X#9)] ) , (letrec X#2= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= (var X#16) ;E#14 ;VV#17|X#16,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#9),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#2=(var X#9);E#14}, VV#13|.1,.2| |-> {[.1]=(var X#16);VV#17|X#16,[.2]|}, X#1 |-> X#9, S#4 |-> (var X#16), E#3 |-> {X#7=(\ X#8.S#11);E#14;VV#17|X#16,(var X#7)|}} and instantiated rules: (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#16);E#14;VV#17|X#16,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#2=(var X#16);X#7=(\ X#8.S#11);X#9=(var X#2);E#14;VV#17|X#16,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#16);E#14;VV#17|X#16,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#16);E#14;VV#17|X#16,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= (var X#17) ;X#7= (\ X#8.S#11) ;E#14 ;VV#18|X#9,(var X#16)| ;VV#19|X#17,(var X#7)| in A#12[(var X#9)] ) , (letrec X#16= (var X#17) ;X#2= (var X#16) ;X#7= (\ X#8.S#11) ;E#14 ;VV#18|X#9,(var X#16)| ;VV#19|X#17,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#2=(var X#16);E#14}, VV#13|.1,.2| |-> {X#16=(var X#17);VV#18|[.1],(var X#16)|;VV#19|X#17,[.2]|}, X#1 |-> X#16, S#4 |-> (var X#17), E#3 |-> {X#7=(\ X#8.S#11);E#14;VV#18|X#9,(var X#16)|;VV#19|X#17,(var X#7)|}} and instantiated rules: (letrec {X#16=(var X#17);X#2=(var X#16);X#7=(\ X#8.S#11);E#14;VV#18|X#9,(var X#16)|;VV#19|X#17,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#16=(var X#2);X#2=(var X#17);X#7=(\ X#8.S#11);E#14;VV#18|X#9,(var X#16)|;VV#19|X#17,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#16=(var X#17);X#2=(var X#16);X#7=(\ X#8.S#11);E#14;VV#18|X#9,(var X#16)|;VV#19|X#17,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#16=(var X#17);X#2=(var X#16);X#7=(\ X#8.S#11);E#14;VV#18|X#9,(var X#16)|;VV#19|X#17,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= (var X#7) ;X#7= (\ X#8.S#11) ;E#14 ;VV#17|X#9,(var X#16)| in A#12[(var X#9)] ) , (letrec X#16= (var X#7) ;X#2= (var X#16) ;X#7= (\ X#8.S#11) ;E#14 ;VV#17|X#9,(var X#16)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], E#10 |-> {X#2=(var X#16);E#14}, VV#13|.1,.2| |-> {X#16=[.2];VV#17|[.1],(var X#16)|}, X#1 |-> X#16, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#11);E#14;VV#17|X#9,(var X#16)|}} and instantiated rules: (letrec {X#16=(var X#7);X#2=(var X#16);X#7=(\ X#8.S#11);E#14;VV#17|X#9,(var X#16)|} in A#12[(var X#9)]) <-xch1- (letrec {X#16=(var X#2);X#2=(var X#7);X#7=(\ X#8.S#11);E#14;VV#17|X#9,(var X#16)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#16=(var X#7);X#2=(var X#16);X#7=(\ X#8.S#11);E#14;VV#17|X#9,(var X#16)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#16=(var X#7);X#2=(var X#16);X#7=(\ X#8.S#11);E#14;VV#17|X#9,(var X#16)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec {X#7=(var X#9);X#9=(\ X#8.S#11);E#10} in A#12[(var X#9)]) , (letrec {X#7=(\ X#8.S#11);X#9=(var X#7);E#10} in A#12[(\ X#8.S#11)]) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#9),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], VV#13|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#9, X#1 |-> X#7, X#7 |-> X#7, S#4 |-> (\ X#8.S#11), E#3 |-> {E#10}} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=(var X#7);E#10} in A#12[(var X#9)]) <-xch1- (letrec {X#7=(var X#9);X#9=(\ X#8.S#11);E#10} in A#12[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=(var X#7);E#10} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);X#9=(var X#7);E#10} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec {X#15=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#7);E#10} in A#12[(var X#9)]) , (letrec X#15= (var X#7) ;X#7= (\ X#8.S#11) ;X#9= (var X#15) ;E#10 in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#15),[.]), ((var X#9),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], VV#13|.1,.2| |-> {X#15=[.2];[.1]=(var X#15)}, X#2 |-> X#9, X#1 |-> X#15, VV#16|.1,.2| |-> {[.1]=[.2]}, X#15 |-> X#15, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#11);E#10}} and instantiated rules: (letrec {X#15=(var X#7);X#7=(\ X#8.S#11);X#9=(var X#15);E#10} in A#12[(var X#9)]) <-xch1- (letrec {X#15=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#7);E#10} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=(var X#7);X#7=(\ X#8.S#11);X#9=(var X#15);E#10} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=(var X#7);X#7=(\ X#8.S#11);X#9=(var X#15);E#10} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= (var X#18) ;E#10 ;VV#19|X#18,(var X#7)| in A#12[(var X#9)] ) , (letrec X#15= (var X#18) ;X#7= (\ X#8.S#11) ;X#9= (var X#15) ;E#10 ;VV#19|X#18,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#15),[.]), ((var X#9),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], VV#13|.1,.2| |-> {X#15=(var X#18);[.1]=(var X#15);VV#19|X#18,[.2]|}, X#2 |-> X#9, X#1 |-> X#15, VV#16|.1,.2| |-> {[.1]=(var X#18);VV#19|X#18,[.2]|}, X#15 |-> X#15, S#4 |-> (var X#18), E#3 |-> {X#7=(\ X#8.S#11);E#10;VV#19|X#18,(var X#7)|}} and instantiated rules: (letrec {X#15=(var X#18);X#7=(\ X#8.S#11);X#9=(var X#15);E#10;VV#19|X#18,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#15=(var X#9);X#7=(\ X#8.S#11);X#9=(var X#18);E#10;VV#19|X#18,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=(var X#18);X#7=(\ X#8.S#11);X#9=(var X#15);E#10;VV#19|X#18,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=(var X#18);X#7=(\ X#8.S#11);X#9=(var X#15);E#10;VV#19|X#18,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#7) ;X#16= (var X#15) ;X#7= (\ X#8.S#11) ;E#10 ;VV#17|X#9,(var X#15)| in A#12[(var X#9)] ) , (letrec X#15= (var X#16) ;X#16= (var X#7) ;X#7= (\ X#8.S#11) ;E#10 ;VV#17|X#9,(var X#15)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#15),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], VV#13|.1,.2| |-> {X#15=(var X#16);X#16=[.2];VV#17|[.1],(var X#15)|}, X#2 |-> X#15, X#1 |-> X#16, VV#18|.1,.2| |-> {[.1]=[.2]}, X#16 |-> X#16, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|}} and instantiated rules: (letrec {X#15=(var X#16);X#16=(var X#7);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|} in A#12[(var X#9)]) <-xch1- (letrec {X#15=(var X#7);X#16=(var X#15);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=(var X#16);X#16=(var X#7);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=(var X#16);X#16=(var X#7);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#20) ;X#16= (var X#15) ;X#7= (\ X#8.S#11) ;E#10 ;VV#17|X#9,(var X#15)| ;VV#21|X#20,(var X#7)| in A#12[(var X#9)] ) , (letrec X#15= (var X#16) ;X#16= (var X#20) ;X#7= (\ X#8.S#11) ;E#10 ;VV#17|X#9,(var X#15)| ;VV#21|X#20,(var X#7)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#15),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], VV#13|.1,.2| |-> {X#15=(var X#16);X#16=(var X#20);VV#17|[.1],(var X#15)|;VV#21|X#20,[.2]|}, X#2 |-> X#15, X#1 |-> X#16, VV#18|.1,.2| |-> {[.1]=(var X#20);VV#21|X#20,[.2]|}, X#16 |-> X#16, S#4 |-> (var X#20), E#3 |-> {X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|;VV#21|X#20,(var X#7)|}} and instantiated rules: (letrec {X#15=(var X#16);X#16=(var X#20);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|;VV#21|X#20,(var X#7)|} in A#12[(var X#9)]) <-xch1- (letrec {X#15=(var X#20);X#16=(var X#15);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|;VV#21|X#20,(var X#7)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=(var X#16);X#16=(var X#20);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|;VV#21|X#20,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=(var X#16);X#16=(var X#20);X#7=(\ X#8.S#11);E#10;VV#17|X#9,(var X#15)|;VV#21|X#20,(var X#7)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#15= (\ X#8.S#11) ;X#7= (var X#15) ;E#10 ;VV#16|X#9,(var X#15)| in A#12[(var X#9)] ) , (letrec X#15= (var X#7) ;X#7= (\ X#8.S#11) ;E#10 ;VV#16|X#9,(var X#15)| in A#12[(\ X#8.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#15),[.]), ((var X#7),[.]), ((var X#9),A#12[[.]]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(\ X#8.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;VV#13|X#9,(var X#7)|} in A#12[(var X#9)])} Delta1= {} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#12[[.]]),((var X#7),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#9)], VV#13|.1,.2| |-> {X#15=[.2];VV#16|[.1],(var X#15)|}, X#2 |-> X#15, X#1 |-> X#7, X#7 |-> X#7, S#4 |-> (\ X#8.S#11), E#3 |-> {E#10;VV#16|X#9,(var X#15)|}} and instantiated rules: (letrec {X#15=(var X#7);X#7=(\ X#8.S#11);E#10;VV#16|X#9,(var X#15)|} in A#12[(var X#9)]) <-xch1- (letrec {X#15=(\ X#8.S#11);X#7=(var X#15);E#10;VV#16|X#9,(var X#15)|} in A#12[(var X#9)]) ................................................................................ (letrec {X#15=(var X#7);X#7=(\ X#8.S#11);E#10;VV#16|X#9,(var X#15)|} in A#12[(var X#9)]) -SR,cp-in2-> (letrec {X#15=(var X#7);X#7=(\ X#8.S#11);E#10;VV#16|X#9,(var X#15)|} in A#12[(\ X#8.S#11)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(var X#7)]] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#11) ;E#10 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18)]), T#15 |-> A#16[(app A#17[(var X#9)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#18 ;EE#14[X#9,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#16= T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= (\ X#8.S#11) ;E#18 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]), E#10 |-> {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#18}, E#17 |-> {X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#16=T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#11);E#18;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#12,A#19} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#21[(app A#22[[.]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23)]];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#7)] T#23)]], T#20 |-> A#21[(app A#22[(var X#7)] T#23)], A#12 |-> A#21[(app A#22 T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];E#10} in A#13[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[A#12[(\ X#8.S#11)]] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21)];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, T#15 |-> A#19[(app A#20[A#12[(var X#7)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#13[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(var X#7)]] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[A#12[(\ X#8.S#11)]] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#19[(app A#20[(\ X#8.S#11)] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#19[(app A#20[[.]] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21)];E#10} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#7)] T#21)], A#12 |-> A#19[(app A#20 T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#13[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(var X#7)] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#19[(app A#20[(\ X#8.S#11)] T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#11) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#10 ;EE#20[X#19,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#7= (\ X#8.S#11) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#10 ;EE#20[X#19,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23)];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#9, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#19,A#12[(var X#7)]]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#20[X#19,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#21[X#9,(var X#19)];EE#22[X#20,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#8.S#11)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#12,A#21} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#23[(app A#24[[.]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25)]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#7)] T#25)]], T#22 |-> A#23[(app A#24[(var X#7)] T#25)], A#12 |-> A#23[(app A#24 T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-xch1- (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#7)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#8.S#11)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[A#12[(\ X#8.S#11)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23)];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, T#15 |-> A#21[(app A#22[A#12[(var X#7)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-xch1- (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#12[(var X#7)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[A#12[(\ X#8.S#11)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= (\ X#8.S#11) ;E#10 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6,A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#21[(app A#22[[.]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(var X#7)] T#23)];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#7)] T#23)], A#12 |-> A#21[(app A#22 T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-xch1- (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#7)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#19=A#21[(app A#22[(\ X#8.S#11)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#11);E#10;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#8.S#11) ;X#7= (var X#2) ;E#15 ;EE#14[X#9,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#2= (var X#7) ;X#7= (\ X#8.S#11) ;E#15 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#2=(var X#7);E#15}, X#1 |-> X#7, S#4 |-> (\ X#8.S#11), E#3 |-> {E#15;EE#14[X#9,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#2=(\ X#8.S#11);X#7=(var X#2);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#2=(var X#7);X#7=(\ X#8.S#11);E#15;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;X#7= (\ X#8.S#11) ;E#16 ;EE#14[X#9,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;X#7= (\ X#8.S#11) ;E#16 ;EE#14[X#9,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#1=S#4;X#2=(var X#1);E#16}, E#15 |-> {X#1=S#4;E#16}, E#3 |-> {X#7=(\ X#8.S#11);E#16;EE#14[X#9,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#11);E#16;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;X#7=(\ X#8.S#11);E#16;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#11);E#16;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#11);E#16;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= A#16[A#12[(var X#7)]] ;X#7= (\ X#8.S#11) ;X#9= (var X#2) ;E#15 in A#13[(var X#9)] ) , (letrec X#2= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= A#16[A#12[(\ X#8.S#11)]] ;E#15 in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#9),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#2=(var X#9);E#15}, EE#14[.1,.2] |-> {[.1]=A#16[[.2]]}, X#1 |-> X#9, S#4 |-> A#16[A#12[(var X#7)]], E#3 |-> {X#7=(\ X#8.S#11);E#15}} and instantiated rules: (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=A#16[A#12[(var X#7)]];E#15} in A#13[(var X#9)]) <-xch1- (letrec {X#2=A#16[A#12[(var X#7)]];X#7=(\ X#8.S#11);X#9=(var X#2);E#15} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=A#16[A#12[(var X#7)]];E#15} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=A#16[A#12[(\ X#8.S#11)]];E#15} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= A#16[(var X#17)] ;X#7= (\ X#8.S#11) ;X#9= (var X#2) ;E#15 ;EE#18[X#17,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#2= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= A#16[(var X#17)] ;E#15 ;EE#18[X#17,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#9),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#2=(var X#9);E#15}, EE#14[.1,.2] |-> {[.1]=A#16[(var X#17)];EE#18[X#17,[.2]]}, X#1 |-> X#9, S#4 |-> A#16[(var X#17)], E#3 |-> {X#7=(\ X#8.S#11);E#15;EE#18[X#17,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=A#16[(var X#17)];E#15;EE#18[X#17,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#2=A#16[(var X#17)];X#7=(\ X#8.S#11);X#9=(var X#2);E#15;EE#18[X#17,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=A#16[(var X#17)];E#15;EE#18[X#17,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#2=(var X#9);X#7=(\ X#8.S#11);X#9=A#16[(var X#17)];E#15;EE#18[X#17,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#2) ;X#2= A#16[(var X#18)] ;X#7= (\ X#8.S#11) ;E#15 ;EE#19[X#9,(var X#17)] ;EE#20[X#18,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#17= A#16[(var X#18)] ;X#2= (var X#17) ;X#7= (\ X#8.S#11) ;E#15 ;EE#19[X#9,(var X#17)] ;EE#20[X#18,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#17),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#2=(var X#17);E#15}, EE#14[.1,.2] |-> {X#17=A#16[(var X#18)];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, S#4 |-> A#16[(var X#18)], E#3 |-> {X#7=(\ X#8.S#11);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,A#12[(var X#7)]]}} and instantiated rules: (letrec {X#17=A#16[(var X#18)];X#2=(var X#17);X#7=(\ X#8.S#11);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#17=(var X#2);X#2=A#16[(var X#18)];X#7=(\ X#8.S#11);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#17=A#16[(var X#18)];X#2=(var X#17);X#7=(\ X#8.S#11);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#17=A#16[(var X#18)];X#2=(var X#17);X#7=(\ X#8.S#11);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#17= (var X#2) ;X#2= A#16[A#12[(var X#7)]] ;X#7= (\ X#8.S#11) ;E#15 ;EE#18[X#9,(var X#17)] in A#13[(var X#9)] ) , (letrec X#17= A#16[A#12[(\ X#8.S#11)]] ;X#2= (var X#17) ;X#7= (\ X#8.S#11) ;E#15 ;EE#18[X#9,(var X#17)] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#17),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#10 |-> {X#2=(var X#17);E#15}, EE#14[.1,.2] |-> {X#17=A#16[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, S#4 |-> A#16[A#12[(var X#7)]], E#3 |-> {X#7=(\ X#8.S#11);E#15;EE#18[X#9,(var X#17)]}} and instantiated rules: (letrec {X#17=A#16[A#12[(var X#7)]];X#2=(var X#17);X#7=(\ X#8.S#11);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) <-xch1- (letrec {X#17=(var X#2);X#2=A#16[A#12[(var X#7)]];X#7=(\ X#8.S#11);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#17=A#16[A#12[(var X#7)]];X#2=(var X#17);X#7=(\ X#8.S#11);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#17=A#16[A#12[(\ X#8.S#11)]];X#2=(var X#17);X#7=(\ X#8.S#11);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= A#18[A#12[(var X#7)]] ;E#10 in A#13[(var X#9)] ) , (letrec X#16= A#18[A#12[(\ X#8.S#11)]] ;X#7= (\ X#8.S#11) ;X#9= (var X#16) ;E#10 in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#9),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#18[[.2]];[.1]=(var X#16)}, X#2 |-> X#9, EE#17[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#16, S#4 |-> A#18[A#12[(var X#7)]], E#3 |-> {X#7=(\ X#8.S#11);E#10}, A#15 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#18[A#12[(var X#7)]];X#7=(\ X#8.S#11);X#9=(var X#16);E#10} in A#13[(var X#9)]) <-xch1- (letrec {X#16=(var X#9);X#7=(\ X#8.S#11);X#9=A#18[A#12[(var X#7)]];E#10} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#18[A#12[(var X#7)]];X#7=(\ X#8.S#11);X#9=(var X#16);E#10} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=A#18[A#12[(\ X#8.S#11)]];X#7=(\ X#8.S#11);X#9=(var X#16);E#10} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#9) ;X#7= (\ X#8.S#11) ;X#9= A#18[(var X#19)] ;E#10 ;EE#20[X#19,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#16= A#18[(var X#19)] ;X#7= (\ X#8.S#11) ;X#9= (var X#16) ;E#10 ;EE#20[X#19,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#9),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#18[(var X#19)];[.1]=(var X#16);EE#20[X#19,[.2]]}, X#2 |-> X#9, EE#17[.1,.2] |-> {[.1]=A#18[(var X#19)];EE#20[X#19,[.2]]}, X#1 |-> X#16, S#4 |-> A#18[(var X#19)], E#3 |-> {X#7=(\ X#8.S#11);E#10;EE#20[X#19,A#12[(var X#7)]]}, A#15 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#18[(var X#19)];X#7=(\ X#8.S#11);X#9=(var X#16);E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#16=(var X#9);X#7=(\ X#8.S#11);X#9=A#18[(var X#19)];E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#18[(var X#19)];X#7=(\ X#8.S#11);X#9=(var X#16);E#10;EE#20[X#19,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=A#18[(var X#19)];X#7=(\ X#8.S#11);X#9=(var X#16);E#10;EE#20[X#19,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[A#12[(var X#7)]] ;X#17= (var X#16) ;X#7= (\ X#8.S#11) ;E#10 ;EE#18[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#17) ;X#17= A#20[A#12[(\ X#8.S#11)]] ;X#7= (\ X#8.S#11) ;E#10 ;EE#18[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#17),[.]), ((var X#16),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#17);X#17=A#20[[.2]];EE#18[[.1],(var X#16)]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#17, S#4 |-> A#20[A#12[(var X#7)]], E#3 |-> {X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)]}, A#15 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#16=(var X#17);X#17=A#20[A#12[(var X#7)]];X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) <-xch1- (letrec {X#16=A#20[A#12[(var X#7)]];X#17=(var X#16);X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#17);X#17=A#20[A#12[(var X#7)]];X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=(var X#17);X#17=A#20[A#12[(\ X#8.S#11)]];X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(var X#21)] ;X#17= (var X#16) ;X#7= (\ X#8.S#11) ;E#10 ;EE#18[X#9,(var X#16)] ;EE#22[X#21,A#12[(var X#7)]] in A#13[(var X#9)] ) , (letrec X#16= (var X#17) ;X#17= A#20[(var X#21)] ;X#7= (\ X#8.S#11) ;E#10 ;EE#18[X#9,(var X#16)] ;EE#22[X#21,A#12[(\ X#8.S#11)]] in A#13[(var X#9)] ) ) where Delta1 = {A#12} Delta2 = {} Delta3 = {((var X#17),[.]), ((var X#16),[.]), ((var X#7),A#12[[.]]), ((var X#9),A#13[[.]]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#11);E#10;EE#14[X#9,A#12[(var X#7)]]} in A#13[(var X#9)])} Delta1= {A#12} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#9),A#13[[.]]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=(var X#17);X#17=A#20[(var X#21)];EE#18[[.1],(var X#16)];EE#22[X#21,[.2]]}, X#2 |-> X#16, EE#19[.1,.2] |-> {[.1]=A#20[(var X#21)];EE#22[X#21,[.2]]}, X#1 |-> X#17, S#4 |-> A#20[(var X#21)], E#3 |-> {X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)];EE#22[X#21,A#12[(var X#7)]]}, A#15 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#16=(var X#17);X#17=A#20[(var X#21)];X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)];EE#22[X#21,A#12[(var X#7)]]} in A#13[(var X#9)]) <-xch1- (letrec {X#16=A#20[(var X#21)];X#17=(var X#16);X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)];EE#22[X#21,A#12[(var X#7)]]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#17);X#17=A#20[(var X#21)];X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)];EE#22[X#21,A#12[(var X#7)]]} in A#13[(var X#9)]) -SR,cp-e1-> (letrec {X#16=(var X#17);X#17=A#20[(var X#21)];X#7=(\ X#8.S#11);E#10;EE#18[X#9,(var X#16)];EE#22[X#21,A#12[(\ X#8.S#11)]]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#14,T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#18[(app A#19[[.]] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20)]), T#17 |-> A#18[(app A#19[(var X#9)] T#20)], A#14 |-> A#18[(app A#19 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#18[(app A#19[(var X#9)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#18= T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;X#7= (\ X#8.S#12) ;E#20 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= (\ X#8.S#12) ;E#20 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=T#17;X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), E#11 |-> {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#20}, E#19 |-> {X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(\ X#8.S#12);E#20;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#22,A#20,T#17,T#6,A#13,A#21} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#23[(app A#24[[.]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25)]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#21[[.2]]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#20 |-> A#21, T#17 |-> A#21[A#23[(app A#24[(var X#10)] T#25)]], T#22 |-> A#23[(app A#24[(var X#10)] T#25)], A#13 |-> A#23[(app A#24 T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[A#13[(\ X#8.S#12)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23)];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#21[(app A#22[[.2]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, T#17 |-> A#21[(app A#22[A#13[(var X#10)]] T#23)], A#20 |-> A#21[(app A#22 T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(var X#10)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[A#13[(\ X#8.S#12)]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#21[(app A#22[(\ X#8.S#12)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#21[(app A#22[[.]] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23)];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#20 |-> [.], T#17 |-> A#21[(app A#22[(var X#10)] T#23)], A#13 |-> A#21[(app A#22 T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(var X#10)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#21[(app A#22[(\ X#8.S#12)] T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#7= (\ X#8.S#12) ;X#9= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#11 ;EE#22[X#21,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#7= (\ X#8.S#12) ;X#9= A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#11 ;EE#22[X#21,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25)];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {[.1]=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#22[X#21,[.2]]}, X#18 |-> X#9, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, T#17 |-> A#23[(app A#24[(var X#21)] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);X#9=A#23[(app A#24[(var X#21)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#11;EE#22[X#21,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#23[X#9,(var X#21)] ;EE#24[X#22,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#23[X#9,(var X#21)] ;EE#24[X#22,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27)];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#23[[.1],(var X#21)];EE#24[X#22,[.2]]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, T#17 |-> A#25[(app A#26[(var X#22)] T#27)], A#20 |-> A#25[(app A#26 T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#25[(app A#26[(var X#22)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#23[X#9,(var X#21)];EE#24[X#22,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[A#25[(app A#26[(\ X#8.S#12)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#24,A#20,T#17,T#6,A#13,A#23} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#25[(app A#26[[.]] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27)]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, A#20 |-> A#23, T#17 |-> A#23[A#25[(app A#26[(var X#10)] T#27)]], T#24 |-> A#25[(app A#26[(var X#10)] T#27)], A#13 |-> A#25[(app A#26 T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[A#25[(app A#26[(var X#10)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[A#25[(app A#26[(\ X#8.S#12)] T#27[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[(app A#24[A#13[(\ X#8.S#12)]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#20,T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25)];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=A#23[(app A#24[[.2]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, T#17 |-> A#23[(app A#24[A#13[(var X#10)]] T#25)], A#20 |-> A#23[(app A#24 T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[(app A#24[A#13[(var X#10)]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[(app A#24[A#13[(\ X#8.S#12)]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#21= A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= (\ X#8.S#12) ;E#11 ;EE#22[X#9,(var X#21)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {T#17,T#6,A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#23[(app A#24[[.]] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#21=A#23[(app A#24[(var X#10)] T#25)];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]), EE#15[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#18 |-> X#21, E#19 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|}, A#20 |-> [.], T#17 |-> A#23[(app A#24[(var X#10)] T#25)], A#13 |-> A#23[(app A#24 T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#21=A#23[(app A#24[(var X#10)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#21=A#23[(app A#24[(\ X#8.S#12)] T#25[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(\ X#8.S#12);E#11;EE#22[X#9,(var X#21)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= (\ X#8.S#12) ;X#7= (var X#2) ;E#17 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#2= (var X#7) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#7);E#17}, X#1 |-> X#7, S#4 |-> (\ X#8.S#12), E#3 |-> {E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#2=(var X#7);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#2=(\ X#8.S#12);X#7=(var X#2);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(var X#7);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#2=(var X#7);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;X#7= (\ X#8.S#12) ;E#18 ;EE#15[X#9,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;X#7= (\ X#8.S#12) ;E#18 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#1=S#4;X#2=(var X#1);E#18}, E#17 |-> {X#1=S#4;E#18}, E#3 |-> {X#7=(\ X#8.S#12);E#18;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#12);E#18;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;X#7=(\ X#8.S#12);E#18;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#12);E#18;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#1=S#4;X#2=(var X#1);X#7=(\ X#8.S#12);E#18;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#2) ;X#2= (var X#7) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(var X#10)]] in A#14[(var X#9)] ) , (letrec X#10= (var X#7) ;X#2= (var X#10) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#10),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#10);E#17}, VV#16|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#10, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]]}} and instantiated rules: (letrec {X#10=(var X#7);X#2=(var X#10);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) <-xch1- (letrec {X#10=(var X#2);X#2=(var X#7);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) ................................................................................ (letrec {X#10=(var X#7);X#2=(var X#10);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#10=(var X#7);X#2=(var X#10);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#2) ;X#2= (var X#19) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(var X#10)]] ;VV#20|X#19,(var X#7)| in A#14[(var X#9)] ) , (letrec X#10= (var X#19) ;X#2= (var X#10) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#20|X#19,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#10),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#10);E#17}, VV#16|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#1 |-> X#10, S#4 |-> (var X#19), E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#19,(var X#7)|}} and instantiated rules: (letrec {X#10=(var X#19);X#2=(var X#10);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#19,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#10=(var X#2);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#19,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#10=(var X#19);X#2=(var X#10);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#19,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#10=(var X#19);X#2=(var X#10);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#20|X#19,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#2) ;X#2= (var X#20) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(var X#10)]] ;VV#21|X#10,(var X#19)| ;VV#22|X#20,(var X#7)| in A#14[(var X#9)] ) , (letrec X#19= (var X#20) ;X#2= (var X#19) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#21|X#10,(var X#19)| ;VV#22|X#20,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#19);E#17}, VV#16|.1,.2| |-> {X#19=(var X#20);VV#21|[.1],(var X#19)|;VV#22|X#20,[.2]|}, X#1 |-> X#19, S#4 |-> (var X#20), E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#21|X#10,(var X#19)|;VV#22|X#20,(var X#7)|}} and instantiated rules: (letrec {X#19=(var X#20);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#21|X#10,(var X#19)|;VV#22|X#20,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#19=(var X#2);X#2=(var X#20);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#21|X#10,(var X#19)|;VV#22|X#20,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#19=(var X#20);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#21|X#10,(var X#19)|;VV#22|X#20,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#21|X#10,(var X#19)|;VV#22|X#20,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#2) ;X#2= (var X#7) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(var X#10)]] ;VV#20|X#10,(var X#19)| in A#14[(var X#9)] ) , (letrec X#19= (var X#7) ;X#2= (var X#19) ;X#7= (\ X#8.S#12) ;E#17 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#20|X#10,(var X#19)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#19);E#17}, VV#16|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#1 |-> X#19, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#19)|}} and instantiated rules: (letrec {X#19=(var X#7);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#19)|} in A#14[(var X#9)]) <-xch1- (letrec {X#19=(var X#2);X#2=(var X#7);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#19)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#19=(var X#7);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#19)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#19=(var X#7);X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#20|X#10,(var X#19)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= A#18[A#13[(var X#10)]] ;X#7= (\ X#8.S#12) ;X#9= (var X#2) ;E#17 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#2= (var X#9) ;X#7= (\ X#8.S#12) ;X#9= A#18[A#13[(\ X#8.S#12)]] ;E#17 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#9),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#9);E#17}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#9, S#4 |-> A#18[A#13[(var X#10)]], E#3 |-> {X#7=(\ X#8.S#12);E#17;VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#2=(var X#9);X#7=(\ X#8.S#12);X#9=A#18[A#13[(var X#10)]];E#17;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#2=A#18[A#13[(var X#10)]];X#7=(\ X#8.S#12);X#9=(var X#2);E#17;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(var X#9);X#7=(\ X#8.S#12);X#9=A#18[A#13[(var X#10)]];E#17;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#2=(var X#9);X#7=(\ X#8.S#12);X#9=A#18[A#13[(\ X#8.S#12)]];E#17;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#2= A#18[(var X#19)] ;X#7= (\ X#8.S#12) ;X#9= (var X#2) ;E#17 ;EE#20[X#19,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#2= (var X#9) ;X#7= (\ X#8.S#12) ;X#9= A#18[(var X#19)] ;E#17 ;EE#20[X#19,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#9),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#9);E#17}, EE#15[.1,.2] |-> {[.1]=A#18[(var X#19)];EE#20[X#19,[.2]]}, X#1 |-> X#9, S#4 |-> A#18[(var X#19)], E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#20[X#19,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#2=(var X#9);X#7=(\ X#8.S#12);X#9=A#18[(var X#19)];E#17;EE#20[X#19,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#2=A#18[(var X#19)];X#7=(\ X#8.S#12);X#9=(var X#2);E#17;EE#20[X#19,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#2=(var X#9);X#7=(\ X#8.S#12);X#9=A#18[(var X#19)];E#17;EE#20[X#19,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#2=(var X#9);X#7=(\ X#8.S#12);X#9=A#18[(var X#19)];E#17;EE#20[X#19,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#2) ;X#2= A#18[(var X#20)] ;X#7= (\ X#8.S#12) ;E#17 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#19= A#18[(var X#20)] ;X#2= (var X#19) ;X#7= (\ X#8.S#12) ;E#17 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#19);E#17}, EE#15[.1,.2] |-> {X#19=A#18[(var X#20)];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#1 |-> X#19, S#4 |-> A#18[(var X#20)], E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#21[X#9,(var X#19)];EE#22[X#20,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#19=A#18[(var X#20)];X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#21[X#9,(var X#19)];EE#22[X#20,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#19=(var X#2);X#2=A#18[(var X#20)];X#7=(\ X#8.S#12);E#17;EE#21[X#9,(var X#19)];EE#22[X#20,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#19=A#18[(var X#20)];X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#21[X#9,(var X#19)];EE#22[X#20,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#19=A#18[(var X#20)];X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#21[X#9,(var X#19)];EE#22[X#20,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#2) ;X#2= A#18[A#13[(var X#10)]] ;X#7= (\ X#8.S#12) ;E#17 ;EE#20[X#9,(var X#19)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#19= A#18[A#13[(\ X#8.S#12)]] ;X#2= (var X#19) ;X#7= (\ X#8.S#12) ;E#17 ;EE#20[X#9,(var X#19)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], E#11 |-> {X#2=(var X#19);E#17}, EE#15[.1,.2] |-> {X#19=A#18[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, S#4 |-> A#18[A#13[(var X#10)]], E#3 |-> {X#7=(\ X#8.S#12);E#17;EE#20[X#9,(var X#19)];VV#16|X#10,(var X#7)|}} and instantiated rules: (letrec {X#19=A#18[A#13[(var X#10)]];X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#20[X#9,(var X#19)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#19=(var X#2);X#2=A#18[A#13[(var X#10)]];X#7=(\ X#8.S#12);E#17;EE#20[X#9,(var X#19)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#19=A#18[A#13[(var X#10)]];X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#20[X#9,(var X#19)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#19=A#18[A#13[(\ X#8.S#12)]];X#2=(var X#19);X#7=(\ X#8.S#12);E#17;EE#20[X#9,(var X#19)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#10= (\ X#8.S#12) ;X#7= (var X#10) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] in A#14[(var X#9)] ) , (letrec X#10= (var X#7) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#10),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], VV#16|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#10, X#1 |-> X#7, X#7 |-> X#7, S#4 |-> (\ X#8.S#12), E#3 |-> {E#11;EE#15[X#9,A#13[(var X#10)]]}} and instantiated rules: (letrec {X#10=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) <-xch1- (letrec {X#10=(\ X#8.S#12);X#7=(var X#10);E#11;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) ................................................................................ (letrec {X#10=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#10=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#7) ;X#18= (var X#10) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] in A#14[(var X#9)] ) , (letrec X#10= (var X#18) ;X#18= (var X#7) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#18),[.]), ((var X#10),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], VV#16|.1,.2| |-> {X#18=[.2];[.1]=(var X#18)}, X#2 |-> X#10, X#1 |-> X#18, VV#19|.1,.2| |-> {[.1]=[.2]}, X#18 |-> X#18, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]]}} and instantiated rules: (letrec {X#10=(var X#18);X#18=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) <-xch1- (letrec {X#10=(var X#7);X#18=(var X#10);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) ................................................................................ (letrec {X#10=(var X#18);X#18=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]]} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#10=(var X#18);X#18=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]]} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#21) ;X#18= (var X#10) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#22|X#21,(var X#7)| in A#14[(var X#9)] ) , (letrec X#10= (var X#18) ;X#18= (var X#21) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#22|X#21,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#18),[.]), ((var X#10),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], VV#16|.1,.2| |-> {X#18=(var X#21);[.1]=(var X#18);VV#22|X#21,[.2]|}, X#2 |-> X#10, X#1 |-> X#18, VV#19|.1,.2| |-> {[.1]=(var X#21);VV#22|X#21,[.2]|}, X#18 |-> X#18, S#4 |-> (var X#21), E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#22|X#21,(var X#7)|}} and instantiated rules: (letrec {X#10=(var X#18);X#18=(var X#21);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#22|X#21,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#10=(var X#21);X#18=(var X#10);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#22|X#21,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#10=(var X#18);X#18=(var X#21);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#22|X#21,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#10=(var X#18);X#18=(var X#21);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#22|X#21,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (var X#7) ;X#19= (var X#18) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#20|X#10,(var X#18)| in A#14[(var X#9)] ) , (letrec X#18= (var X#19) ;X#19= (var X#7) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#20|X#10,(var X#18)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#18),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], VV#16|.1,.2| |-> {X#18=(var X#19);X#19=[.2];VV#20|[.1],(var X#18)|}, X#2 |-> X#18, X#1 |-> X#19, VV#21|.1,.2| |-> {[.1]=[.2]}, X#19 |-> X#19, S#4 |-> (var X#7), E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|}} and instantiated rules: (letrec {X#18=(var X#19);X#19=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=(var X#7);X#19=(var X#18);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(var X#19);X#19=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=(var X#19);X#19=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#20|X#10,(var X#18)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (var X#23) ;X#19= (var X#18) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#20|X#10,(var X#18)| ;VV#24|X#23,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= (var X#19) ;X#19= (var X#23) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#20|X#10,(var X#18)| ;VV#24|X#23,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#18),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], VV#16|.1,.2| |-> {X#18=(var X#19);X#19=(var X#23);VV#20|[.1],(var X#18)|;VV#24|X#23,[.2]|}, X#2 |-> X#18, X#1 |-> X#19, VV#21|.1,.2| |-> {[.1]=(var X#23);VV#24|X#23,[.2]|}, X#19 |-> X#19, S#4 |-> (var X#23), E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|;VV#24|X#23,(var X#7)|}} and instantiated rules: (letrec {X#18=(var X#19);X#19=(var X#23);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|;VV#24|X#23,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=(var X#23);X#19=(var X#18);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|;VV#24|X#23,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(var X#19);X#19=(var X#23);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#20|X#10,(var X#18)|;VV#24|X#23,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=(var X#19);X#19=(var X#23);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#20|X#10,(var X#18)|;VV#24|X#23,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (\ X#8.S#12) ;X#7= (var X#18) ;E#11 ;EE#15[X#9,A#13[(var X#10)]] ;VV#19|X#10,(var X#18)| in A#14[(var X#9)] ) , (letrec X#18= (var X#7) ;X#7= (\ X#8.S#12) ;E#11 ;EE#15[X#9,A#13[(\ X#8.S#12)]] ;VV#19|X#10,(var X#18)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#7),[.]), ((var X#18),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], VV#16|.1,.2| |-> {X#18=[.2];VV#19|[.1],(var X#18)|}, X#2 |-> X#18, X#1 |-> X#7, X#7 |-> X#7, S#4 |-> (\ X#8.S#12), E#3 |-> {E#11;EE#15[X#9,A#13[(var X#10)]];VV#19|X#10,(var X#18)|}} and instantiated rules: (letrec {X#18=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#19|X#10,(var X#18)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=(\ X#8.S#12);X#7=(var X#18);E#11;EE#15[X#9,A#13[(var X#10)]];VV#19|X#10,(var X#18)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#19|X#10,(var X#18)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=(var X#7);X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#19|X#10,(var X#18)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (var X#9) ;X#7= (\ X#8.S#12) ;X#9= A#20[A#13[(var X#10)]] ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= A#20[A#13[(\ X#8.S#12)]] ;X#7= (\ X#8.S#12) ;X#9= (var X#18) ;E#11 ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#18),[.]), ((var X#9),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], EE#15[.1,.2] |-> {X#18=A#20[[.2]];[.1]=(var X#18)}, X#2 |-> X#9, EE#19[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#18, S#4 |-> A#20[A#13[(var X#10)]], E#3 |-> {X#7=(\ X#8.S#12);E#11;VV#16|X#10,(var X#7)|}, A#17 |-> [.], X#18 |-> X#18} and instantiated rules: (letrec {X#18=A#20[A#13[(var X#10)]];X#7=(\ X#8.S#12);X#9=(var X#18);E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=(var X#9);X#7=(\ X#8.S#12);X#9=A#20[A#13[(var X#10)]];E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[A#13[(var X#10)]];X#7=(\ X#8.S#12);X#9=(var X#18);E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=A#20[A#13[(\ X#8.S#12)]];X#7=(\ X#8.S#12);X#9=(var X#18);E#11;VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= (var X#9) ;X#7= (\ X#8.S#12) ;X#9= A#20[(var X#21)] ;E#11 ;EE#22[X#21,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= A#20[(var X#21)] ;X#7= (\ X#8.S#12) ;X#9= (var X#18) ;E#11 ;EE#22[X#21,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#18),[.]), ((var X#9),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], EE#15[.1,.2] |-> {X#18=A#20[(var X#21)];[.1]=(var X#18);EE#22[X#21,[.2]]}, X#2 |-> X#9, EE#19[.1,.2] |-> {[.1]=A#20[(var X#21)];EE#22[X#21,[.2]]}, X#1 |-> X#18, S#4 |-> A#20[(var X#21)], E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, A#17 |-> [.], X#18 |-> X#18} and instantiated rules: (letrec {X#18=A#20[(var X#21)];X#7=(\ X#8.S#12);X#9=(var X#18);E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=(var X#9);X#7=(\ X#8.S#12);X#9=A#20[(var X#21)];E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=A#20[(var X#21)];X#7=(\ X#8.S#12);X#9=(var X#18);E#11;EE#22[X#21,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=A#20[(var X#21)];X#7=(\ X#8.S#12);X#9=(var X#18);E#11;EE#22[X#21,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[A#13[(var X#10)]] ;X#19= (var X#18) ;X#7= (\ X#8.S#12) ;E#11 ;EE#20[X#9,(var X#18)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= (var X#19) ;X#19= A#22[A#13[(\ X#8.S#12)]] ;X#7= (\ X#8.S#12) ;E#11 ;EE#20[X#9,(var X#18)] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#18),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], EE#15[.1,.2] |-> {X#18=(var X#19);X#19=A#22[[.2]];EE#20[[.1],(var X#18)]}, X#2 |-> X#18, EE#21[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#19, S#4 |-> A#22[A#13[(var X#10)]], E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];VV#16|X#10,(var X#7)|}, A#17 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#18=(var X#19);X#19=A#22[A#13[(var X#10)]];X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=A#22[A#13[(var X#10)]];X#19=(var X#18);X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(var X#19);X#19=A#22[A#13[(var X#10)]];X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=(var X#19);X#19=A#22[A#13[(\ X#8.S#12)]];X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(var X#23)] ;X#19= (var X#18) ;X#7= (\ X#8.S#12) ;E#11 ;EE#20[X#9,(var X#18)] ;EE#24[X#23,A#13[(var X#10)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) , (letrec X#18= (var X#19) ;X#19= A#22[(var X#23)] ;X#7= (\ X#8.S#12) ;E#11 ;EE#20[X#9,(var X#18)] ;EE#24[X#23,A#13[(\ X#8.S#12)]] ;VV#16|X#10,(var X#7)| in A#14[(var X#9)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#18),[.]), ((var X#7),[.]), ((var X#9),A#14[[.]]), ((var X#10),A#13[[.]]), ((var X#7),[.]), ((var X#9),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(\ X#8.S#12);E#11;EE#15[X#9,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#9),A#14[[.]]),((var X#10),A#13[[.]]),((var X#7),[.]),((var X#9),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#9)], EE#15[.1,.2] |-> {X#18=(var X#19);X#19=A#22[(var X#23)];EE#20[[.1],(var X#18)];EE#24[X#23,[.2]]}, X#2 |-> X#18, EE#21[.1,.2] |-> {[.1]=A#22[(var X#23)];EE#24[X#23,[.2]]}, X#1 |-> X#19, S#4 |-> A#22[(var X#23)], E#3 |-> {X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];EE#24[X#23,A#13[(var X#10)]];VV#16|X#10,(var X#7)|}, A#17 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#18=(var X#19);X#19=A#22[(var X#23)];X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];EE#24[X#23,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) <-xch1- (letrec {X#18=A#22[(var X#23)];X#19=(var X#18);X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];EE#24[X#23,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ................................................................................ (letrec {X#18=(var X#19);X#19=A#22[(var X#23)];X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];EE#24[X#23,A#13[(var X#10)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) -SR,cp-e2-> (letrec {X#18=(var X#19);X#19=A#22[(var X#23)];X#7=(\ X#8.S#12);E#11;EE#20[X#9,(var X#18)];EE#24[X#23,A#13[(\ X#8.S#12)]];VV#16|X#10,(var X#7)|} in A#14[(var X#9)]) ================================================================================ Critical Pair: ( (letrec E#7 in (letrec {E#8} in T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ) , (letrec {E#7;E#8} in T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) ) where Delta1 = {T#10,T#6} Delta2 = {E#7,E#8} Delta3 = {[{E#7},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,llet-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {[{E#7},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in (letrec {E#8} in T#11)), T#10 |-> (letrec {E#8} in T#11), S#9 |-> T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) <-xch1- (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])) ................................................................................ (letrec {E#7} in (letrec {E#8} in T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) -SR,llet-in1-> (letrec {E#7;E#8} in T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) ================================================================================ Critical Pair: ( (letrec E#7 in (letrec {X#12=T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#14} in S#9) ) , (letrec X#12= T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#14 ;E#7 in S#9 ) ) where Delta1 = {T#10,T#6} Delta2 = {E#7,E#8} Delta3 = {[{E#7},(letrec {X#12=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#14} in [.])], ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,llet-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {[{E#7},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in (letrec {X#12=T#11;E#14} in S#9)), T#10 |-> (letrec {X#12=T#11;E#14} in S#9), E#8 |-> {X#12=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#14} in S#9)) <-xch1- (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#14} in S#9)) ................................................................................ (letrec {E#7} in (letrec {X#12=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#14} in S#9)) -SR,llet-in1-> (letrec {X#12=T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#14;E#7} in S#9) ================================================================================ Critical Pair: ( (letrec {E#7} in (letrec {X#1=(var X#2);X#2=S#4;E#12} in S#9)) , (letrec {X#1=S#4;X#2=(var X#1);E#12;E#7} in S#9) ) where Delta1 = {T#6} Delta2 = {E#7,E#8} Delta3 = {[{E#7},(letrec {X#1=S#4;X#2=(var X#1);E#12} in [.])], ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,llet-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {[{E#7},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in [.]), T#10 |-> [.], S#5 |-> S#9, E#8 |-> {X#1=S#4;X#2=(var X#1);E#12}, E#11 |-> {X#1=S#4;E#12}, E#3 |-> {E#12}} and instantiated rules: (letrec {E#7} in (letrec {X#1=S#4;X#2=(var X#1);E#12} in S#9)) <-xch1- (letrec {E#7} in (letrec {X#1=(var X#2);X#2=S#4;E#12} in S#9)) ................................................................................ (letrec {E#7} in (letrec {X#1=S#4;X#2=(var X#1);E#12} in S#9)) -SR,llet-in1-> (letrec {X#1=S#4;X#2=(var X#1);E#12;E#7} in S#9) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;E#13 in (letrec {E#8} in S#9) ) , (letrec X#11= T#10[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#13 ;E#8 in S#9 ) ) where Delta1 = {T#6} Delta2 = {E#7,E#8} Delta3 = {[{X#11=T#10[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#13},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,llet-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {[{E#7},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {X#11=T#10;E#13} in (letrec {E#8} in S#9)), E#7 |-> {X#11=T#10[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#13} in (letrec {E#8} in S#9)) <-xch1- (letrec {X#11=T#10[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#13} in (letrec {E#8} in S#9)) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#13} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {X#11=T#10[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#13;E#8} in S#9) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);X#2=S#4;E#11} in (letrec {E#8} in S#9)) , (letrec {X#1=S#4;X#2=(var X#1);E#11;E#8} in S#9) ) where Delta1 = {} Delta2 = {E#7,E#8} Delta3 = {[{X#1=S#4;X#2=(var X#1);E#11},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,llet-in1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {E#7;E#8} in S#9) and constraints: E#7/= {}, E#8/= {}, ({E#7},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in (letrec {E#8} in S#9))} Delta1= {} Delta2= {E#7,E#8} Delta3= {[{E#7},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> (letrec {E#8} in S#9), E#7 |-> {X#1=S#4;X#2=(var X#1);E#11}, E#10 |-> {X#1=S#4;E#11}, E#3 |-> {E#11}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);E#11} in (letrec {E#8} in S#9)) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;E#11} in (letrec {E#8} in S#9)) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);E#11} in (letrec {E#8} in S#9)) -SR,llet-in1-> (letrec {X#1=S#4;X#2=(var X#1);E#11;E#8} in S#9) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#8} in S#10) ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec X#7= S#10 ;E#8 ;E#9 in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#8} Delta3 = {(A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#8} in T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ;E#9 in A#11[(var X#7)] ) , (letrec X#7= T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#8 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {(A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#8} in T#15);E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> (letrec {E#8} in T#15), S#10 |-> T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#9} in A#11[(var X#7)]) <-xch1- (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {E#8} in T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#8;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#16=T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#18} in S#10) ;E#9 in A#11[(var X#7)] ) , (letrec X#16= T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= S#10 ;E#18 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {(A#11[(var X#7)],(letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#18} in [.])), [{E#9},(letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#18} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {X#16=T#15;E#18} in S#10);E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> (letrec {X#16=T#15;E#18} in S#10), E#8 |-> {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#18} in S#10);E#9} in A#11[(var X#7)]) <-xch1- (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#18} in S#10);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#18} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#16=T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=S#10;E#18;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#1=(var X#2);X#2=S#4;E#16} in S#10) ;E#9 in A#11[(var X#7)] ) , (letrec {X#1=S#4;X#2=(var X#1);X#7=S#10;E#16;E#9} in A#11[(var X#7)]) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {(A#11[(var X#7)],(letrec {X#1=S#4;X#2=(var X#1);E#16} in [.])), [{E#9},(letrec {X#1=S#4;X#2=(var X#1);E#16} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=[.];E#9} in A#11[(var X#7)]), X#13 |-> X#7, E#14 |-> {E#9}, T#12 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=S#4;X#2=(var X#1);E#16}, E#15 |-> {X#1=S#4;E#16}, E#3 |-> {E#16}} and instantiated rules: (letrec {X#7=(letrec {X#1=S#4;X#2=(var X#1);E#16} in S#10);E#9} in A#11[(var X#7)]) <-xch1- (letrec {X#7=(letrec {X#1=(var X#2);X#2=S#4;E#16} in S#10);E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#7=(letrec {X#1=S#4;X#2=(var X#1);E#16} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#1=S#4;X#2=(var X#1);X#7=S#10;E#16;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;X#7= (letrec {E#8} in S#10) ;E#15 in A#11[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= S#10 ;E#15 ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {(A#11[(var X#7)],(letrec {E#8} in [.])), [{X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]), E#9 |-> {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15}, E#14 |-> {X#7=(letrec {E#8} in S#10);E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) <-xch1- (letrec {X#13=T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(letrec {E#8} in S#10);E#15} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=S#10;E#15;E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#12} in A#11[(var X#7)]) , (letrec {X#2=(var X#7);X#7=S#10;E#12;E#8} in A#11[(var X#7)]) ) where Delta1 = {} Delta2 = {E#8} Delta3 = {(A#11[(var X#7)],(letrec {E#8} in [.])), [{X#2=(var X#7);E#12},(letrec {E#8} in [.])], ((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], E#9 |-> {X#2=(var X#7);E#12}, X#1 |-> X#7, S#4 |-> (letrec {E#8} in S#10), E#3 |-> {E#12}} and instantiated rules: (letrec {X#2=(var X#7);X#7=(letrec {E#8} in S#10);E#12} in A#11[(var X#7)]) <-xch1- (letrec {X#2=(letrec {E#8} in S#10);X#7=(var X#2);E#12} in A#11[(var X#7)]) ................................................................................ (letrec {X#2=(var X#7);X#7=(letrec {E#8} in S#10);E#12} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#2=(var X#7);X#7=S#10;E#12;E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;X#7= (letrec {E#8} in S#10) ;E#13 in A#11[(var X#7)] ) , (letrec {X#1=S#4;X#2=(var X#1);X#7=S#10;E#13;E#8} in A#11[(var X#7)]) ) where Delta1 = {} Delta2 = {E#8} Delta3 = {(A#11[(var X#7)],(letrec {E#8} in [.])), [{X#1=S#4;X#2=(var X#1);E#13},(letrec {E#8} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#7=S#10;E#8;E#9} in A#11[(var X#7)]) and constraints: E#8/= {}, (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#8} in S#10);E#9} in A#11[(var X#7)])} Delta1= {} Delta2= {E#8} Delta3= {(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9},(letrec {E#8} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(var X#7)], E#9 |-> {X#1=S#4;X#2=(var X#1);E#13}, E#12 |-> {X#1=S#4;E#13}, E#3 |-> {X#7=(letrec {E#8} in S#10);E#13}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);X#7=(letrec {E#8} in S#10);E#13} in A#11[(var X#7)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;X#7=(letrec {E#8} in S#10);E#13} in A#11[(var X#7)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);X#7=(letrec {E#8} in S#10);E#13} in A#11[(var X#7)]) -SR,llet-e1-> (letrec {X#1=S#4;X#2=(var X#1);X#7=S#10;E#13;E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec X#7= S#11 ;E#10 ;E#9 ;EE#13[X#8,(var X#7)] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),[.]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17)]), T#14 |-> A#15[(app A#16[(var X#8)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#7= T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#10 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in T#17);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> (letrec {E#9} in T#17), S#11 |-> T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#18=T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#20} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#18= T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= S#11 ;E#10 ;E#20 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#10;E#20;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#20} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#20} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {X#18=T#17;E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> (letrec {X#18=T#17;E#20} in S#11), E#9 |-> {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#20} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=S#11;E#10;E#20;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {X#1=(var X#2);X#2=S#4;E#18} in S#11) ;E#10 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;X#7= S#11 ;E#10 ;E#18 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#1=S#4;X#2=(var X#1);E#10;E#18;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {X#1=S#4;X#2=(var X#1);E#18} in [.])), [{E#10;EE#13[X#8,(var X#7)]},(letrec {X#1=S#4;X#2=(var X#1);E#18} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=[.];E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), X#15 |-> X#7, E#16 |-> {E#10;EE#13[X#8,(var X#7)]}, T#14 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=S#4;X#2=(var X#1);E#18}, E#17 |-> {X#1=S#4;E#18}, E#3 |-> {E#18}} and instantiated rules: (letrec {X#7=(letrec {X#1=S#4;X#2=(var X#1);E#18} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#7=(letrec {X#1=(var X#2);X#2=S#4;E#18} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {X#1=S#4;X#2=(var X#1);E#18} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#1=S#4;X#2=(var X#1);X#7=S#11;E#10;E#18;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;X#7= (letrec {E#9} in S#11) ;E#17 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#15= T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;X#7= S#11 ;E#17 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]), E#10 |-> {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17}, E#16 |-> {X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=(letrec {E#9} in S#11);E#17;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];X#7=S#11;E#17;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;X#8= A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#10 in A#12[(var X#8)] ) , (letrec X#7= S#11 ;X#8= A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#10 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;E#9} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20)];E#10} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]}, X#15 |-> X#8, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10}, T#14 |-> A#18[(app A#19[(var X#7)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#12[(var X#8)]) <-xch1- (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=A#18[(app A#19[(var X#7)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#7= (letrec {E#9} in S#11) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#10 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) , (letrec X#7= S#11 ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#10 ;E#9 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;E#9;EE#19[X#18,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22)];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#19[X#18,[.2]]}, X#15 |-> X#8, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#18,(var X#7)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;E#9;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,(var X#7)] in A#12[(var X#8)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= S#11 ;E#10 ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;E#9;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=S#11;E#10;E#9;EE#20[X#8,(var X#18)];EE#21[X#19,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;X#7= S#11 ;E#10 ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;E#9;EE#19[X#8,(var X#18)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#10;EE#19[X#8,(var X#18)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22)];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]}, T#14 |-> A#20[(app A#21[(var X#7)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-xch1- (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=(letrec {E#9} in S#11);E#10;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];X#7=S#11;E#10;E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= (letrec {E#9} in S#11) ;X#7= (var X#2) ;E#14 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#2= (var X#7) ;X#7= S#11 ;E#14 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#2=(var X#7);E#14;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#2=(var X#7);E#14;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#7);E#14}, X#1 |-> X#7, S#4 |-> (letrec {E#9} in S#11), E#3 |-> {E#14;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#2=(var X#7);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#2=(letrec {E#9} in S#11);X#7=(var X#2);E#14;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=(var X#7);X#7=(letrec {E#9} in S#11);E#14;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#2=(var X#7);X#7=S#11;E#14;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;X#7= (letrec {E#9} in S#11) ;E#15 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;X#7= S#11 ;E#15 ;E#9 ;EE#13[X#8,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#1=S#4;X#2=(var X#1);E#15;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#1=S#4;X#2=(var X#1);E#15;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])], ((var X#1),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#1=S#4;X#2=(var X#1);E#15}, E#14 |-> {X#1=S#4;E#15}, E#3 |-> {X#7=(letrec {E#9} in S#11);E#15;EE#13[X#8,(var X#7)]}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);X#7=(letrec {E#9} in S#11);E#15;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;X#7=(letrec {E#9} in S#11);E#15;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);X#7=(letrec {E#9} in S#11);E#15;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#1=S#4;X#2=(var X#1);X#7=S#11;E#15;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= A#15[(var X#7)] ;X#7= (letrec {E#9} in S#11) ;X#8= (var X#2) ;E#14 in A#12[(var X#8)] ) , (letrec X#2= (var X#8) ;X#7= S#11 ;X#8= A#15[(var X#7)] ;E#14 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#2=(var X#8);X#8=A#15[(var X#7)];E#14;E#9} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#2=(var X#8);X#8=A#15[(var X#7)];E#14},(letrec {E#9} in [.])], ((var X#8),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#8);E#14}, EE#13[.1,.2] |-> {[.1]=A#15[[.2]]}, X#1 |-> X#8, S#4 |-> A#15[(var X#7)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#14}} and instantiated rules: (letrec {X#2=(var X#8);X#7=(letrec {E#9} in S#11);X#8=A#15[(var X#7)];E#14} in A#12[(var X#8)]) <-xch1- (letrec {X#2=A#15[(var X#7)];X#7=(letrec {E#9} in S#11);X#8=(var X#2);E#14} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=(var X#8);X#7=(letrec {E#9} in S#11);X#8=A#15[(var X#7)];E#14} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#2=(var X#8);X#7=S#11;X#8=A#15[(var X#7)];E#14;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#2= A#15[(var X#16)] ;X#7= (letrec {E#9} in S#11) ;X#8= (var X#2) ;E#14 ;EE#17[X#16,(var X#7)] in A#12[(var X#8)] ) , (letrec X#2= (var X#8) ;X#7= S#11 ;X#8= A#15[(var X#16)] ;E#14 ;E#9 ;EE#17[X#16,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#2=(var X#8);X#8=A#15[(var X#16)];E#14;E#9;EE#17[X#16,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#2=(var X#8);X#8=A#15[(var X#16)];E#14;EE#17[X#16,(var X#7)]},(letrec {E#9} in [.])], ((var X#8),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#8);E#14}, EE#13[.1,.2] |-> {[.1]=A#15[(var X#16)];EE#17[X#16,[.2]]}, X#1 |-> X#8, S#4 |-> A#15[(var X#16)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#14;EE#17[X#16,(var X#7)]}} and instantiated rules: (letrec {X#2=(var X#8);X#7=(letrec {E#9} in S#11);X#8=A#15[(var X#16)];E#14;EE#17[X#16,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#2=A#15[(var X#16)];X#7=(letrec {E#9} in S#11);X#8=(var X#2);E#14;EE#17[X#16,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=(var X#8);X#7=(letrec {E#9} in S#11);X#8=A#15[(var X#16)];E#14;EE#17[X#16,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#2=(var X#8);X#7=S#11;X#8=A#15[(var X#16)];E#14;E#9;EE#17[X#16,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= A#15[(var X#17)] ;X#7= (letrec {E#9} in S#11) ;E#14 ;EE#18[X#8,(var X#16)] ;EE#19[X#17,(var X#7)] in A#12[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#2= (var X#16) ;X#7= S#11 ;E#14 ;E#9 ;EE#18[X#8,(var X#16)] ;EE#19[X#17,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;E#9;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]},(letrec {E#9} in [.])], ((var X#16),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#16);E#14}, EE#13[.1,.2] |-> {X#16=A#15[(var X#17)];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#1 |-> X#16, S#4 |-> A#15[(var X#17)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#14;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]}} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);X#7=(letrec {E#9} in S#11);E#14;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#16=(var X#2);X#2=A#15[(var X#17)];X#7=(letrec {E#9} in S#11);E#14;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);X#7=(letrec {E#9} in S#11);E#14;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);X#7=S#11;E#14;E#9;EE#18[X#8,(var X#16)];EE#19[X#17,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= A#15[(var X#7)] ;X#7= (letrec {E#9} in S#11) ;E#14 ;EE#17[X#8,(var X#16)] in A#12[(var X#8)] ) , (letrec X#16= A#15[(var X#7)] ;X#2= (var X#16) ;X#7= S#11 ;E#14 ;E#9 ;EE#17[X#8,(var X#16)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#16=A#15[(var X#7)];X#2=(var X#16);E#14;E#9;EE#17[X#8,(var X#16)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#16=A#15[(var X#7)];X#2=(var X#16);E#14;EE#17[X#8,(var X#16)]},(letrec {E#9} in [.])], ((var X#16),[.]), ((var X#2),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=(var X#16);E#14}, EE#13[.1,.2] |-> {X#16=A#15[[.2]];EE#17[[.1],(var X#16)]}, X#1 |-> X#16, S#4 |-> A#15[(var X#7)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#14;EE#17[X#8,(var X#16)]}} and instantiated rules: (letrec {X#16=A#15[(var X#7)];X#2=(var X#16);X#7=(letrec {E#9} in S#11);E#14;EE#17[X#8,(var X#16)]} in A#12[(var X#8)]) <-xch1- (letrec {X#16=(var X#2);X#2=A#15[(var X#7)];X#7=(letrec {E#9} in S#11);E#14;EE#17[X#8,(var X#16)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#7)];X#2=(var X#16);X#7=(letrec {E#9} in S#11);E#14;EE#17[X#8,(var X#16)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#7)];X#2=(var X#16);X#7=S#11;E#14;E#9;EE#17[X#8,(var X#16)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#7=(var X#8);X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) , (letrec {X#7=S#11;X#8=(var X#7);E#10;E#9} in A#12[(var X#8)]) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#8=(var X#7);E#10;E#9} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#8=(var X#7);E#10},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#8),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], EE#13[.1,.2] |-> {[.1]=[.2]}, X#2 |-> X#8, X#1 |-> X#7, S#4 |-> (letrec {E#9} in S#11), E#3 |-> {E#10}, A#14 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#7=(letrec {E#9} in S#11);X#8=(var X#7);E#10} in A#12[(var X#8)]) <-xch1- (letrec {X#7=(var X#8);X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);X#8=(var X#7);E#10} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;X#8=(var X#7);E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#8) ;X#7= (letrec {E#9} in S#11) ;X#8= A#17[(var X#7)] ;E#10 in A#12[(var X#8)] ) , (letrec X#15= A#17[(var X#7)] ;X#7= S#11 ;X#8= (var X#15) ;E#10 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#15=A#17[(var X#7)];X#8=(var X#15);E#10;E#9} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=A#17[(var X#7)];X#8=(var X#15);E#10},(letrec {E#9} in [.])], ((var X#15),[.]), ((var X#8),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], EE#13[.1,.2] |-> {X#15=A#17[[.2]];[.1]=(var X#15)}, X#2 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#15, S#4 |-> A#17[(var X#7)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#10}, A#14 |-> [.], X#15 |-> X#15} and instantiated rules: (letrec {X#15=A#17[(var X#7)];X#7=(letrec {E#9} in S#11);X#8=(var X#15);E#10} in A#12[(var X#8)]) <-xch1- (letrec {X#15=(var X#8);X#7=(letrec {E#9} in S#11);X#8=A#17[(var X#7)];E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=A#17[(var X#7)];X#7=(letrec {E#9} in S#11);X#8=(var X#15);E#10} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=A#17[(var X#7)];X#7=S#11;X#8=(var X#15);E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#8) ;X#7= (letrec {E#9} in S#11) ;X#8= A#17[(var X#18)] ;E#10 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) , (letrec X#15= A#17[(var X#18)] ;X#7= S#11 ;X#8= (var X#15) ;E#10 ;E#9 ;EE#19[X#18,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#15=A#17[(var X#18)];X#8=(var X#15);E#10;E#9;EE#19[X#18,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=A#17[(var X#18)];X#8=(var X#15);E#10;EE#19[X#18,(var X#7)]},(letrec {E#9} in [.])], ((var X#15),[.]), ((var X#8),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], EE#13[.1,.2] |-> {X#15=A#17[(var X#18)];[.1]=(var X#15);EE#19[X#18,[.2]]}, X#2 |-> X#8, EE#16[.1,.2] |-> {[.1]=A#17[(var X#18)];EE#19[X#18,[.2]]}, X#1 |-> X#15, S#4 |-> A#17[(var X#18)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#19[X#18,(var X#7)]}, A#14 |-> [.], X#15 |-> X#15} and instantiated rules: (letrec {X#15=A#17[(var X#18)];X#7=(letrec {E#9} in S#11);X#8=(var X#15);E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#15=(var X#8);X#7=(letrec {E#9} in S#11);X#8=A#17[(var X#18)];E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=A#17[(var X#18)];X#7=(letrec {E#9} in S#11);X#8=(var X#15);E#10;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=A#17[(var X#18)];X#7=S#11;X#8=(var X#15);E#10;E#9;EE#19[X#18,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(var X#7)] ;X#16= (var X#15) ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#17[X#8,(var X#15)] in A#12[(var X#8)] ) , (letrec X#15= (var X#16) ;X#16= A#19[(var X#7)] ;X#7= S#11 ;E#10 ;E#9 ;EE#17[X#8,(var X#15)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#15=(var X#16);X#16=A#19[(var X#7)];E#10;E#9;EE#17[X#8,(var X#15)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=(var X#16);X#16=A#19[(var X#7)];E#10;EE#17[X#8,(var X#15)]},(letrec {E#9} in [.])], ((var X#16),[.]), ((var X#15),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], EE#13[.1,.2] |-> {X#15=(var X#16);X#16=A#19[[.2]];EE#17[[.1],(var X#15)]}, X#2 |-> X#15, EE#18[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#16, S#4 |-> A#19[(var X#7)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)]}, A#14 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#15=(var X#16);X#16=A#19[(var X#7)];X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)]} in A#12[(var X#8)]) <-xch1- (letrec {X#15=A#19[(var X#7)];X#16=(var X#15);X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=(var X#16);X#16=A#19[(var X#7)];X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=(var X#16);X#16=A#19[(var X#7)];X#7=S#11;E#10;E#9;EE#17[X#8,(var X#15)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(var X#20)] ;X#16= (var X#15) ;X#7= (letrec {E#9} in S#11) ;E#10 ;EE#17[X#8,(var X#15)] ;EE#21[X#20,(var X#7)] in A#12[(var X#8)] ) , (letrec X#15= (var X#16) ;X#16= A#19[(var X#20)] ;X#7= S#11 ;E#10 ;E#9 ;EE#17[X#8,(var X#15)] ;EE#21[X#20,(var X#7)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#10;E#9;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=(var X#16);X#16=A#19[(var X#20)];E#10;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]},(letrec {E#9} in [.])], ((var X#16),[.]), ((var X#15),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], EE#13[.1,.2] |-> {X#15=(var X#16);X#16=A#19[(var X#20)];EE#17[[.1],(var X#15)];EE#21[X#20,[.2]]}, X#2 |-> X#15, EE#18[.1,.2] |-> {[.1]=A#19[(var X#20)];EE#21[X#20,[.2]]}, X#1 |-> X#16, S#4 |-> A#19[(var X#20)], E#3 |-> {X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]}, A#14 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]} in A#12[(var X#8)]) <-xch1- (letrec {X#15=A#19[(var X#20)];X#16=(var X#15);X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];X#7=(letrec {E#9} in S#11);E#10;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];X#7=S#11;E#10;E#9;EE#17[X#8,(var X#15)];EE#21[X#20,(var X#7)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#15= (letrec {E#9} in S#11) ;X#7= (var X#15) ;E#10 ;EE#16[X#8,(var X#15)] in A#12[(var X#8)] ) , (letrec X#15= (var X#7) ;X#7= S#11 ;E#10 ;E#9 ;EE#16[X#8,(var X#15)] in A#12[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#7),(letrec {X#15=(var X#7);E#10;E#9;EE#16[X#8,(var X#15)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#15=(var X#7);E#10;EE#16[X#8,(var X#15)]},(letrec {E#9} in [.])], ((var X#7),[.]), ((var X#15),[.]), ((var X#7),[.]), ((var X#8),A#12[[.]]), ((var X#7),[.]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#7=S#11;E#10;E#9;EE#13[X#8,(var X#7)]} in A#12[(var X#8)]) and constraints: E#9/= {}, ((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {X#7=(letrec {E#9} in S#11);E#10;EE#13[X#8,(var X#7)]} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#7),(letrec {E#10;E#9;EE#13[X#8,(var X#7)]} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10;EE#13[X#8,(var X#7)]},(letrec {E#9} in [.])],((var X#1),[.]),((var X#2),[.]),((var X#7),[.]),((var X#8),A#12[[.]]),((var X#7),[.]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], EE#13[.1,.2] |-> {X#15=[.2];EE#16[[.1],(var X#15)]}, X#2 |-> X#15, X#1 |-> X#7, S#4 |-> (letrec {E#9} in S#11), E#3 |-> {E#10;EE#16[X#8,(var X#15)]}, A#14 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#15=(var X#7);X#7=(letrec {E#9} in S#11);E#10;EE#16[X#8,(var X#15)]} in A#12[(var X#8)]) <-xch1- (letrec {X#15=(letrec {E#9} in S#11);X#7=(var X#15);E#10;EE#16[X#8,(var X#15)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=(var X#7);X#7=(letrec {E#9} in S#11);E#10;EE#16[X#8,(var X#15)]} in A#12[(var X#8)]) -SR,llet-e2-> (letrec {X#15=(var X#7);X#7=S#11;E#10;E#9;EE#16[X#8,(var X#15)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#8)] , A#11[(letrec {E#7} in (app T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#8))] ) where Delta1 = {T#13,T#12,A#10,T#6,A#11} Delta2 = {E#7} Delta3 = {(S#8,(letrec {E#7} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (letrec {E#7} in T#14) S#8)], T#12 |-> (app (letrec {E#7} in T#14) S#8), T#13 |-> (letrec {E#7} in T#14), S#9 |-> T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: A#11[(app (letrec {E#7} in T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#8)] <-xch1- A#11[(app (letrec {E#7} in T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#8)] ................................................................................ A#11[(app (letrec {E#7} in T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#8)] -SR,lapp1-> A#11[(letrec {E#7} in (app T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#17} in S#9) S#8)] , A#11[(letrec X#15= T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#17 in (app S#9 S#8) )] ) where Delta1 = {T#13,T#12,A#10,T#6,A#11} Delta2 = {E#7} Delta3 = {(S#8,(letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#9) S#8)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#9) S#8), T#13 |-> (letrec {X#15=T#14;E#17} in S#9), E#7 |-> {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17}, E#16 |-> {E#17}} and instantiated rules: A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in S#9) S#8)] <-xch1- A#11[(app (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#17} in S#9) S#8)] ................................................................................ A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in S#9) S#8)] -SR,lapp1-> A#11[(letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in (app S#9 S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {X#1=(var X#2);X#2=S#4;E#15} in S#9) S#8)] , A#11[(letrec {X#1=S#4;X#2=(var X#1);E#15} in (app S#9 S#8))] ) where Delta1 = {T#12,A#10,T#6,A#11} Delta2 = {E#7} Delta3 = {(S#8,(letrec {X#1=S#4;X#2=(var X#1);E#15} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app [.] S#8)], T#12 |-> (app [.] S#8), T#13 |-> [.], S#5 |-> S#9, E#7 |-> {X#1=S#4;X#2=(var X#1);E#15}, E#14 |-> {X#1=S#4;E#15}, E#3 |-> {E#15}} and instantiated rules: A#11[(app (letrec {X#1=S#4;X#2=(var X#1);E#15} in S#9) S#8)] <-xch1- A#11[(app (letrec {X#1=(var X#2);X#2=S#4;E#15} in S#9) S#8)] ................................................................................ A#11[(app (letrec {X#1=S#4;X#2=(var X#1);E#15} in S#9) S#8)] -SR,lapp1-> A#11[(letrec {X#1=S#4;X#2=(var X#1);E#15} in (app S#9 S#8))] ================================================================================ Critical Pair: ( A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] , A#11[(letrec {E#7} in (app S#9 T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))] ) where Delta1 = {T#12,A#10,T#6,A#11} Delta2 = {E#7} Delta3 = {(T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#7} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> A#11, T#6 |-> A#11[(app (letrec {E#7} in S#9) T#13)], T#12 |-> (app (letrec {E#7} in S#9) T#13), S#8 |-> T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] <-xch1- A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ................................................................................ A#11[(app (letrec {E#7} in S#9) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] -SR,lapp1-> A#11[(letrec {E#7} in (app S#9 T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))] ================================================================================ Critical Pair: ( A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] , A#11[(app A#12[(letrec {E#7} in (app S#9 S#8))] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) where Delta1 = {A#10,T#6} Delta2 = {E#7} Delta3 = {(S#8,(letrec {E#7} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13)], A#10 |-> A#11[(app A#12 T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] <-xch1- A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ................................................................................ A#11[(app A#12[(app (letrec {E#7} in S#9) S#8)] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] -SR,lapp1-> A#11[(app A#12[(letrec {E#7} in (app S#9 S#8))] T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ================================================================================ Critical Pair: ( (app (letrec {E#7} in T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#8) , (letrec {E#7} in (app T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#8)) ) where Delta1 = {T#11,T#6} Delta2 = {E#7} Delta3 = {(S#8,(letrec {E#7} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (letrec {E#7} in T#12) S#8), T#11 |-> (letrec {E#7} in T#12), S#9 |-> T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (app (letrec {E#7} in T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#8) <-xch1- (app (letrec {E#7} in T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#8) ................................................................................ (app (letrec {E#7} in T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#8) -SR,lapp1-> (letrec {E#7} in (app T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#8)) ================================================================================ Critical Pair: ( (app (letrec {X#13=T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#15} in S#9) S#8) , (letrec X#13= T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#15 in (app S#9 S#8) ) ) where Delta1 = {T#11,T#6} Delta2 = {E#7} Delta3 = {(S#8,(letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (letrec {X#13=T#12;E#15} in S#9) S#8), T#11 |-> (letrec {X#13=T#12;E#15} in S#9), E#7 |-> {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (app (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in S#9) S#8) <-xch1- (app (letrec {X#13=T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#15} in S#9) S#8) ................................................................................ (app (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in S#9) S#8) -SR,lapp1-> (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in (app S#9 S#8)) ================================================================================ Critical Pair: ( (app (letrec {X#1=(var X#2);X#2=S#4;E#13} in S#9) S#8) , (letrec {X#1=S#4;X#2=(var X#1);E#13} in (app S#9 S#8)) ) where Delta1 = {T#6} Delta2 = {E#7} Delta3 = {(S#8,(letrec {X#1=S#4;X#2=(var X#1);E#13} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app [.] S#8), T#11 |-> [.], S#5 |-> S#9, E#7 |-> {X#1=S#4;X#2=(var X#1);E#13}, E#12 |-> {X#1=S#4;E#13}, E#3 |-> {E#13}} and instantiated rules: (app (letrec {X#1=S#4;X#2=(var X#1);E#13} in S#9) S#8) <-xch1- (app (letrec {X#1=(var X#2);X#2=S#4;E#13} in S#9) S#8) ................................................................................ (app (letrec {X#1=S#4;X#2=(var X#1);E#13} in S#9) S#8) -SR,lapp1-> (letrec {X#1=S#4;X#2=(var X#1);E#13} in (app S#9 S#8)) ================================================================================ Critical Pair: ( (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) , (letrec {E#7} in (app S#9 T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) ) where Delta1 = {T#6} Delta2 = {E#7} Delta3 = {(T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#7} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp1- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ A#10[(app (letrec {E#7} in S#9) S#8)] -SR,lapp1-> A#10[(letrec {E#7} in (app S#9 S#8))] and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= A#10[(app (letrec {E#7} in S#9) S#8)]} Delta1= {} Delta2= {E#7} Delta3= {(S#8,(letrec {E#7} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {A#10 |-> [.], T#6 |-> (app (letrec {E#7} in S#9) T#11), S#8 |-> T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (app (letrec {E#7} in S#9) T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) <-xch1- (app (letrec {E#7} in S#9) T#11[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ................................................................................ (app (letrec {E#7} in S#9) T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) -SR,lapp1-> (letrec {E#7} in (app S#9 T#11[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#9)] ) , (letrec E#7 in A#13[(letrec {E#8} in (app T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#9))] ) ) where Delta1 = {T#15,T#14,A#11,T#12,T#6,A#13} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app (letrec {E#8} in T#16) S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {E#8} in T#16) S#9)], T#14 |-> (app (letrec {E#8} in T#16) S#9), T#15 |-> (letrec {E#8} in T#16), S#10 |-> T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#9)]) <-xch1- (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {E#8} in T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {E#8} in (app T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#19} in S#10) S#9)] ) , (letrec E#7 in A#13[(letrec X#17= T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#19 in (app S#10 S#9) )] ) ) where Delta1 = {T#15,T#14,A#11,T#12,T#6,A#13} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {X#17=T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#19} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app (letrec {X#17=T#16;E#19} in S#10) S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {X#17=T#16;E#19} in S#10) S#9)], T#14 |-> (app (letrec {X#17=T#16;E#19} in S#10) S#9), T#15 |-> (letrec {X#17=T#16;E#19} in S#10), E#8 |-> {X#17=T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#19} in S#10) S#9)]) <-xch1- (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#19} in S#10) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {X#17=T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#19} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {X#17=T#16[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#19} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec {E#7} in A#13[(app (letrec {X#1=(var X#2);X#2=S#4;E#17} in S#10) S#9)]) , (letrec {E#7} in A#13[(letrec {X#1=S#4;X#2=(var X#1);E#17} in (app S#10 S#9))]) ) where Delta1 = {T#14,A#11,T#12,T#6,A#13} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {X#1=S#4;X#2=(var X#1);E#17} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app [.] S#9)]), A#11 |-> A#13, T#12 |-> A#13[(app [.] S#9)], T#14 |-> (app [.] S#9), T#15 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=S#4;X#2=(var X#1);E#17}, E#16 |-> {X#1=S#4;E#17}, E#3 |-> {E#17}} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {X#1=S#4;X#2=(var X#1);E#17} in S#10) S#9)]) <-xch1- (letrec {E#7} in A#13[(app (letrec {X#1=(var X#2);X#2=S#4;E#17} in S#10) S#9)]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {X#1=S#4;X#2=(var X#1);E#17} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {X#1=S#4;X#2=(var X#1);E#17} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec E#7 in A#13[(letrec {E#8} in (app S#10 T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))] ) ) where Delta1 = {T#14,A#11,T#12,T#6,A#13} Delta2 = {E#7,E#8} Delta3 = {(T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15)]), A#11 |-> A#13, T#12 |-> A#13[(app (letrec {E#8} in S#10) T#15)], T#14 |-> (app (letrec {E#8} in S#10) T#15), S#9 |-> T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,lapp2-> (letrec {E#7} in A#13[(letrec {E#8} in (app S#10 T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))]) ================================================================================ Critical Pair: ( (letrec E#7 in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec E#7 in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#11,T#12,T#6} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15)]), T#12 |-> A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15)], A#11 |-> A#13[(app A#14 T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {E#7} in A#13[(app A#14[(app (letrec {E#8} in S#10) S#9)] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,lapp2-> (letrec {E#7} in A#13[(app A#14[(letrec {E#8} in (app S#10 S#9))] T#15[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {E#8} in T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#9) ) , (letrec E#7 in (letrec {E#8} in (app T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#9)) ) ) where Delta1 = {T#13,T#12,T#6} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app (letrec {E#8} in T#14) S#9)), A#11 |-> [.], T#12 |-> (app (letrec {E#8} in T#14) S#9), T#13 |-> (letrec {E#8} in T#14), S#10 |-> T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#9)) <-xch1- (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {E#8} in T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {E#8} in (app T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#9))) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#17} in S#10) S#9) ) , (letrec E#7 in (letrec X#15= T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#17 in (app S#10 S#9) ) ) ) where Delta1 = {T#13,T#12,T#6} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app (letrec {X#15=T#14;E#17} in S#10) S#9)), A#11 |-> [.], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#10) S#9), T#13 |-> (letrec {X#15=T#14;E#17} in S#10), E#8 |-> {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in S#10) S#9)) <-xch1- (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#17} in S#10) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in S#10) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17} in (app S#10 S#9))) ================================================================================ Critical Pair: ( (letrec {E#7} in (app (letrec {X#1=(var X#2);X#2=S#4;E#15} in S#10) S#9)) , (letrec {E#7} in (letrec {X#1=S#4;X#2=(var X#1);E#15} in (app S#10 S#9))) ) where Delta1 = {T#12,T#6} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {X#1=S#4;X#2=(var X#1);E#15} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app [.] S#9)), A#11 |-> [.], T#12 |-> (app [.] S#9), T#13 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=S#4;X#2=(var X#1);E#15}, E#14 |-> {X#1=S#4;E#15}, E#3 |-> {E#15}} and instantiated rules: (letrec {E#7} in (app (letrec {X#1=S#4;X#2=(var X#1);E#15} in S#10) S#9)) <-xch1- (letrec {E#7} in (app (letrec {X#1=(var X#2);X#2=S#4;E#15} in S#10) S#9)) ................................................................................ (letrec {E#7} in (app (letrec {X#1=S#4;X#2=(var X#1);E#15} in S#10) S#9)) -SR,lapp2-> (letrec {E#7} in (letrec {X#1=S#4;X#2=(var X#1);E#15} in (app S#10 S#9))) ================================================================================ Critical Pair: ( (letrec E#7 in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ) , (letrec E#7 in (letrec {E#8} in (app S#10 T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#7,E#8} Delta3 = {(T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {E#7} in (app (letrec {E#8} in S#10) T#13)), A#11 |-> [.], T#12 |-> (app (letrec {E#8} in S#10) T#13), S#9 |-> T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) <-xch1- (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])) ................................................................................ (letrec {E#7} in (app (letrec {E#8} in S#10) T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) -SR,lapp2-> (letrec {E#7} in (letrec {E#8} in (app S#10 T#13[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;E#15 in A#11[(app (letrec {E#8} in S#10) S#9)] ) , (letrec X#13= T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#15 in A#11[(letrec {E#8} in (app S#10 S#9))] ) ) where Delta1 = {T#6} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> (letrec {X#13=T#12;E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]), E#7 |-> {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) <-xch1- (letrec {X#13=T#12[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {X#13=T#12[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#15} in A#11[(letrec {E#8} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec {X#1=(var X#2);X#2=S#4;E#13} in A#11[(app (letrec {E#8} in S#10) S#9)]) , (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(letrec {E#8} in (app S#10 S#9))]) ) where Delta1 = {} Delta2 = {E#7,E#8} Delta3 = {(S#9,(letrec {E#8} in [.])), ((var X#1),[.]), ((var X#2),[.])} Delta4= {} from overlapping <-SR,lapp2- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {E#7} in A#11[(letrec {E#8} in (app S#10 S#9))]) and constraints: E#7/= {}, E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#7} in A#11[(app (letrec {E#8} in S#10) S#9)])} Delta1= {} Delta2= {E#7,E#8} Delta3= {(S#9,(letrec {E#8} in [.])),((var X#1),[.]),((var X#2),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#11[(app (letrec {E#8} in S#10) S#9)], E#7 |-> {X#1=S#4;X#2=(var X#1);E#13}, E#12 |-> {X#1=S#4;E#13}, E#3 |-> {E#13}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(app (letrec {E#8} in S#10) S#9)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;E#13} in A#11[(app (letrec {E#8} in S#10) S#9)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(app (letrec {E#8} in S#10) S#9)]) -SR,lapp2-> (letrec {X#1=S#4;X#2=(var X#1);E#13} in A#11[(letrec {E#8} in (app S#10 S#9))]) ================================================================================ Critical Pair: ( (letrec E#8 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ) , (letrec E#8 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ) ) where Delta1 = {A#12,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]), ((var X#7),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17)]), T#14 |-> A#15[(app A#16[(var X#7)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) <-xch1- (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])]) ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#15[(app A#16[(var X#7)] T#17[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] ;E#17 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#17 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#15=T#14;E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), E#8 |-> {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17}, E#16 |-> {E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=T#14[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=T#14[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#17;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {E#9} in (app T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10))] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#19,A#17,T#14,T#6,A#18} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (letrec {E#9} in T#21) S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {E#9} in T#21) S#10)], T#19 |-> (app (letrec {E#9} in T#21) S#10), T#20 |-> (letrec {E#9} in T#21), S#11 |-> T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10)];E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {E#9} in T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {E#9} in (app T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {X#22=T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#24} in S#11) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec X#22= T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#24 in (app S#11 S#10) )] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#19,A#17,T#14,T#6,A#18} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (letrec {X#22=T#21;E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#11) S#10)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#11) S#10), T#20 |-> (letrec {X#22=T#21;E#24} in S#11), E#9 |-> {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in S#11) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in (app S#11 S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {X#1=(var X#2);X#2=S#4;E#22} in S#11) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {X#1=S#4;X#2=(var X#1);E#22} in (app S#11 S#10))] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#6,A#18} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#1=S#4;X#2=(var X#1);E#22} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app [.] S#10)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app [.] S#10)], T#19 |-> (app [.] S#10), T#20 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=S#4;X#2=(var X#1);E#22}, E#21 |-> {X#1=S#4;E#22}, E#3 |-> {E#22}} and instantiated rules: (letrec {X#7=A#18[(app (letrec {X#1=S#4;X#2=(var X#1);E#22} in S#11) S#10)];E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app (letrec {X#1=(var X#2);X#2=S#4;E#22} in S#11) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {X#1=S#4;X#2=(var X#1);E#22} in S#11) S#10)];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {X#1=S#4;X#2=(var X#1);E#22} in (app S#11 S#10))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(letrec {E#9} in (app S#11 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#19,A#17,T#14,T#6,A#18} Delta2 = {E#9} Delta3 = {(T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> A#18, T#14 |-> A#18[(app (letrec {E#9} in S#11) T#20)], T#19 |-> (app (letrec {E#9} in S#11) T#20), S#10 |-> T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(letrec {E#9} in (app S#11 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#8 in A#12[(var X#7)] ) , (letrec X#7= A#18[(app A#19[(letrec {E#9} in (app S#11 S#10))] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20)];E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]}, X#15 |-> X#7, E#16 |-> {E#8}, T#14 |-> A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#18[(app A#19[(app (letrec {E#9} in S#11) S#10)] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#18[(app A#19[(letrec {E#9} in (app S#11 S#10))] T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {E#9} in T#19[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec {E#9} in (app T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10)) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#18,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (letrec {E#9} in T#19) S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in T#19) S#10), T#18 |-> (letrec {E#9} in T#19), S#11 |-> T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10);E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {E#9} in T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {E#9} in (app T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {X#20=T#19[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#22} in S#11) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec X#20= T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#22 in (app S#11 S#10) ) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#18,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#20=T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#22} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (letrec {X#20=T#19;E#22} in S#11) S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {X#20=T#19;E#22} in S#11) S#10), T#18 |-> (letrec {X#20=T#19;E#22} in S#11), E#9 |-> {X#20=T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {X#20=T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#22} in S#11) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {X#20=T#19[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#22} in (app S#11 S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {X#1=(var X#2);X#2=S#4;E#20} in S#11) S#10) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec {X#1=S#4;X#2=(var X#1);E#20} in (app S#11 S#10)) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#1=S#4;X#2=(var X#1);E#20} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app [.] S#10);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app [.] S#10), T#18 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=S#4;X#2=(var X#1);E#20}, E#19 |-> {X#1=S#4;E#20}, E#3 |-> {E#20}} and instantiated rules: (letrec {X#7=(app (letrec {X#1=S#4;X#2=(var X#1);E#20} in S#11) S#10);E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=(app (letrec {X#1=(var X#2);X#2=S#4;E#20} in S#11) S#10);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {X#1=S#4;X#2=(var X#1);E#20} in S#11) S#10);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {X#1=S#4;X#2=(var X#1);E#20} in (app S#11 S#10));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= (app (letrec {E#9} in S#11) T#18[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ;E#8 in A#12[(var X#7)] ) , (letrec X#7= (letrec {E#9} in (app S#11 T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#9} Delta3 = {(T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=(app (letrec {E#9} in S#11) T#18);E#8} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#7, E#16 |-> {E#8}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in S#11) T#18), S#10 |-> T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]);E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=(app (letrec {E#9} in S#11) T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=(letrec {E#9} in (app S#11 T#18[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]));E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#8 ;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#7= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#8 ;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22)];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#19[X#18,[.2]]}, X#15 |-> X#7, E#16 |-> {E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#7=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#8 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#8 ;EE#20[X#7,(var X#18)] ;EE#21[X#19,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#20[X#7,(var X#18)];EE#21[X#19,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {E#9} in (app T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10))] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#22,T#21,A#17,T#14,T#6,A#20} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (letrec {E#9} in T#23) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {E#9} in T#23) S#10)], T#21 |-> (app (letrec {E#9} in T#23) S#10), T#22 |-> (letrec {E#9} in T#23), S#11 |-> T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#9} in T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#9} in (app T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {X#24=T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#26} in S#11) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec X#24= T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#26 in (app S#11 S#10) )] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#22,T#21,A#17,T#14,T#6,A#20} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#24=T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#26} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (letrec {X#24=T#23;E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {X#24=T#23;E#26} in S#11) S#10)], T#21 |-> (app (letrec {X#24=T#23;E#26} in S#11) S#10), T#22 |-> (letrec {X#24=T#23;E#26} in S#11), E#9 |-> {X#24=T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#26}, E#25 |-> {E#26}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#24=T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#26} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#24=T#23[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#26} in (app S#11 S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {X#1=(var X#2);X#2=S#4;E#24} in S#11) S#10)] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {X#1=S#4;X#2=(var X#1);E#24} in (app S#11 S#10))] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#6,A#20} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#1=S#4;X#2=(var X#1);E#24} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app [.] S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app [.] S#10)], T#21 |-> (app [.] S#10), T#22 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=S#4;X#2=(var X#1);E#24}, E#23 |-> {X#1=S#4;E#24}, E#3 |-> {E#24}} and instantiated rules: (letrec {X#18=A#20[(app (letrec {X#1=S#4;X#2=(var X#1);E#24} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app (letrec {X#1=(var X#2);X#2=S#4;E#24} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {X#1=S#4;X#2=(var X#1);E#24} in S#11) S#10)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {X#1=S#4;X#2=(var X#1);E#24} in (app S#11 S#10))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(letrec {E#9} in (app S#11 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#21,A#17,T#14,T#6,A#20} Delta2 = {E#9} Delta3 = {(T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[(app (letrec {E#9} in S#11) T#22)], T#21 |-> (app (letrec {E#9} in S#11) T#22), S#10 |-> T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app (letrec {E#9} in S#11) T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(letrec {E#9} in (app S#11 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]))];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= A#20[(app A#21[(letrec {E#9} in (app S#11 S#10))] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])] ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {A#17,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22)];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, T#14 |-> A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(app (letrec {E#9} in S#11) S#10)] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=A#20[(app A#21[(letrec {E#9} in (app S#11 S#10))] T#22[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])];E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#9} in T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {E#9} in (app T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10)) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (letrec {E#9} in T#21) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in T#21) S#10), T#20 |-> (letrec {E#9} in T#21), S#11 |-> T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {E#9} in T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {E#9} in (app T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {X#22=T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#24} in S#11) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec X#22= T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] ;E#24 in (app S#11 S#10) ) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#20,T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (letrec {X#22=T#21;E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {X#22=T#21;E#24} in S#11) S#10), T#20 |-> (letrec {X#22=T#21;E#24} in S#11), E#9 |-> {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {X#22=T#21[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)];E#24} in (app S#11 S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {X#1=(var X#2);X#2=S#4;E#22} in S#11) S#10) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {X#1=S#4;X#2=(var X#1);E#22} in (app S#11 S#10)) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#9} Delta3 = {(S#10,(letrec {X#1=S#4;X#2=(var X#1);E#22} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app [.] S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app [.] S#10), T#20 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=S#4;X#2=(var X#1);E#22}, E#21 |-> {X#1=S#4;E#22}, E#3 |-> {E#22}} and instantiated rules: (letrec {X#18=(app (letrec {X#1=S#4;X#2=(var X#1);E#22} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=(app (letrec {X#1=(var X#2);X#2=S#4;E#22} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {X#1=S#4;X#2=(var X#1);E#22} in S#11) S#10);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {X#1=S#4;X#2=(var X#1);E#22} in (app S#11 S#10));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#18= (app (letrec {E#9} in S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) , (letrec X#18= (letrec {E#9} in (app S#11 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)])) ;E#8 ;EE#19[X#7,(var X#18)] in A#12[(var X#7)] ) ) where Delta1 = {T#14,T#6} Delta2 = {E#9} Delta3 = {(T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)],(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#18=(app (letrec {E#9} in S#11) T#20);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {E#8;EE#19[X#7,(var X#18)]}, A#17 |-> [.], T#14 |-> (app (letrec {E#9} in S#11) T#20), S#10 |-> T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]} and instantiated rules: (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) <-xch1- (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#18=(app (letrec {E#9} in S#11) T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]);E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#18=(letrec {E#9} in (app S#11 T#20[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)]));E#8;EE#19[X#7,(var X#18)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#1= (var X#2) ;X#2= S#4 ;E#15 ;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#1= S#4 ;X#2= (var X#1) ;E#15 ;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#1),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#8 |-> {X#1=S#4;X#2=(var X#1);E#15}, E#14 |-> {X#1=S#4;E#15}, E#3 |-> {E#15;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#1=S#4;X#2=(var X#1);E#15;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#1=(var X#2);X#2=S#4;E#15;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#1=S#4;X#2=(var X#1);E#15;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#1=S#4;X#2=(var X#1);E#15;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#2= A#15[(app (letrec {E#9} in S#11) S#10)] ;X#7= (var X#2) ;E#14 in A#12[(var X#7)] ) , (letrec X#2= (var X#7) ;X#7= A#15[(letrec {E#9} in (app S#11 S#10))] ;E#14 in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#8 |-> {X#2=(var X#7);E#14}, EE#13[.1,.2] |-> {[.1]=A#15[[.2]]}, X#1 |-> X#7, S#4 |-> A#15[(app (letrec {E#9} in S#11) S#10)], E#3 |-> {E#14}} and instantiated rules: (letrec {X#2=(var X#7);X#7=A#15[(app (letrec {E#9} in S#11) S#10)];E#14} in A#12[(var X#7)]) <-xch1- (letrec {X#2=A#15[(app (letrec {E#9} in S#11) S#10)];X#7=(var X#2);E#14} in A#12[(var X#7)]) ................................................................................ (letrec {X#2=(var X#7);X#7=A#15[(app (letrec {E#9} in S#11) S#10)];E#14} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#2=(var X#7);X#7=A#15[(letrec {E#9} in (app S#11 S#10))];E#14} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#2= A#15[(var X#16)] ;X#7= (var X#2) ;E#14 ;EE#17[X#16,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#2= (var X#7) ;X#7= A#15[(var X#16)] ;E#14 ;EE#17[X#16,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#7),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#8 |-> {X#2=(var X#7);E#14}, EE#13[.1,.2] |-> {[.1]=A#15[(var X#16)];EE#17[X#16,[.2]]}, X#1 |-> X#7, S#4 |-> A#15[(var X#16)], E#3 |-> {E#14;EE#17[X#16,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#2=(var X#7);X#7=A#15[(var X#16)];E#14;EE#17[X#16,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#2=A#15[(var X#16)];X#7=(var X#2);E#14;EE#17[X#16,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#2=(var X#7);X#7=A#15[(var X#16)];E#14;EE#17[X#16,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#2=(var X#7);X#7=A#15[(var X#16)];E#14;EE#17[X#16,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= A#15[(var X#17)] ;E#14 ;EE#18[X#7,(var X#16)] ;EE#19[X#17,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#16= A#15[(var X#17)] ;X#2= (var X#16) ;E#14 ;EE#18[X#7,(var X#16)] ;EE#19[X#17,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#16),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#8 |-> {X#2=(var X#16);E#14}, EE#13[.1,.2] |-> {X#16=A#15[(var X#17)];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#1 |-> X#16, S#4 |-> A#15[(var X#17)], E#3 |-> {E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (letrec {E#9} in S#11) S#10)]}} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#16=(var X#2);X#2=A#15[(var X#17)];E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#2=(var X#16);E#14;EE#18[X#7,(var X#16)];EE#19[X#17,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#16= (var X#2) ;X#2= A#15[(app (letrec {E#9} in S#11) S#10)] ;E#14 ;EE#17[X#7,(var X#16)] in A#12[(var X#7)] ) , (letrec X#16= A#15[(letrec {E#9} in (app S#11 S#10))] ;X#2= (var X#16) ;E#14 ;EE#17[X#7,(var X#16)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#16),[.]), ((var X#2),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], E#8 |-> {X#2=(var X#16);E#14}, EE#13[.1,.2] |-> {X#16=A#15[[.2]];EE#17[[.1],(var X#16)]}, X#1 |-> X#16, S#4 |-> A#15[(app (letrec {E#9} in S#11) S#10)], E#3 |-> {E#14;EE#17[X#7,(var X#16)]}} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#9} in S#11) S#10)];X#2=(var X#16);E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) <-xch1- (letrec {X#16=(var X#2);X#2=A#15[(app (letrec {E#9} in S#11) S#10)];E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#9} in S#11) S#10)];X#2=(var X#16);E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#9} in (app S#11 S#10))];X#2=(var X#16);E#14;EE#17[X#7,(var X#16)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#7) ;X#7= A#17[(app (letrec {E#9} in S#11) S#10)] ;E#8 in A#12[(var X#7)] ) , (letrec X#15= A#17[(letrec {E#9} in (app S#11 S#10))] ;X#7= (var X#15) ;E#8 in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#15),[.]), ((var X#7),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=A#17[[.2]];[.1]=(var X#15)}, X#2 |-> X#7, EE#16[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#15, S#4 |-> A#17[(app (letrec {E#9} in S#11) S#10)], E#3 |-> {E#8}, A#14 |-> [.], X#15 |-> X#15} and instantiated rules: (letrec {X#15=A#17[(app (letrec {E#9} in S#11) S#10)];X#7=(var X#15);E#8} in A#12[(var X#7)]) <-xch1- (letrec {X#15=(var X#7);X#7=A#17[(app (letrec {E#9} in S#11) S#10)];E#8} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=A#17[(app (letrec {E#9} in S#11) S#10)];X#7=(var X#15);E#8} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=A#17[(letrec {E#9} in (app S#11 S#10))];X#7=(var X#15);E#8} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= (var X#7) ;X#7= A#17[(var X#18)] ;E#8 ;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= A#17[(var X#18)] ;X#7= (var X#15) ;E#8 ;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#15),[.]), ((var X#7),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=A#17[(var X#18)];[.1]=(var X#15);EE#19[X#18,[.2]]}, X#2 |-> X#7, EE#16[.1,.2] |-> {[.1]=A#17[(var X#18)];EE#19[X#18,[.2]]}, X#1 |-> X#15, S#4 |-> A#17[(var X#18)], E#3 |-> {E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]}, A#14 |-> [.], X#15 |-> X#15} and instantiated rules: (letrec {X#15=A#17[(var X#18)];X#7=(var X#15);E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=(var X#7);X#7=A#17[(var X#18)];E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=A#17[(var X#18)];X#7=(var X#15);E#8;EE#19[X#18,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=A#17[(var X#18)];X#7=(var X#15);E#8;EE#19[X#18,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(app (letrec {E#9} in S#11) S#10)] ;X#16= (var X#15) ;E#8 ;EE#17[X#7,(var X#15)] in A#12[(var X#7)] ) , (letrec X#15= (var X#16) ;X#16= A#19[(letrec {E#9} in (app S#11 S#10))] ;E#8 ;EE#17[X#7,(var X#15)] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#16),[.]), ((var X#15),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=(var X#16);X#16=A#19[[.2]];EE#17[[.1],(var X#15)]}, X#2 |-> X#15, EE#18[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#16, S#4 |-> A#19[(app (letrec {E#9} in S#11) S#10)], E#3 |-> {E#8;EE#17[X#7,(var X#15)]}, A#14 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#15=(var X#16);X#16=A#19[(app (letrec {E#9} in S#11) S#10)];E#8;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=A#19[(app (letrec {E#9} in S#11) S#10)];X#16=(var X#15);E#8;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=(var X#16);X#16=A#19[(app (letrec {E#9} in S#11) S#10)];E#8;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=(var X#16);X#16=A#19[(letrec {E#9} in (app S#11 S#10))];E#8;EE#17[X#7,(var X#15)]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(var X#20)] ;X#16= (var X#15) ;E#8 ;EE#17[X#7,(var X#15)] ;EE#21[X#20,(app (letrec {E#9} in S#11) S#10)] in A#12[(var X#7)] ) , (letrec X#15= (var X#16) ;X#16= A#19[(var X#20)] ;E#8 ;EE#17[X#7,(var X#15)] ;EE#21[X#20,(letrec {E#9} in (app S#11 S#10))] in A#12[(var X#7)] ) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {(S#10,(letrec {E#9} in [.])), ((var X#16),[.]), ((var X#15),[.]), ((var X#7),A#12[[.]]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -xch1-> with input rules: T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] <-xch1- T#6[(letrec {X#1=(var X#2);X#2=S#4;E#3} in S#5)] and constraints: ................................................................................ (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {E#8;EE#13[X#7,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) and constraints: E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=S#4;X#2=(var X#1);E#3} in S#5)] =?= (letrec {E#8;EE#13[X#7,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)])} Delta1= {} Delta2= {E#9} Delta3= {(S#10,(letrec {E#9} in [.])),((var X#1),[.]),((var X#2),[.]),((var X#7),A#12[[.]]),((var X#7),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#7)], EE#13[.1,.2] |-> {X#15=(var X#16);X#16=A#19[(var X#20)];EE#17[[.1],(var X#15)];EE#21[X#20,[.2]]}, X#2 |-> X#15, EE#18[.1,.2] |-> {[.1]=A#19[(var X#20)];EE#21[X#20,[.2]]}, X#1 |-> X#16, S#4 |-> A#19[(var X#20)], E#3 |-> {E#8;EE#17[X#7,(var X#15)];EE#21[X#20,(app (letrec {E#9} in S#11) S#10)]}, A#14 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#8;EE#17[X#7,(var X#15)];EE#21[X#20,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) <-xch1- (letrec {X#15=A#19[(var X#20)];X#16=(var X#15);E#8;EE#17[X#7,(var X#15)];EE#21[X#20,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) ................................................................................ (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#8;EE#17[X#7,(var X#15)];EE#21[X#20,(app (letrec {E#9} in S#11) S#10)]} in A#12[(var X#7)]) -SR,lapp3-> (letrec {X#15=(var X#16);X#16=A#19[(var X#20)];E#8;EE#17[X#7,(var X#15)];EE#21[X#20,(letrec {E#9} in (app S#11 S#10))]} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( A#8[(app (\ X#4.S#6) T#10[S#2])] , A#8[(letrec {X#4=T#10[(letrec {E#1} in S#2)]} in S#6)] ) where Delta1 = {T#9,A#7,T#3,A#8} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#10[(letrec {E#1} in S#2)],(\ X#4.[.])), (T#10[(letrec {E#1} in S#2)],(letrec {X#4=[.]} in S#6))} Delta4= {} from overlapping <-SR,lbeta1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (\ X#4.S#6) S#5)] -SR,lbeta1-> A#7[(letrec {X#4=S#5} in S#6)] and constraints: (S#5,(\ X#4.[.])), (S#5,(letrec {X#4=[.]} in S#6)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (\ X#4.S#6) S#5)]} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(\ X#4.[.])),(S#5,(letrec {X#4=[.]} in S#6))} and found solution: Sol = {A#7 |-> A#8, T#3 |-> A#8[(app (\ X#4.S#6) T#10)], T#9 |-> (app (\ X#4.S#6) T#10), S#5 |-> T#10[(letrec {E#1} in S#2)]} and instantiated rules: A#8[(app (\ X#4.S#6) T#10[(letrec {E#1} in S#2)])] <-gc1- A#8[(app (\ X#4.S#6) T#10[S#2])] ................................................................................ A#8[(app (\ X#4.S#6) T#10[(letrec {E#1} in S#2)])] -SR,lbeta1-> A#8[(letrec {X#4=T#10[(letrec {E#1} in S#2)]} in S#6)] ================================================================================ Critical Pair: ( A#8[(app A#9[(app (\ X#4.S#6) S#5)] T#10[S#2])] , A#8[(app A#9[(letrec {X#4=S#5} in S#6)] T#10[(letrec {E#1} in S#2)])] ) where Delta1 = {A#7,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#5,(\ X#4.[.])), (S#5,(letrec {X#4=[.]} in S#6))} Delta4= {} from overlapping <-SR,lbeta1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (\ X#4.S#6) S#5)] -SR,lbeta1-> A#7[(letrec {X#4=S#5} in S#6)] and constraints: (S#5,(\ X#4.[.])), (S#5,(letrec {X#4=[.]} in S#6)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (\ X#4.S#6) S#5)]} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(\ X#4.[.])),(S#5,(letrec {X#4=[.]} in S#6))} and found solution: Sol = {T#3 |-> A#8[(app A#9[(app (\ X#4.S#6) S#5)] T#10)], A#7 |-> A#8[(app A#9 T#10[(letrec {E#1} in S#2)])]} and instantiated rules: A#8[(app A#9[(app (\ X#4.S#6) S#5)] T#10[(letrec {E#1} in S#2)])] <-gc1- A#8[(app A#9[(app (\ X#4.S#6) S#5)] T#10[S#2])] ................................................................................ A#8[(app A#9[(app (\ X#4.S#6) S#5)] T#10[(letrec {E#1} in S#2)])] -SR,lbeta1-> A#8[(app A#9[(letrec {X#4=S#5} in S#6)] T#10[(letrec {E#1} in S#2)])] ================================================================================ Critical Pair: ( (app (\ X#4.S#6) T#8[S#2]) , (letrec {X#4=T#8[(letrec {E#1} in S#2)]} in S#6) ) where Delta1 = {T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#8[(letrec {E#1} in S#2)],(\ X#4.[.])), (T#8[(letrec {E#1} in S#2)],(letrec {X#4=[.]} in S#6))} Delta4= {} from overlapping <-SR,lbeta1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (\ X#4.S#6) S#5)] -SR,lbeta1-> A#7[(letrec {X#4=S#5} in S#6)] and constraints: (S#5,(\ X#4.[.])), (S#5,(letrec {X#4=[.]} in S#6)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (\ X#4.S#6) S#5)]} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(\ X#4.[.])),(S#5,(letrec {X#4=[.]} in S#6))} and found solution: Sol = {A#7 |-> [.], T#3 |-> (app (\ X#4.S#6) T#8), S#5 |-> T#8[(letrec {E#1} in S#2)]} and instantiated rules: (app (\ X#4.S#6) T#8[(letrec {E#1} in S#2)]) <-gc1- (app (\ X#4.S#6) T#8[S#2]) ................................................................................ (app (\ X#4.S#6) T#8[(letrec {E#1} in S#2)]) -SR,lbeta1-> (letrec {X#4=T#8[(letrec {E#1} in S#2)]} in S#6) ================================================================================ Critical Pair: ( (letrec {E#5} in A#10[(app (\ X#4.S#7) T#12[S#2])]) , (letrec {E#5} in A#10[(letrec {X#4=T#12[(letrec {E#1} in S#2)]} in S#7)]) ) where Delta1 = {T#11,A#8,T#9,T#3,A#10} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#12[(letrec {E#1} in S#2)],(\ X#4.[.])), (T#12[(letrec {E#1} in S#2)],(letrec {X#4=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) and constraints: E#5/= {}, (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#4.[.])),(S#6,(letrec {X#4=[.]} in S#7))} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#10[(app (\ X#4.S#7) T#12)]), A#8 |-> A#10, T#9 |-> A#10[(app (\ X#4.S#7) T#12)], T#11 |-> (app (\ X#4.S#7) T#12), S#6 |-> T#12[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#5} in A#10[(app (\ X#4.S#7) T#12[(letrec {E#1} in S#2)])]) <-gc1- (letrec {E#5} in A#10[(app (\ X#4.S#7) T#12[S#2])]) ................................................................................ (letrec {E#5} in A#10[(app (\ X#4.S#7) T#12[(letrec {E#1} in S#2)])]) -SR,lbeta2-> (letrec {E#5} in A#10[(letrec {X#4=T#12[(letrec {E#1} in S#2)]} in S#7)]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#10[(app A#11[(app (\ X#4.S#7) S#6)] T#12[S#2])]) , (letrec E#5 in A#10[(app A#11[(letrec {X#4=S#6} in S#7)] T#12[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#8,T#9,T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) and constraints: E#5/= {}, (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#4.[.])),(S#6,(letrec {X#4=[.]} in S#7))} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#10[(app A#11[(app (\ X#4.S#7) S#6)] T#12)]), T#9 |-> A#10[(app A#11[(app (\ X#4.S#7) S#6)] T#12)], A#8 |-> A#10[(app A#11 T#12[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {E#5} in A#10[(app A#11[(app (\ X#4.S#7) S#6)] T#12[(letrec {E#1} in S#2)])]) <-gc1- (letrec {E#5} in A#10[(app A#11[(app (\ X#4.S#7) S#6)] T#12[S#2])]) ................................................................................ (letrec {E#5} in A#10[(app A#11[(app (\ X#4.S#7) S#6)] T#12[(letrec {E#1} in S#2)])]) -SR,lbeta2-> (letrec {E#5} in A#10[(app A#11[(letrec {X#4=S#6} in S#7)] T#12[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (\ X#4.S#7) T#10[S#2])) , (letrec {E#5} in (letrec {X#4=T#10[(letrec {E#1} in S#2)]} in S#7)) ) where Delta1 = {T#9,T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#10[(letrec {E#1} in S#2)],(\ X#4.[.])), (T#10[(letrec {E#1} in S#2)],(letrec {X#4=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) and constraints: E#5/= {}, (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#4.[.])),(S#6,(letrec {X#4=[.]} in S#7))} and found solution: Sol = {T#3 |-> (letrec {E#5} in (app (\ X#4.S#7) T#10)), A#8 |-> [.], T#9 |-> (app (\ X#4.S#7) T#10), S#6 |-> T#10[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#5} in (app (\ X#4.S#7) T#10[(letrec {E#1} in S#2)])) <-gc1- (letrec {E#5} in (app (\ X#4.S#7) T#10[S#2])) ................................................................................ (letrec {E#5} in (app (\ X#4.S#7) T#10[(letrec {E#1} in S#2)])) -SR,lbeta2-> (letrec {E#5} in (letrec {X#4=T#10[(letrec {E#1} in S#2)]} in S#7)) ================================================================================ Critical Pair: ( (letrec {X#10=T#9[S#2];E#12} in A#8[(app (\ X#4.S#7) S#6)]) , (letrec X#10= T#9[(letrec {E#1} in S#2)] ;E#12 in A#8[(letrec {X#4=S#6} in S#7)] ) ) where Delta1 = {T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) and constraints: E#5/= {}, (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#4.[.])),(S#6,(letrec {X#4=[.]} in S#7))} and found solution: Sol = {T#3 |-> (letrec {X#10=T#9;E#12} in A#8[(app (\ X#4.S#7) S#6)]), E#5 |-> {X#10=T#9[(letrec {E#1} in S#2)];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in A#8[(app (\ X#4.S#7) S#6)]) <-gc1- (letrec {X#10=T#9[S#2];E#12} in A#8[(app (\ X#4.S#7) S#6)]) ................................................................................ (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in A#8[(letrec {X#4=S#6} in S#7)]) ================================================================================ Critical Pair: ( A#8[(app (\ X#4.S#7) S#6)] , (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) ) where Delta1 = {} Delta2 = {E#1,E#5} Delta3 = {(A#8[(app (\ X#4.S#7) S#6)],(letrec {E#5} in [.])), (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) and constraints: E#5/= {}, (S#6,(\ X#4.[.])), (S#6,(letrec {X#4=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(\ X#4.[.])),(S#6,(letrec {X#4=[.]} in S#7))} and found solution: Sol = {T#3 |-> [.], S#2 |-> A#8[(app (\ X#4.S#7) S#6)], E#1 |-> {E#5}} and instantiated rules: (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) <-gc1- A#8[(app (\ X#4.S#7) S#6)] ................................................................................ (letrec {E#5} in A#8[(app (\ X#4.S#7) S#6)]) -SR,lbeta2-> (letrec {E#5} in A#8[(letrec {X#4=S#6} in S#7)]) ================================================================================ Critical Pair: ( (letrec E#6 ;EE#10[X#4,(app (\ X#5.S#8) S#7)] in A#12[(app A#13[(var X#4)] T#14[S#2])] ) , (letrec E#6 ;EE#10[X#4,(letrec {X#5=S#7} in S#8)] in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#9,T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#4),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])]), ((var X#4),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14)]), T#11 |-> A#12[(app A#13[(var X#4)] T#14)], A#9 |-> A#12[(app A#13 T#14[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])]) <-gc1- (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14[S#2])]) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[S#2] ;E#14 ;EE#10[X#4,(app (\ X#5.S#8) S#7)] in A#9[(var X#4)] ) , (letrec X#12= T#11[(letrec {E#1} in S#2)] ;E#14 ;EE#10[X#4,(letrec {X#5=S#7} in S#8)] in A#9[(var X#4)] ) ) where Delta1 = {T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#12=T#11;E#14;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]), E#6 |-> {X#12=T#11[(letrec {E#1} in S#2)];E#14}, E#13 |-> {E#14;EE#10[X#4,(app (\ X#5.S#8) S#7)]}} and instantiated rules: (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) <-gc1- (letrec {X#12=T#11[S#2];E#14;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=A#15[(app (\ X#5.S#8) T#17[S#2])];E#6} in A#9[(var X#4)]) , (letrec X#4= A#15[(letrec {X#5=T#17[(letrec {E#1} in S#2)]} in S#8)] ;E#6 in A#9[(var X#4)] ) ) where Delta1 = {T#16,A#14,T#11,T#3,A#15} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#17[(letrec {E#1} in S#2)],(\ X#5.[.])), (T#17[(letrec {E#1} in S#2)],(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app (\ X#5.S#8) T#17)];E#6} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[[.2]]}, X#12 |-> X#4, E#13 |-> {E#6}, A#14 |-> A#15, T#11 |-> A#15[(app (\ X#5.S#8) T#17)], T#16 |-> (app (\ X#5.S#8) T#17), S#7 |-> T#17[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=A#15[(app (\ X#5.S#8) T#17[(letrec {E#1} in S#2)])];E#6} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app (\ X#5.S#8) T#17[S#2])];E#6} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app (\ X#5.S#8) T#17[(letrec {E#1} in S#2)])];E#6} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#4=A#15[(letrec {X#5=T#17[(letrec {E#1} in S#2)]} in S#8)];E#6} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= A#15[(app A#16[(app (\ X#5.S#8) S#7)] T#17[S#2])] ;E#6 in A#9[(var X#4)] ) , (letrec X#4= A#15[(app A#16[(letrec {X#5=S#7} in S#8)] T#17[(letrec {E#1} in S#2)])] ;E#6 in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app A#16[(app (\ X#5.S#8) S#7)] T#17)];E#6} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[(app A#16[[.2]] T#17[(letrec {E#1} in S#2)])]}, X#12 |-> X#4, E#13 |-> {E#6}, T#11 |-> A#15[(app A#16[(app (\ X#5.S#8) S#7)] T#17)], A#14 |-> A#15[(app A#16 T#17[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=A#15[(app A#16[(app (\ X#5.S#8) S#7)] T#17[(letrec {E#1} in S#2)])];E#6} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app A#16[(app (\ X#5.S#8) S#7)] T#17[S#2])];E#6} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app A#16[(app (\ X#5.S#8) S#7)] T#17[(letrec {E#1} in S#2)])];E#6} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#4=A#15[(app A#16[(letrec {X#5=S#7} in S#8)] T#17[(letrec {E#1} in S#2)])];E#6} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=(app (\ X#5.S#8) T#15[S#2]);E#6} in A#9[(var X#4)]) , (letrec X#4= (letrec {X#5=T#15[(letrec {E#1} in S#2)]} in S#8) ;E#6 in A#9[(var X#4)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#15[(letrec {E#1} in S#2)],(\ X#5.[.])), (T#15[(letrec {E#1} in S#2)],(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(app (\ X#5.S#8) T#15);E#6} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=[.2]}, X#12 |-> X#4, E#13 |-> {E#6}, A#14 |-> [.], T#11 |-> (app (\ X#5.S#8) T#15), S#7 |-> T#15[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=(app (\ X#5.S#8) T#15[(letrec {E#1} in S#2)]);E#6} in A#9[(var X#4)]) <-gc1- (letrec {X#4=(app (\ X#5.S#8) T#15[S#2]);E#6} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=(app (\ X#5.S#8) T#15[(letrec {E#1} in S#2)]);E#6} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#4=(letrec {X#5=T#15[(letrec {E#1} in S#2)]} in S#8);E#6} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= A#17[(app A#18[(var X#15)] T#19[S#2])] ;E#6 ;EE#16[X#15,(app (\ X#5.S#8) S#7)] in A#9[(var X#4)] ) , (letrec X#4= A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])] ;E#6 ;EE#16[X#15,(letrec {X#5=S#7} in S#8)] in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#17[(app A#18[(var X#15)] T#19)];E#6;EE#16[X#15,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];EE#16[X#15,[.2]]}, X#12 |-> X#4, E#13 |-> {E#6;EE#16[X#15,(app (\ X#5.S#8) S#7)]}, T#11 |-> A#17[(app A#18[(var X#15)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#15,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[S#2])];E#6;EE#16[X#15,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#15,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#15,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(app A#20[(var X#16)] T#21[S#2])] ;E#6 ;EE#17[X#4,(var X#15)] ;EE#18[X#16,(app (\ X#5.S#8) S#7)] in A#9[(var X#4)] ) , (letrec X#15= A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])] ;E#6 ;EE#17[X#4,(var X#15)] ;EE#18[X#16,(letrec {X#5=S#7} in S#8)] in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#19[(app A#20[(var X#16)] T#21)];E#6;EE#17[X#4,(var X#15)];EE#18[X#16,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];EE#17[[.1],(var X#15)];EE#18[X#16,[.2]]}, X#12 |-> X#15, E#13 |-> {E#6;EE#17[X#4,(var X#15)];EE#18[X#16,(app (\ X#5.S#8) S#7)]}, T#11 |-> A#19[(app A#20[(var X#16)] T#21)], A#14 |-> A#19[(app A#20 T#21[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#6;EE#17[X#4,(var X#15)];EE#18[X#16,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[S#2])];E#6;EE#17[X#4,(var X#15)];EE#18[X#16,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#6;EE#17[X#4,(var X#15)];EE#18[X#16,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#6;EE#17[X#4,(var X#15)];EE#18[X#16,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app (\ X#5.S#8) T#19[S#2])] ;E#6 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= A#17[(letrec {X#5=T#19[(letrec {E#1} in S#2)]} in S#8)] ;E#6 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#18,A#14,T#11,T#3,A#17} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#19[(letrec {E#1} in S#2)],(\ X#5.[.])), (T#19[(letrec {E#1} in S#2)],(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app (\ X#5.S#8) T#19)];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[[.2]];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#6;EE#16[X#4,(var X#15)]}, A#14 |-> A#17, T#11 |-> A#17[(app (\ X#5.S#8) T#19)], T#18 |-> (app (\ X#5.S#8) T#19), S#7 |-> T#19[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#15=A#17[(app (\ X#5.S#8) T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app (\ X#5.S#8) T#19[S#2])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app (\ X#5.S#8) T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#15=A#17[(letrec {X#5=T#19[(letrec {E#1} in S#2)]} in S#8)];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app A#18[(app (\ X#5.S#8) S#7)] T#19[S#2])] ;E#6 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= A#17[(app A#18[(letrec {X#5=S#7} in S#8)] T#19[(letrec {E#1} in S#2)])] ;E#6 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app A#18[(app (\ X#5.S#8) S#7)] T#19)];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[(app A#18[[.2]] T#19[(letrec {E#1} in S#2)])];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#6;EE#16[X#4,(var X#15)]}, T#11 |-> A#17[(app A#18[(app (\ X#5.S#8) S#7)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#15=A#17[(app A#18[(app (\ X#5.S#8) S#7)] T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app A#18[(app (\ X#5.S#8) S#7)] T#19[S#2])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app A#18[(app (\ X#5.S#8) S#7)] T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#15=A#17[(app A#18[(letrec {X#5=S#7} in S#8)] T#19[(letrec {E#1} in S#2)])];E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= (app (\ X#5.S#8) T#17[S#2]) ;E#6 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= (letrec {X#5=T#17[(letrec {E#1} in S#2)]} in S#8) ;E#6 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#17[(letrec {E#1} in S#2)],(\ X#5.[.])), (T#17[(letrec {E#1} in S#2)],(letrec {X#5=[.]} in S#8)), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {E#6;EE#10[X#4,(letrec {X#5=S#7} in S#8)]} in A#9[(var X#4)]) and constraints: (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#6;EE#10[X#4,(app (\ X#5.S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=(app (\ X#5.S#8) T#17);E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=[.2];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#6;EE#16[X#4,(var X#15)]}, A#14 |-> [.], T#11 |-> (app (\ X#5.S#8) T#17), S#7 |-> T#17[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#15=(app (\ X#5.S#8) T#17[(letrec {E#1} in S#2)]);E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=(app (\ X#5.S#8) T#17[S#2]);E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=(app (\ X#5.S#8) T#17[(letrec {E#1} in S#2)]);E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lbeta3-> (letrec {X#15=(letrec {X#5=T#17[(letrec {E#1} in S#2)]} in S#8);E#6;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=(\ X#5.S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[S#2])]) , (letrec X#4= (\ X#5.S#7) ;E#6 in A#10[(app A#11[(\ X#5.S#7)] T#12[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#8,T#9,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#10[(app A#11[[.]] T#12[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,cp-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#7);E#6} in A#8[(var X#4)]) -SR,cp-in1-> (letrec {X#4=(\ X#5.S#7);E#6} in A#8[(\ X#5.S#7)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#7);E#6} in A#10[(app A#11[(var X#4)] T#12)]), T#9 |-> A#10[(app A#11[(var X#4)] T#12)], A#8 |-> A#10[(app A#11 T#12[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])]) <-gc1- (letrec {X#4=(\ X#5.S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[S#2])]) ................................................................................ (letrec {X#4=(\ X#5.S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])]) -SR,cp-in1-> (letrec {X#4=(\ X#5.S#7);E#6} in A#10[(app A#11[(\ X#5.S#7)] T#12[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec {X#10=T#9[S#2];X#4=(\ X#5.S#7);E#12} in A#8[(var X#4)]) , (letrec X#10= T#9[(letrec {E#1} in S#2)] ;X#4= (\ X#5.S#7) ;E#12 in A#8[(\ X#5.S#7)] ) ) where Delta1 = {T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#8[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#7);E#6} in A#8[(var X#4)]) -SR,cp-in1-> (letrec {X#4=(\ X#5.S#7);E#6} in A#8[(\ X#5.S#7)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#10=T#9;X#4=(\ X#5.S#7);E#12} in A#8[(var X#4)]), E#6 |-> {X#10=T#9[(letrec {E#1} in S#2)];E#12}, E#11 |-> {X#4=(\ X#5.S#7);E#12}} and instantiated rules: (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=(\ X#5.S#7);E#12} in A#8[(var X#4)]) <-gc1- (letrec {X#10=T#9[S#2];X#4=(\ X#5.S#7);E#12} in A#8[(var X#4)]) ................................................................................ (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=(\ X#5.S#7);E#12} in A#8[(var X#4)]) -SR,cp-in1-> (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=(\ X#5.S#7);E#12} in A#8[(\ X#5.S#7)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#8) ;E#7 ;VV#10|X#6,(var X#4)| in A#12[(app A#13[(var X#6)] T#14[S#2])] ) , (letrec X#4= (\ X#5.S#8) ;E#7 ;VV#10|X#6,(var X#4)| in A#12[(app A#13[(\ X#5.S#8)] T#14[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#9,T#11,T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])]), ((var X#4),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#9[(var X#6)]) -SR,cp-in2-> (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#9[(\ X#5.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#9[(var X#6)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#9[[.]]),((var X#4),[.])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#12[(app A#13[(var X#6)] T#14)]), T#11 |-> A#12[(app A#13[(var X#6)] T#14)], A#9 |-> A#12[(app A#13 T#14[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#12[(app A#13[(var X#6)] T#14[(letrec {E#1} in S#2)])]) <-gc1- (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#12[(app A#13[(var X#6)] T#14[S#2])]) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#12[(app A#13[(var X#6)] T#14[(letrec {E#1} in S#2)])]) -SR,cp-in2-> (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#12[(app A#13[(\ X#5.S#8)] T#14[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[S#2] ;X#4= (\ X#5.S#8) ;E#14 ;VV#10|X#6,(var X#4)| in A#9[(var X#6)] ) , (letrec X#12= T#11[(letrec {E#1} in S#2)] ;X#4= (\ X#5.S#8) ;E#14 ;VV#10|X#6,(var X#4)| in A#9[(\ X#5.S#8)] ) ) where Delta1 = {T#3} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#9[[.]]), ((var X#4),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#9[(var X#6)]) -SR,cp-in2-> (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#9[(\ X#5.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;VV#10|X#6,(var X#4)|} in A#9[(var X#6)])} Delta1= {} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#9[[.]]),((var X#4),[.])} and found solution: Sol = {T#3 |-> (letrec {X#12=T#11;X#4=(\ X#5.S#8);E#14;VV#10|X#6,(var X#4)|} in A#9[(var X#6)]), E#7 |-> {X#12=T#11[(letrec {E#1} in S#2)];E#14}, E#13 |-> {X#4=(\ X#5.S#8);E#14;VV#10|X#6,(var X#4)|}} and instantiated rules: (letrec {X#12=T#11[(letrec {E#1} in S#2)];X#4=(\ X#5.S#8);E#14;VV#10|X#6,(var X#4)|} in A#9[(var X#6)]) <-gc1- (letrec {X#12=T#11[S#2];X#4=(\ X#5.S#8);E#14;VV#10|X#6,(var X#4)|} in A#9[(var X#6)]) ................................................................................ (letrec {X#12=T#11[(letrec {E#1} in S#2)];X#4=(\ X#5.S#8);E#14;VV#10|X#6,(var X#4)|} in A#9[(var X#6)]) -SR,cp-in2-> (letrec {X#12=T#11[(letrec {E#1} in S#2)];X#4=(\ X#5.S#8);E#14;VV#10|X#6,(var X#4)|} in A#9[(\ X#5.S#8)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#8) ;E#7 ;EE#11[X#6,A#9[(var X#4)]] in A#13[(app A#14[(var X#6)] T#15[S#2])] ) , (letrec X#4= (\ X#5.S#8) ;E#7 ;EE#11[X#6,A#9[(\ X#5.S#8)]] in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#10,T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#9[[.]]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {E#1} in S#2)])]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#13[(app A#14[(var X#6)] T#15)]), T#12 |-> A#13[(app A#14[(var X#6)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in S#2)])]) <-gc1- (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#13[(app A#14[(var X#6)] T#15[S#2])]) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in S#2)])]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[S#2] ;X#4= (\ X#5.S#8) ;E#15 ;EE#11[X#6,A#9[(var X#4)]] in A#10[(var X#6)] ) , (letrec X#13= T#12[(letrec {E#1} in S#2)] ;X#4= (\ X#5.S#8) ;E#15 ;EE#11[X#6,A#9[(\ X#5.S#8)]] in A#10[(var X#6)] ) ) where Delta1 = {T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#9[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#13=T#12;X#4=(\ X#5.S#8);E#15;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]), E#7 |-> {X#13=T#12[(letrec {E#1} in S#2)];E#15}, E#14 |-> {X#4=(\ X#5.S#8);E#15;EE#11[X#6,A#9[(var X#4)]]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1} in S#2)];X#4=(\ X#5.S#8);E#15;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) <-gc1- (letrec {X#13=T#12[S#2];X#4=(\ X#5.S#8);E#15;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1} in S#2)];X#4=(\ X#5.S#8);E#15;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#13=T#12[(letrec {E#1} in S#2)];X#4=(\ X#5.S#8);E#15;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#8) ;X#6= A#16[A#18[(app A#19[(var X#4)] T#20[S#2])]] ;E#7 in A#10[(var X#6)] ) , (letrec X#4= (\ X#5.S#8) ;X#6= A#16[A#18[(app A#19[(\ X#5.S#8)] T#20[(letrec {E#1} in S#2)])]] ;E#7 in A#10[(var X#6)] ) ) where Delta1 = {T#17,A#15,T#12,T#3,A#9,A#16} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#18[(app A#19[[.]] T#20[(letrec {E#1} in S#2)])]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#8);X#6=A#16[A#18[(app A#19[(var X#4)] T#20)]];E#7} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#6, E#14 |-> {X#4=(\ X#5.S#8);E#7}, A#15 |-> A#16, T#12 |-> A#16[A#18[(app A#19[(var X#4)] T#20)]], T#17 |-> A#18[(app A#19[(var X#4)] T#20)], A#9 |-> A#18[(app A#19 T#20[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#8);X#6=A#16[A#18[(app A#19[(var X#4)] T#20[(letrec {E#1} in S#2)])]];E#7} in A#10[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#8);X#6=A#16[A#18[(app A#19[(var X#4)] T#20[S#2])]];E#7} in A#10[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#8);X#6=A#16[A#18[(app A#19[(var X#4)] T#20[(letrec {E#1} in S#2)])]];E#7} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);X#6=A#16[A#18[(app A#19[(\ X#5.S#8)] T#20[(letrec {E#1} in S#2)])]];E#7} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#8) ;X#6= A#16[(app A#17[A#9[(var X#4)]] T#18[S#2])] ;E#7 in A#10[(var X#6)] ) , (letrec X#4= (\ X#5.S#8) ;X#6= A#16[(app A#17[A#9[(\ X#5.S#8)]] T#18[(letrec {E#1} in S#2)])] ;E#7 in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#9[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[A#9[(var X#4)]] T#18)];E#7} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1} in S#2)])]}, X#13 |-> X#6, E#14 |-> {X#4=(\ X#5.S#8);E#7}, T#12 |-> A#16[(app A#17[A#9[(var X#4)]] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[A#9[(var X#4)]] T#18[(letrec {E#1} in S#2)])];E#7} in A#10[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[A#9[(var X#4)]] T#18[S#2])];E#7} in A#10[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[A#9[(var X#4)]] T#18[(letrec {E#1} in S#2)])];E#7} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[A#9[(\ X#5.S#8)]] T#18[(letrec {E#1} in S#2)])];E#7} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#8) ;X#6= A#16[(app A#17[(var X#4)] T#18[S#2])] ;E#7 in A#10[(var X#6)] ) , (letrec X#4= (\ X#5.S#8) ;X#6= A#16[(app A#17[(\ X#5.S#8)] T#18[(letrec {E#1} in S#2)])] ;E#7 in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#16[(app A#17[[.]] T#18[(letrec {E#1} in S#2)])]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[(var X#4)] T#18)];E#7} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#6, E#14 |-> {X#4=(\ X#5.S#8);E#7}, A#15 |-> [.], T#12 |-> A#16[(app A#17[(var X#4)] T#18)], A#9 |-> A#16[(app A#17 T#18[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[(var X#4)] T#18[(letrec {E#1} in S#2)])];E#7} in A#10[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[(var X#4)] T#18[S#2])];E#7} in A#10[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[(var X#4)] T#18[(letrec {E#1} in S#2)])];E#7} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);X#6=A#16[(app A#17[(\ X#5.S#8)] T#18[(letrec {E#1} in S#2)])];E#7} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#8) ;X#6= A#18[(app A#19[(var X#16)] T#20[S#2])] ;E#7 ;EE#17[X#16,A#9[(var X#4)]] in A#10[(var X#6)] ) , (letrec X#4= (\ X#5.S#8) ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#2)])] ;E#7 ;EE#17[X#16,A#9[(\ X#5.S#8)]] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#9[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#8);X#6=A#18[(app A#19[(var X#16)] T#20)];E#7;EE#17[X#16,A#9[(var X#4)]]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#2)])];EE#17[X#16,[.2]]}, X#13 |-> X#6, E#14 |-> {X#4=(\ X#5.S#8);E#7;EE#17[X#16,A#9[(var X#4)]]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#8);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#2)])];E#7;EE#17[X#16,A#9[(var X#4)]]} in A#10[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#8);X#6=A#18[(app A#19[(var X#16)] T#20[S#2])];E#7;EE#17[X#16,A#9[(var X#4)]]} in A#10[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#8);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#2)])];E#7;EE#17[X#16,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#2)])];E#7;EE#17[X#16,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[S#2])] ;X#4= (\ X#5.S#8) ;E#7 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,A#9[(var X#4)]] in A#10[(var X#6)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#2)])] ;X#4= (\ X#5.S#8) ;E#7 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,A#9[(\ X#5.S#8)]] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#9[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];X#4=(\ X#5.S#8);E#7;EE#18[X#6,(var X#16)];EE#19[X#17,A#9[(var X#4)]]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#2)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {X#4=(\ X#5.S#8);E#7;EE#18[X#6,(var X#16)];EE#19[X#17,A#9[(var X#4)]]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#18[X#6,(var X#16)];EE#19[X#17,A#9[(var X#4)]]} in A#10[(var X#6)]) <-gc1- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[S#2])];X#4=(\ X#5.S#8);E#7;EE#18[X#6,(var X#16)];EE#19[X#17,A#9[(var X#4)]]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#18[X#6,(var X#16)];EE#19[X#17,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#18[X#6,(var X#16)];EE#19[X#17,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[A#20[(app A#21[(var X#4)] T#22[S#2])]] ;X#4= (\ X#5.S#8) ;E#7 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[A#20[(app A#21[(\ X#5.S#8)] T#22[(letrec {E#1} in S#2)])]] ;X#4= (\ X#5.S#8) ;E#7 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {T#19,A#15,T#12,T#3,A#9,A#18} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#20[(app A#21[[.]] T#22[(letrec {E#1} in S#2)])]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[A#20[(app A#21[(var X#4)] T#22)]];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[A#20[(app A#21[(var X#4)] T#22)]], T#19 |-> A#20[(app A#21[(var X#4)] T#22)], A#9 |-> A#20[(app A#21 T#22[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#16=A#18[A#20[(app A#21[(var X#4)] T#22[(letrec {E#1} in S#2)])]];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-gc1- (letrec {X#16=A#18[A#20[(app A#21[(var X#4)] T#22[S#2])]];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[A#20[(app A#21[(var X#4)] T#22[(letrec {E#1} in S#2)])]];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#16=A#18[A#20[(app A#21[(\ X#5.S#8)] T#22[(letrec {E#1} in S#2)])]];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[A#9[(var X#4)]] T#20[S#2])] ;X#4= (\ X#5.S#8) ;E#7 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[A#9[(\ X#5.S#8)]] T#20[(letrec {E#1} in S#2)])] ;X#4= (\ X#5.S#8) ;E#7 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#9[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app A#19[A#9[(var X#4)]] T#20)];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1} in S#2)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]}, T#12 |-> A#18[(app A#19[A#9[(var X#4)]] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[A#9[(var X#4)]] T#20[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-gc1- (letrec {X#16=A#18[(app A#19[A#9[(var X#4)]] T#20[S#2])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[A#9[(var X#4)]] T#20[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#16=A#18[(app A#19[A#9[(\ X#5.S#8)]] T#20[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(var X#4)] T#20[S#2])] ;X#4= (\ X#5.S#8) ;E#7 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[(\ X#5.S#8)] T#20[(letrec {E#1} in S#2)])] ;X#4= (\ X#5.S#8) ;E#7 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#3,A#9} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),A#18[(app A#19[[.]] T#20[(letrec {E#1} in S#2)])]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(\ X#5.S#8)]]} in A#10[(var X#6)]) and constraints: A#9/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#8);E#7;EE#11[X#6,A#9[(var X#4)]]} in A#10[(var X#6)])} Delta1= {A#9} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),A#9[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app A#19[(var X#4)] T#20)];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]}, A#15 |-> [.], T#12 |-> A#18[(app A#19[(var X#4)] T#20)], A#9 |-> A#18[(app A#19 T#20[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(var X#4)] T#20[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-gc1- (letrec {X#16=A#18[(app A#19[(var X#4)] T#20[S#2])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(var X#4)] T#20[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,cp-e1-> (letrec {X#16=A#18[(app A#19[(\ X#5.S#8)] T#20[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#8);E#7;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#9) ;E#8 ;EE#12[X#6,A#10[(var X#7)]] ;VV#13|X#7,(var X#4)| in A#15[(app A#16[(var X#6)] T#17[S#2])] ) , (letrec X#4= (\ X#5.S#9) ;E#8 ;EE#12[X#6,A#10[(\ X#5.S#9)]] ;VV#13|X#7,(var X#4)| in A#15[(app A#16[(var X#6)] T#17[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#11,T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#15[(app A#16[[.]] T#17[(letrec {E#1} in S#2)])]), ((var X#7),A#10[[.]]), ((var X#4),[.]), ((var X#6),A#15[(app A#16[[.]] T#17[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#15[(app A#16[(var X#6)] T#17)]), T#14 |-> A#15[(app A#16[(var X#6)] T#17)], A#11 |-> A#15[(app A#16 T#17[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#15[(app A#16[(var X#6)] T#17[(letrec {E#1} in S#2)])]) <-gc1- (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#15[(app A#16[(var X#6)] T#17[S#2])]) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#15[(app A#16[(var X#6)] T#17[(letrec {E#1} in S#2)])]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#15[(app A#16[(var X#6)] T#17[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[S#2] ;X#4= (\ X#5.S#9) ;E#17 ;EE#12[X#6,A#10[(var X#7)]] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#15= T#14[(letrec {E#1} in S#2)] ;X#4= (\ X#5.S#9) ;E#17 ;EE#12[X#6,A#10[(\ X#5.S#9)]] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#10[[.]]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=T#14;X#4=(\ X#5.S#9);E#17;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), E#8 |-> {X#15=T#14[(letrec {E#1} in S#2)];E#17}, E#16 |-> {X#4=(\ X#5.S#9);E#17;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|}} and instantiated rules: (letrec {X#15=T#14[(letrec {E#1} in S#2)];X#4=(\ X#5.S#9);E#17;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#15=T#14[S#2];X#4=(\ X#5.S#9);E#17;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#15=T#14[(letrec {E#1} in S#2)];X#4=(\ X#5.S#9);E#17;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#15=T#14[(letrec {E#1} in S#2)];X#4=(\ X#5.S#9);E#17;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#9) ;X#6= A#18[A#20[(app A#21[(var X#7)] T#22[S#2])]] ;E#8 ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#4= (\ X#5.S#9) ;X#6= A#18[A#20[(app A#21[(\ X#5.S#9)] T#22[(letrec {E#1} in S#2)])]] ;E#8 ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {T#19,A#17,T#14,T#3,A#10,A#18} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#20[(app A#21[[.]] T#22[(letrec {E#1} in S#2)])]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#9);X#6=A#18[A#20[(app A#21[(var X#7)] T#22)]];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#6, E#16 |-> {X#4=(\ X#5.S#9);E#8;VV#13|X#7,(var X#4)|}, A#17 |-> A#18, T#14 |-> A#18[A#20[(app A#21[(var X#7)] T#22)]], T#19 |-> A#20[(app A#21[(var X#7)] T#22)], A#10 |-> A#20[(app A#21 T#22[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#9);X#6=A#18[A#20[(app A#21[(var X#7)] T#22[(letrec {E#1} in S#2)])]];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#9);X#6=A#18[A#20[(app A#21[(var X#7)] T#22[S#2])]];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#9);X#6=A#18[A#20[(app A#21[(var X#7)] T#22[(letrec {E#1} in S#2)])]];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);X#6=A#18[A#20[(app A#21[(\ X#5.S#9)] T#22[(letrec {E#1} in S#2)])]];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#9) ;X#6= A#18[(app A#19[A#10[(var X#7)]] T#20[S#2])] ;E#8 ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#4= (\ X#5.S#9) ;X#6= A#18[(app A#19[A#10[(\ X#5.S#9)]] T#20[(letrec {E#1} in S#2)])] ;E#8 ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {A#17,T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#10[[.]]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[A#10[(var X#7)]] T#20)];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {E#1} in S#2)])]}, X#15 |-> X#6, E#16 |-> {X#4=(\ X#5.S#9);E#8;VV#13|X#7,(var X#4)|}, T#14 |-> A#18[(app A#19[A#10[(var X#7)]] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[A#10[(var X#7)]] T#20[(letrec {E#1} in S#2)])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[A#10[(var X#7)]] T#20[S#2])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[A#10[(var X#7)]] T#20[(letrec {E#1} in S#2)])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[A#10[(\ X#5.S#9)]] T#20[(letrec {E#1} in S#2)])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#9) ;X#6= A#18[(app A#19[(var X#7)] T#20[S#2])] ;E#8 ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#4= (\ X#5.S#9) ;X#6= A#18[(app A#19[(\ X#5.S#9)] T#20[(letrec {E#1} in S#2)])] ;E#8 ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#18[(app A#19[[.]] T#20[(letrec {E#1} in S#2)])]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[(var X#7)] T#20)];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#6, E#16 |-> {X#4=(\ X#5.S#9);E#8;VV#13|X#7,(var X#4)|}, A#17 |-> [.], T#14 |-> A#18[(app A#19[(var X#7)] T#20)], A#10 |-> A#18[(app A#19 T#20[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[(var X#7)] T#20[(letrec {E#1} in S#2)])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[(var X#7)] T#20[S#2])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[(var X#7)] T#20[(letrec {E#1} in S#2)])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);X#6=A#18[(app A#19[(\ X#5.S#9)] T#20[(letrec {E#1} in S#2)])];E#8;VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#4= (\ X#5.S#9) ;X#6= A#20[(app A#21[(var X#18)] T#22[S#2])] ;E#8 ;EE#19[X#18,A#10[(var X#7)]] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#4= (\ X#5.S#9) ;X#6= A#20[(app A#21[(var X#18)] T#22[(letrec {E#1} in S#2)])] ;E#8 ;EE#19[X#18,A#10[(\ X#5.S#9)]] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {A#17,T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#10[[.]]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(\ X#5.S#9);X#6=A#20[(app A#21[(var X#18)] T#22)];E#8;EE#19[X#18,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {E#1} in S#2)])];EE#19[X#18,[.2]]}, X#15 |-> X#6, E#16 |-> {X#4=(\ X#5.S#9);E#8;EE#19[X#18,A#10[(var X#7)]];VV#13|X#7,(var X#4)|}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(\ X#5.S#9);X#6=A#20[(app A#21[(var X#18)] T#22[(letrec {E#1} in S#2)])];E#8;EE#19[X#18,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#4=(\ X#5.S#9);X#6=A#20[(app A#21[(var X#18)] T#22[S#2])];E#8;EE#19[X#18,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#4=(\ X#5.S#9);X#6=A#20[(app A#21[(var X#18)] T#22[(letrec {E#1} in S#2)])];E#8;EE#19[X#18,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);X#6=A#20[(app A#21[(var X#18)] T#22[(letrec {E#1} in S#2)])];E#8;EE#19[X#18,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[S#2])] ;X#4= (\ X#5.S#9) ;E#8 ;EE#20[X#6,(var X#18)] ;EE#21[X#19,A#10[(var X#7)]] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {E#1} in S#2)])] ;X#4= (\ X#5.S#9) ;E#8 ;EE#20[X#6,(var X#18)] ;EE#21[X#19,A#10[(\ X#5.S#9)]] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {A#17,T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#10[[.]]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];X#4=(\ X#5.S#9);E#8;EE#20[X#6,(var X#18)];EE#21[X#19,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {E#1} in S#2)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {X#4=(\ X#5.S#9);E#8;EE#20[X#6,(var X#18)];EE#21[X#19,A#10[(var X#7)]];VV#13|X#7,(var X#4)|}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#20[X#6,(var X#18)];EE#21[X#19,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[S#2])];X#4=(\ X#5.S#9);E#8;EE#20[X#6,(var X#18)];EE#21[X#19,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#20[X#6,(var X#18)];EE#21[X#19,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#20[X#6,(var X#18)];EE#21[X#19,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(app A#23[(var X#7)] T#24[S#2])]] ;X#4= (\ X#5.S#9) ;E#8 ;EE#19[X#6,(var X#18)] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#18= A#20[A#22[(app A#23[(\ X#5.S#9)] T#24[(letrec {E#1} in S#2)])]] ;X#4= (\ X#5.S#9) ;E#8 ;EE#19[X#6,(var X#18)] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {T#21,A#17,T#14,T#3,A#10,A#20} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#22[(app A#23[[.]] T#24[(letrec {E#1} in S#2)])]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#18=A#20[A#22[(app A#23[(var X#7)] T#24)]];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|}, A#17 |-> A#20, T#14 |-> A#20[A#22[(app A#23[(var X#7)] T#24)]], T#21 |-> A#22[(app A#23[(var X#7)] T#24)], A#10 |-> A#22[(app A#23 T#24[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#18=A#20[A#22[(app A#23[(var X#7)] T#24[(letrec {E#1} in S#2)])]];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#18=A#20[A#22[(app A#23[(var X#7)] T#24[S#2])]];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#18=A#20[A#22[(app A#23[(var X#7)] T#24[(letrec {E#1} in S#2)])]];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#18=A#20[A#22[(app A#23[(\ X#5.S#9)] T#24[(letrec {E#1} in S#2)])]];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[A#10[(var X#7)]] T#22[S#2])] ;X#4= (\ X#5.S#9) ;E#8 ;EE#19[X#6,(var X#18)] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#18= A#20[(app A#21[A#10[(\ X#5.S#9)]] T#22[(letrec {E#1} in S#2)])] ;X#4= (\ X#5.S#9) ;E#8 ;EE#19[X#6,(var X#18)] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {A#17,T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#10[[.]]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#18=A#20[(app A#21[A#10[(var X#7)]] T#22)];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {E#1} in S#2)])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|}, T#14 |-> A#20[(app A#21[A#10[(var X#7)]] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[A#10[(var X#7)]] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#18=A#20[(app A#21[A#10[(var X#7)]] T#22[S#2])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#18=A#20[(app A#21[A#10[(var X#7)]] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#18=A#20[(app A#21[A#10[(\ X#5.S#9)]] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#7)] T#22[S#2])] ;X#4= (\ X#5.S#9) ;E#8 ;EE#19[X#6,(var X#18)] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) , (letrec X#18= A#20[(app A#21[(\ X#5.S#9)] T#22[(letrec {E#1} in S#2)])] ;X#4= (\ X#5.S#9) ;E#8 ;EE#19[X#6,(var X#18)] ;VV#13|X#7,(var X#4)| in A#11[(var X#6)] ) ) where Delta1 = {T#14,T#3,A#10} Delta2 = {E#1} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),[.]), ((var X#6),A#11[[.]]), ((var X#7),A#20[(app A#21[[.]] T#22[(letrec {E#1} in S#2)])]), ((var X#4),[.]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(\ X#5.S#9)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(\ X#5.S#9);E#8;EE#12[X#6,A#10[(var X#7)]];VV#13|X#7,(var X#4)|} in A#11[(var X#6)])} Delta1= {A#10} Delta2= {E#1} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),[.]),((var X#6),A#11[[.]]),((var X#7),A#10[[.]]),((var X#4),[.]),((var X#6),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#18=A#20[(app A#21[(var X#7)] T#22)];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|}, A#17 |-> [.], T#14 |-> A#20[(app A#21[(var X#7)] T#22)], A#10 |-> A#20[(app A#21 T#22[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) <-gc1- (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[S#2])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#7)] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) -SR,cp-e2-> (letrec {X#18=A#20[(app A#21[(\ X#5.S#9)] T#22[(letrec {E#1} in S#2)])];X#4=(\ X#5.S#9);E#8;EE#19[X#6,(var X#18)];VV#13|X#7,(var X#4)|} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#4} in (letrec {E#5} in T#8[S#2])) , (letrec {E#4;E#5} in T#8[(letrec {E#1} in S#2)]) ) where Delta1 = {T#7,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), [{E#4},(letrec {E#5} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) and constraints: E#4/= {}, E#5/= {}, ({E#4},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in (letrec {E#5} in S#6))} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#4},(letrec {E#5} in [.])]} and found solution: Sol = {T#3 |-> (letrec {E#4} in (letrec {E#5} in T#8)), T#7 |-> (letrec {E#5} in T#8), S#6 |-> T#8[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#4} in (letrec {E#5} in T#8[(letrec {E#1} in S#2)])) <-gc1- (letrec {E#4} in (letrec {E#5} in T#8[S#2])) ................................................................................ (letrec {E#4} in (letrec {E#5} in T#8[(letrec {E#1} in S#2)])) -SR,llet-in1-> (letrec {E#4;E#5} in T#8[(letrec {E#1} in S#2)]) ================================================================================ Critical Pair: ( (letrec {E#4} in (letrec {X#9=T#8[S#2];E#11} in S#6)) , (letrec {X#9=T#8[(letrec {E#1} in S#2)];E#11;E#4} in S#6) ) where Delta1 = {T#7,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), [{E#4},(letrec {X#9=T#8[(letrec {E#1} in S#2)];E#11} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) and constraints: E#4/= {}, E#5/= {}, ({E#4},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in (letrec {E#5} in S#6))} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#4},(letrec {E#5} in [.])]} and found solution: Sol = {T#3 |-> (letrec {E#4} in (letrec {X#9=T#8;E#11} in S#6)), T#7 |-> (letrec {X#9=T#8;E#11} in S#6), E#5 |-> {X#9=T#8[(letrec {E#1} in S#2)];E#11}, E#10 |-> {E#11}} and instantiated rules: (letrec {E#4} in (letrec {X#9=T#8[(letrec {E#1} in S#2)];E#11} in S#6)) <-gc1- (letrec {E#4} in (letrec {X#9=T#8[S#2];E#11} in S#6)) ................................................................................ (letrec {E#4} in (letrec {X#9=T#8[(letrec {E#1} in S#2)];E#11} in S#6)) -SR,llet-in1-> (letrec {X#9=T#8[(letrec {E#1} in S#2)];E#11;E#4} in S#6) ================================================================================ Critical Pair: ( (letrec {E#4} in S#6) , (letrec {E#4;E#5} in S#6) ) where Delta1 = {T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#6,(letrec {E#5} in [.])), [{E#4},(letrec {E#5} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) and constraints: E#4/= {}, E#5/= {}, ({E#4},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in (letrec {E#5} in S#6))} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#4},(letrec {E#5} in [.])]} and found solution: Sol = {T#3 |-> (letrec {E#4} in [.]), T#7 |-> [.], S#2 |-> S#6, E#1 |-> {E#5}} and instantiated rules: (letrec {E#4} in (letrec {E#5} in S#6)) <-gc1- (letrec {E#4} in S#6) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) ================================================================================ Critical Pair: ( (letrec {X#8=T#7[S#2];E#10} in (letrec {E#5} in S#6)) , (letrec {X#8=T#7[(letrec {E#1} in S#2)];E#10;E#5} in S#6) ) where Delta1 = {T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), [{X#8=T#7[(letrec {E#1} in S#2)];E#10},(letrec {E#5} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) and constraints: E#4/= {}, E#5/= {}, ({E#4},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in (letrec {E#5} in S#6))} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#4},(letrec {E#5} in [.])]} and found solution: Sol = {T#3 |-> (letrec {X#8=T#7;E#10} in (letrec {E#5} in S#6)), E#4 |-> {X#8=T#7[(letrec {E#1} in S#2)];E#10}, E#9 |-> {E#10}} and instantiated rules: (letrec {X#8=T#7[(letrec {E#1} in S#2)];E#10} in (letrec {E#5} in S#6)) <-gc1- (letrec {X#8=T#7[S#2];E#10} in (letrec {E#5} in S#6)) ................................................................................ (letrec {X#8=T#7[(letrec {E#1} in S#2)];E#10} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {X#8=T#7[(letrec {E#1} in S#2)];E#10;E#5} in S#6) ================================================================================ Critical Pair: ( (letrec {E#5} in S#6) , (letrec {E#4;E#5} in S#6) ) where Delta1 = {} Delta2 = {E#1,E#4,E#5} Delta3 = {((letrec {E#5} in S#6),(letrec {E#4} in [.])), [{E#4},(letrec {E#5} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) and constraints: E#4/= {}, E#5/= {}, ({E#4},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in (letrec {E#5} in S#6))} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),[{E#4},(letrec {E#5} in [.])]} and found solution: Sol = {T#3 |-> [.], S#2 |-> (letrec {E#5} in S#6), E#1 |-> {E#4}} and instantiated rules: (letrec {E#4} in (letrec {E#5} in S#6)) <-gc1- (letrec {E#5} in S#6) ................................................................................ (letrec {E#4} in (letrec {E#5} in S#6)) -SR,llet-in1-> (letrec {E#4;E#5} in S#6) ================================================================================ Critical Pair: ( (letrec X#4= (letrec {E#5} in S#7) ;E#6 in A#10[(app A#11[(var X#4)] T#12[S#2])] ) , (letrec X#4= S#7 ;E#5 ;E#6 in A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#8,T#9,T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])],(letrec {E#5} in [.])), [{E#6},(letrec {E#5} in [.])], ((var X#4),A#10[(app A#11[[.]] T#12[(letrec {E#1} in S#2)])]), ((var X#4),A#10[(app A#11[[.]] T#12[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,llet-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) and constraints: E#5/= {}, (A#8[(var X#4)],(letrec {E#5} in [.])), ({E#6},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(A#8[(var X#4)],(letrec {E#5} in [.])),[{E#6},(letrec {E#5} in [.])],((var X#4),A#8[[.]]),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#10[(app A#11[(var X#4)] T#12)]), T#9 |-> A#10[(app A#11[(var X#4)] T#12)], A#8 |-> A#10[(app A#11 T#12[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])]) <-gc1- (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[S#2])]) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#10[(app A#11[(var X#4)] T#12[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec {X#4=(letrec {E#5} in T#12[S#2]);E#6} in A#8[(var X#4)]) , (letrec {X#4=T#12[(letrec {E#1} in S#2)];E#5;E#6} in A#8[(var X#4)]) ) where Delta1 = {T#9,T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#8[(var X#4)],(letrec {E#5} in [.])), [{E#6},(letrec {E#5} in [.])], ((var X#4),A#8[[.]]), ((var X#4),A#8[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) and constraints: E#5/= {}, (A#8[(var X#4)],(letrec {E#5} in [.])), ({E#6},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(A#8[(var X#4)],(letrec {E#5} in [.])),[{E#6},(letrec {E#5} in [.])],((var X#4),A#8[[.]]),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {E#5} in T#12);E#6} in A#8[(var X#4)]), X#10 |-> X#4, E#11 |-> {E#6}, T#9 |-> (letrec {E#5} in T#12), S#7 |-> T#12[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=(letrec {E#5} in T#12[(letrec {E#1} in S#2)]);E#6} in A#8[(var X#4)]) <-gc1- (letrec {X#4=(letrec {E#5} in T#12[S#2]);E#6} in A#8[(var X#4)]) ................................................................................ (letrec {X#4=(letrec {E#5} in T#12[(letrec {E#1} in S#2)]);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=T#12[(letrec {E#1} in S#2)];E#5;E#6} in A#8[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=(letrec {X#13=T#12[S#2];E#15} in S#7);E#6} in A#8[(var X#4)]) , (letrec {X#13=T#12[(letrec {E#1} in S#2)];X#4=S#7;E#15;E#6} in A#8[(var X#4)]) ) where Delta1 = {T#9,T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#8[(var X#4)],(letrec {X#13=T#12[(letrec {E#1} in S#2)];E#15} in [.])), [{E#6},(letrec {X#13=T#12[(letrec {E#1} in S#2)];E#15} in [.])], ((var X#4),A#8[[.]]), ((var X#4),A#8[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) and constraints: E#5/= {}, (A#8[(var X#4)],(letrec {E#5} in [.])), ({E#6},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(A#8[(var X#4)],(letrec {E#5} in [.])),[{E#6},(letrec {E#5} in [.])],((var X#4),A#8[[.]]),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {X#13=T#12;E#15} in S#7);E#6} in A#8[(var X#4)]), X#10 |-> X#4, E#11 |-> {E#6}, T#9 |-> (letrec {X#13=T#12;E#15} in S#7), E#5 |-> {X#13=T#12[(letrec {E#1} in S#2)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#4=(letrec {X#13=T#12[(letrec {E#1} in S#2)];E#15} in S#7);E#6} in A#8[(var X#4)]) <-gc1- (letrec {X#4=(letrec {X#13=T#12[S#2];E#15} in S#7);E#6} in A#8[(var X#4)]) ................................................................................ (letrec {X#4=(letrec {X#13=T#12[(letrec {E#1} in S#2)];E#15} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#13=T#12[(letrec {E#1} in S#2)];X#4=S#7;E#15;E#6} in A#8[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=S#7;E#6} in A#8[(var X#4)]) , (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) ) where Delta1 = {T#3} Delta2 = {E#1,E#5} Delta3 = {(S#7,(letrec {E#5} in [.])), (A#8[(var X#4)],(letrec {E#5} in [.])), [{E#6},(letrec {E#5} in [.])], ((var X#4),A#8[[.]]), ((var X#4),A#8[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) and constraints: E#5/= {}, (A#8[(var X#4)],(letrec {E#5} in [.])), ({E#6},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(A#8[(var X#4)],(letrec {E#5} in [.])),[{E#6},(letrec {E#5} in [.])],((var X#4),A#8[[.]]),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=[.];E#6} in A#8[(var X#4)]), X#10 |-> X#4, E#11 |-> {E#6}, T#9 |-> [.], S#2 |-> S#7, E#1 |-> {E#5}} and instantiated rules: (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) <-gc1- (letrec {X#4=S#7;E#6} in A#8[(var X#4)]) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#10=T#9[S#2];X#4=(letrec {E#5} in S#7);E#12} in A#8[(var X#4)]) , (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=S#7;E#12;E#5} in A#8[(var X#4)]) ) where Delta1 = {T#3} Delta2 = {E#1,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (A#8[(var X#4)],(letrec {E#5} in [.])), [{X#10=T#9[(letrec {E#1} in S#2)];E#12},(letrec {E#5} in [.])], ((var X#4),A#8[[.]]), ((var X#4),A#8[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#4=S#7;E#5;E#6} in A#8[(var X#4)]) and constraints: E#5/= {}, (A#8[(var X#4)],(letrec {E#5} in [.])), ({E#6},(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#5} in S#7);E#6} in A#8[(var X#4)])} Delta1= {} Delta2= {E#1,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(A#8[(var X#4)],(letrec {E#5} in [.])),[{E#6},(letrec {E#5} in [.])],((var X#4),A#8[[.]]),((var X#4),A#8[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#10=T#9;X#4=(letrec {E#5} in S#7);E#12} in A#8[(var X#4)]), E#6 |-> {X#10=T#9[(letrec {E#1} in S#2)];E#12}, E#11 |-> {X#4=(letrec {E#5} in S#7);E#12}} and instantiated rules: (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=(letrec {E#5} in S#7);E#12} in A#8[(var X#4)]) <-gc1- (letrec {X#10=T#9[S#2];X#4=(letrec {E#5} in S#7);E#12} in A#8[(var X#4)]) ................................................................................ (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=(letrec {E#5} in S#7);E#12} in A#8[(var X#4)]) -SR,llet-e1-> (letrec {X#10=T#9[(letrec {E#1} in S#2)];X#4=S#7;E#12;E#5} in A#8[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= (letrec {E#6} in S#8) ;E#7 ;EE#10[X#5,(var X#4)] in A#12[(app A#13[(var X#5)] T#14[S#2])] ) , (letrec X#4= S#8 ;E#6 ;E#7 ;EE#10[X#5,(var X#4)] in A#12[(app A#13[(var X#5)] T#14[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#9,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#12[(app A#13[(var X#5)] T#14[(letrec {E#1} in S#2)])],(letrec {E#6} in [.])), [{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])]), ((var X#4),[.]), ((var X#5),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#12[(app A#13[(var X#5)] T#14)]), T#11 |-> A#12[(app A#13[(var X#5)] T#14)], A#9 |-> A#12[(app A#13 T#14[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#12[(app A#13[(var X#5)] T#14[(letrec {E#1} in S#2)])]) <-gc1- (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#12[(app A#13[(var X#5)] T#14[S#2])]) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#12[(app A#13[(var X#5)] T#14[(letrec {E#1} in S#2)])]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#12[(app A#13[(var X#5)] T#14[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec X#4= (letrec {E#6} in T#14[S#2]) ;E#7 ;EE#10[X#5,(var X#4)] in A#9[(var X#5)] ) , (letrec X#4= T#14[(letrec {E#1} in S#2)] ;E#6 ;E#7 ;EE#10[X#5,(var X#4)] in A#9[(var X#5)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {E#6} in T#14);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]), X#12 |-> X#4, E#13 |-> {E#7;EE#10[X#5,(var X#4)]}, T#11 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=(letrec {E#6} in T#14[(letrec {E#1} in S#2)]);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) <-gc1- (letrec {X#4=(letrec {E#6} in T#14[S#2]);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#4=(letrec {E#6} in T#14[(letrec {E#1} in S#2)]);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=T#14[(letrec {E#1} in S#2)];E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#4= (letrec {X#15=T#14[S#2];E#17} in S#8) ;E#7 ;EE#10[X#5,(var X#4)] in A#9[(var X#5)] ) , (letrec X#15= T#14[(letrec {E#1} in S#2)] ;X#4= S#8 ;E#17 ;E#7 ;EE#10[X#5,(var X#4)] in A#9[(var X#5)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {X#15=T#14[(letrec {E#1} in S#2)];E#17;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {X#15=T#14[(letrec {E#1} in S#2)];E#17} in [.])), [{E#7;EE#10[X#5,(var X#4)]},(letrec {X#15=T#14[(letrec {E#1} in S#2)];E#17} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {X#15=T#14;E#17} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]), X#12 |-> X#4, E#13 |-> {E#7;EE#10[X#5,(var X#4)]}, T#11 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(letrec {E#1} in S#2)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#4=(letrec {X#15=T#14[(letrec {E#1} in S#2)];E#17} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) <-gc1- (letrec {X#4=(letrec {X#15=T#14[S#2];E#17} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#4=(letrec {X#15=T#14[(letrec {E#1} in S#2)];E#17} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#15=T#14[(letrec {E#1} in S#2)];X#4=S#8;E#17;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#4=S#8;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) , (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ) where Delta1 = {T#3} Delta2 = {E#1,E#6} Delta3 = {(S#8,(letrec {E#6} in [.])), ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=[.];E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]), X#12 |-> X#4, E#13 |-> {E#7;EE#10[X#5,(var X#4)]}, T#11 |-> [.], S#2 |-> S#8, E#1 |-> {E#6}} and instantiated rules: (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) <-gc1- (letrec {X#4=S#8;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[S#2] ;X#4= (letrec {E#6} in S#8) ;E#14 ;EE#10[X#5,(var X#4)] in A#9[(var X#5)] ) , (letrec X#12= T#11[(letrec {E#1} in S#2)] ;X#4= S#8 ;E#14 ;E#6 ;EE#10[X#5,(var X#4)] in A#9[(var X#5)] ) ) where Delta1 = {T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;E#6;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#12=T#11;X#4=(letrec {E#6} in S#8);E#14;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]), E#7 |-> {X#12=T#11[(letrec {E#1} in S#2)];E#14}, E#13 |-> {X#4=(letrec {E#6} in S#8);E#14;EE#10[X#5,(var X#4)]}} and instantiated rules: (letrec {X#12=T#11[(letrec {E#1} in S#2)];X#4=(letrec {E#6} in S#8);E#14;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) <-gc1- (letrec {X#12=T#11[S#2];X#4=(letrec {E#6} in S#8);E#14;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#12=T#11[(letrec {E#1} in S#2)];X#4=(letrec {E#6} in S#8);E#14;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#12=T#11[(letrec {E#1} in S#2)];X#4=S#8;E#14;E#6;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#4= (letrec {E#6} in S#8) ;X#5= A#15[(app A#16[(var X#4)] T#17[S#2])] ;E#7 in A#9[(var X#5)] ) , (letrec X#4= S#8 ;X#5= A#15[(app A#16[(var X#4)] T#17[(letrec {E#1} in S#2)])] ;E#6 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {X#5=A#15[(app A#16[(var X#4)] T#17[(letrec {E#1} in S#2)])];E#6;E#7} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#5=A#15[(app A#16[(var X#4)] T#17[(letrec {E#1} in S#2)])];E#7},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {E#6} in S#8);X#5=A#15[(app A#16[(var X#4)] T#17)];E#7} in A#9[(var X#5)]), EE#10[.1,.2] |-> {[.1]=A#15[(app A#16[[.2]] T#17[(letrec {E#1} in S#2)])]}, X#12 |-> X#5, E#13 |-> {X#4=(letrec {E#6} in S#8);E#7}, T#11 |-> A#15[(app A#16[(var X#4)] T#17)], A#14 |-> A#15[(app A#16 T#17[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(letrec {E#6} in S#8);X#5=A#15[(app A#16[(var X#4)] T#17[(letrec {E#1} in S#2)])];E#7} in A#9[(var X#5)]) <-gc1- (letrec {X#4=(letrec {E#6} in S#8);X#5=A#15[(app A#16[(var X#4)] T#17[S#2])];E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);X#5=A#15[(app A#16[(var X#4)] T#17[(letrec {E#1} in S#2)])];E#7} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;X#5=A#15[(app A#16[(var X#4)] T#17[(letrec {E#1} in S#2)])];E#6;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#4= (letrec {E#6} in S#8) ;X#5= A#17[(app A#18[(var X#15)] T#19[S#2])] ;E#7 ;EE#16[X#15,(var X#4)] in A#9[(var X#5)] ) , (letrec X#4= S#8 ;X#5= A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])] ;E#6 ;E#7 ;EE#16[X#15,(var X#4)] in A#9[(var X#5)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {X#5=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#6;E#7;EE#16[X#15,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#5=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#7;EE#16[X#15,(var X#4)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(letrec {E#6} in S#8);X#5=A#17[(app A#18[(var X#15)] T#19)];E#7;EE#16[X#15,(var X#4)]} in A#9[(var X#5)]), EE#10[.1,.2] |-> {[.1]=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];EE#16[X#15,[.2]]}, X#12 |-> X#5, E#13 |-> {X#4=(letrec {E#6} in S#8);E#7;EE#16[X#15,(var X#4)]}, T#11 |-> A#17[(app A#18[(var X#15)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=(letrec {E#6} in S#8);X#5=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#7;EE#16[X#15,(var X#4)]} in A#9[(var X#5)]) <-gc1- (letrec {X#4=(letrec {E#6} in S#8);X#5=A#17[(app A#18[(var X#15)] T#19[S#2])];E#7;EE#16[X#15,(var X#4)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);X#5=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#7;EE#16[X#15,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;X#5=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#6;E#7;EE#16[X#15,(var X#4)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(app A#20[(var X#16)] T#21[S#2])] ;X#4= (letrec {E#6} in S#8) ;E#7 ;EE#17[X#5,(var X#15)] ;EE#18[X#16,(var X#4)] in A#9[(var X#5)] ) , (letrec X#15= A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])] ;X#4= S#8 ;E#6 ;E#7 ;EE#17[X#5,(var X#15)] ;EE#18[X#16,(var X#4)] in A#9[(var X#5)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#6;E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#19[(app A#20[(var X#16)] T#21)];X#4=(letrec {E#6} in S#8);E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]} in A#9[(var X#5)]), EE#10[.1,.2] |-> {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];EE#17[[.1],(var X#15)];EE#18[X#16,[.2]]}, X#12 |-> X#15, E#13 |-> {X#4=(letrec {E#6} in S#8);E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]}, T#11 |-> A#19[(app A#20[(var X#16)] T#21)], A#14 |-> A#19[(app A#20 T#21[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];X#4=(letrec {E#6} in S#8);E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]} in A#9[(var X#5)]) <-gc1- (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[S#2])];X#4=(letrec {E#6} in S#8);E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];X#4=(letrec {E#6} in S#8);E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];X#4=S#8;E#6;E#7;EE#17[X#5,(var X#15)];EE#18[X#16,(var X#4)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app A#18[(var X#4)] T#19[S#2])] ;X#4= (letrec {E#6} in S#8) ;E#7 ;EE#16[X#5,(var X#15)] in A#9[(var X#5)] ) , (letrec X#15= A#17[(app A#18[(var X#4)] T#19[(letrec {E#1} in S#2)])] ;X#4= S#8 ;E#6 ;E#7 ;EE#16[X#5,(var X#15)] in A#9[(var X#5)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), ((var X#4),(letrec {X#15=A#17[(app A#18[(var X#4)] T#19[(letrec {E#1} in S#2)])];E#6;E#7;EE#16[X#5,(var X#15)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#15=A#17[(app A#18[(var X#4)] T#19[(letrec {E#1} in S#2)])];E#7;EE#16[X#5,(var X#15)]},(letrec {E#6} in [.])], ((var X#4),[.]), ((var X#5),A#9[[.]]), ((var X#4),[.]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#4=S#8;E#6;E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)]) and constraints: E#6/= {}, ((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {X#4=(letrec {E#6} in S#8);E#7;EE#10[X#5,(var X#4)]} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),((var X#4),(letrec {E#6;E#7;EE#10[X#5,(var X#4)]} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7;EE#10[X#5,(var X#4)]},(letrec {E#6} in [.])],((var X#4),[.]),((var X#5),A#9[[.]]),((var X#4),[.]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app A#18[(var X#4)] T#19)];X#4=(letrec {E#6} in S#8);E#7;EE#16[X#5,(var X#15)]} in A#9[(var X#5)]), EE#10[.1,.2] |-> {X#15=A#17[(app A#18[[.2]] T#19[(letrec {E#1} in S#2)])];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {X#4=(letrec {E#6} in S#8);E#7;EE#16[X#5,(var X#15)]}, T#11 |-> A#17[(app A#18[(var X#4)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#15=A#17[(app A#18[(var X#4)] T#19[(letrec {E#1} in S#2)])];X#4=(letrec {E#6} in S#8);E#7;EE#16[X#5,(var X#15)]} in A#9[(var X#5)]) <-gc1- (letrec {X#15=A#17[(app A#18[(var X#4)] T#19[S#2])];X#4=(letrec {E#6} in S#8);E#7;EE#16[X#5,(var X#15)]} in A#9[(var X#5)]) ................................................................................ (letrec {X#15=A#17[(app A#18[(var X#4)] T#19[(letrec {E#1} in S#2)])];X#4=(letrec {E#6} in S#8);E#7;EE#16[X#5,(var X#15)]} in A#9[(var X#5)]) -SR,llet-e2-> (letrec {X#15=A#17[(app A#18[(var X#4)] T#19[(letrec {E#1} in S#2)])];X#4=S#8;E#6;E#7;EE#16[X#5,(var X#15)]} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( A#8[(app (letrec {E#4} in T#11[S#2]) S#5)] , A#8[(letrec {E#4} in (app T#11[(letrec {E#1} in S#2)] S#5))] ) where Delta1 = {T#10,T#9,A#7,T#3,A#8} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#5,(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> A#8, T#3 |-> A#8[(app (letrec {E#4} in T#11) S#5)], T#9 |-> (app (letrec {E#4} in T#11) S#5), T#10 |-> (letrec {E#4} in T#11), S#6 |-> T#11[(letrec {E#1} in S#2)]} and instantiated rules: A#8[(app (letrec {E#4} in T#11[(letrec {E#1} in S#2)]) S#5)] <-gc1- A#8[(app (letrec {E#4} in T#11[S#2]) S#5)] ................................................................................ A#8[(app (letrec {E#4} in T#11[(letrec {E#1} in S#2)]) S#5)] -SR,lapp1-> A#8[(letrec {E#4} in (app T#11[(letrec {E#1} in S#2)] S#5))] ================================================================================ Critical Pair: ( A#8[(app (letrec {X#12=T#11[S#2];E#14} in S#6) S#5)] , A#8[(letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in (app S#6 S#5))] ) where Delta1 = {T#10,T#9,A#7,T#3,A#8} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#5,(letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> A#8, T#3 |-> A#8[(app (letrec {X#12=T#11;E#14} in S#6) S#5)], T#9 |-> (app (letrec {X#12=T#11;E#14} in S#6) S#5), T#10 |-> (letrec {X#12=T#11;E#14} in S#6), E#4 |-> {X#12=T#11[(letrec {E#1} in S#2)];E#14}, E#13 |-> {E#14}} and instantiated rules: A#8[(app (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in S#6) S#5)] <-gc1- A#8[(app (letrec {X#12=T#11[S#2];E#14} in S#6) S#5)] ................................................................................ A#8[(app (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in S#6) S#5)] -SR,lapp1-> A#8[(letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in (app S#6 S#5))] ================================================================================ Critical Pair: ( A#8[(app S#6 S#5)] , A#8[(letrec {E#4} in (app S#6 S#5))] ) where Delta1 = {T#9,A#7,T#3,A#8} Delta2 = {E#1,E#4} Delta3 = {(S#6,(letrec {E#4} in [.])), (S#5,(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> A#8, T#3 |-> A#8[(app [.] S#5)], T#9 |-> (app [.] S#5), T#10 |-> [.], S#2 |-> S#6, E#1 |-> {E#4}} and instantiated rules: A#8[(app (letrec {E#4} in S#6) S#5)] <-gc1- A#8[(app S#6 S#5)] ................................................................................ A#8[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#8[(letrec {E#4} in (app S#6 S#5))] ================================================================================ Critical Pair: ( A#8[(app (letrec {E#4} in S#6) T#10[S#2])] , A#8[(letrec {E#4} in (app S#6 T#10[(letrec {E#1} in S#2)]))] ) where Delta1 = {T#9,A#7,T#3,A#8} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#10[(letrec {E#1} in S#2)],(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> A#8, T#3 |-> A#8[(app (letrec {E#4} in S#6) T#10)], T#9 |-> (app (letrec {E#4} in S#6) T#10), S#5 |-> T#10[(letrec {E#1} in S#2)]} and instantiated rules: A#8[(app (letrec {E#4} in S#6) T#10[(letrec {E#1} in S#2)])] <-gc1- A#8[(app (letrec {E#4} in S#6) T#10[S#2])] ................................................................................ A#8[(app (letrec {E#4} in S#6) T#10[(letrec {E#1} in S#2)])] -SR,lapp1-> A#8[(letrec {E#4} in (app S#6 T#10[(letrec {E#1} in S#2)]))] ================================================================================ Critical Pair: ( A#8[(app A#9[(app (letrec {E#4} in S#6) S#5)] T#10[S#2])] , A#8[(app A#9[(letrec {E#4} in (app S#6 S#5))] T#10[(letrec {E#1} in S#2)])] ) where Delta1 = {A#7,T#3} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#5,(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {T#3 |-> A#8[(app A#9[(app (letrec {E#4} in S#6) S#5)] T#10)], A#7 |-> A#8[(app A#9 T#10[(letrec {E#1} in S#2)])]} and instantiated rules: A#8[(app A#9[(app (letrec {E#4} in S#6) S#5)] T#10[(letrec {E#1} in S#2)])] <-gc1- A#8[(app A#9[(app (letrec {E#4} in S#6) S#5)] T#10[S#2])] ................................................................................ A#8[(app A#9[(app (letrec {E#4} in S#6) S#5)] T#10[(letrec {E#1} in S#2)])] -SR,lapp1-> A#8[(app A#9[(letrec {E#4} in (app S#6 S#5))] T#10[(letrec {E#1} in S#2)])] ================================================================================ Critical Pair: ( (app (letrec {E#4} in T#9[S#2]) S#5) , (letrec {E#4} in (app T#9[(letrec {E#1} in S#2)] S#5)) ) where Delta1 = {T#8,T#3} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#5,(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> [.], T#3 |-> (app (letrec {E#4} in T#9) S#5), T#8 |-> (letrec {E#4} in T#9), S#6 |-> T#9[(letrec {E#1} in S#2)]} and instantiated rules: (app (letrec {E#4} in T#9[(letrec {E#1} in S#2)]) S#5) <-gc1- (app (letrec {E#4} in T#9[S#2]) S#5) ................................................................................ (app (letrec {E#4} in T#9[(letrec {E#1} in S#2)]) S#5) -SR,lapp1-> (letrec {E#4} in (app T#9[(letrec {E#1} in S#2)] S#5)) ================================================================================ Critical Pair: ( (app (letrec {X#10=T#9[S#2];E#12} in S#6) S#5) , (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in (app S#6 S#5)) ) where Delta1 = {T#8,T#3} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#5,(letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> [.], T#3 |-> (app (letrec {X#10=T#9;E#12} in S#6) S#5), T#8 |-> (letrec {X#10=T#9;E#12} in S#6), E#4 |-> {X#10=T#9[(letrec {E#1} in S#2)];E#12}, E#11 |-> {E#12}} and instantiated rules: (app (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in S#6) S#5) <-gc1- (app (letrec {X#10=T#9[S#2];E#12} in S#6) S#5) ................................................................................ (app (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in S#6) S#5) -SR,lapp1-> (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in (app S#6 S#5)) ================================================================================ Critical Pair: ( (app S#6 S#5) , (letrec {E#4} in (app S#6 S#5)) ) where Delta1 = {T#3} Delta2 = {E#1,E#4} Delta3 = {(S#6,(letrec {E#4} in [.])), (S#5,(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> [.], T#3 |-> (app [.] S#5), T#8 |-> [.], S#2 |-> S#6, E#1 |-> {E#4}} and instantiated rules: (app (letrec {E#4} in S#6) S#5) <-gc1- (app S#6 S#5) ................................................................................ (app (letrec {E#4} in S#6) S#5) -SR,lapp1-> (letrec {E#4} in (app S#6 S#5)) ================================================================================ Critical Pair: ( (app (letrec {E#4} in S#6) T#8[S#2]) , (letrec {E#4} in (app S#6 T#8[(letrec {E#1} in S#2)])) ) where Delta1 = {T#3} Delta2 = {E#1,E#4} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#8[(letrec {E#1} in S#2)],(letrec {E#4} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ A#7[(app (letrec {E#4} in S#6) S#5)] -SR,lapp1-> A#7[(letrec {E#4} in (app S#6 S#5))] and constraints: E#4/= {}, (S#5,(letrec {E#4} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= A#7[(app (letrec {E#4} in S#6) S#5)]} Delta1= {} Delta2= {E#1,E#4} Delta3= {(S#2,(letrec {E#1} in [.])),(S#5,(letrec {E#4} in [.]))} and found solution: Sol = {A#7 |-> [.], T#3 |-> (app (letrec {E#4} in S#6) T#8), S#5 |-> T#8[(letrec {E#1} in S#2)]} and instantiated rules: (app (letrec {E#4} in S#6) T#8[(letrec {E#1} in S#2)]) <-gc1- (app (letrec {E#4} in S#6) T#8[S#2]) ................................................................................ (app (letrec {E#4} in S#6) T#8[(letrec {E#1} in S#2)]) -SR,lapp1-> (letrec {E#4} in (app S#6 T#8[(letrec {E#1} in S#2)])) ================================================================================ Critical Pair: ( (letrec {E#4} in A#10[(app (letrec {E#5} in T#13[S#2]) S#6)]) , (letrec {E#4} in A#10[(letrec {E#5} in (app T#13[(letrec {E#1} in S#2)] S#6))]) ) where Delta1 = {T#12,T#11,A#8,T#9,T#3,A#10} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in A#10[(app (letrec {E#5} in T#13) S#6)]), A#8 |-> A#10, T#9 |-> A#10[(app (letrec {E#5} in T#13) S#6)], T#11 |-> (app (letrec {E#5} in T#13) S#6), T#12 |-> (letrec {E#5} in T#13), S#7 |-> T#13[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#4} in A#10[(app (letrec {E#5} in T#13[(letrec {E#1} in S#2)]) S#6)]) <-gc1- (letrec {E#4} in A#10[(app (letrec {E#5} in T#13[S#2]) S#6)]) ................................................................................ (letrec {E#4} in A#10[(app (letrec {E#5} in T#13[(letrec {E#1} in S#2)]) S#6)]) -SR,lapp2-> (letrec {E#4} in A#10[(letrec {E#5} in (app T#13[(letrec {E#1} in S#2)] S#6))]) ================================================================================ Critical Pair: ( (letrec {E#4} in A#10[(app (letrec {X#14=T#13[S#2];E#16} in S#7) S#6)]) , (letrec E#4 in A#10[(letrec {X#14=T#13[(letrec {E#1} in S#2)];E#16} in (app S#7 S#6))] ) ) where Delta1 = {T#12,T#11,A#8,T#9,T#3,A#10} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {X#14=T#13[(letrec {E#1} in S#2)];E#16} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in A#10[(app (letrec {X#14=T#13;E#16} in S#7) S#6)]), A#8 |-> A#10, T#9 |-> A#10[(app (letrec {X#14=T#13;E#16} in S#7) S#6)], T#11 |-> (app (letrec {X#14=T#13;E#16} in S#7) S#6), T#12 |-> (letrec {X#14=T#13;E#16} in S#7), E#5 |-> {X#14=T#13[(letrec {E#1} in S#2)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {E#4} in A#10[(app (letrec {X#14=T#13[(letrec {E#1} in S#2)];E#16} in S#7) S#6)]) <-gc1- (letrec {E#4} in A#10[(app (letrec {X#14=T#13[S#2];E#16} in S#7) S#6)]) ................................................................................ (letrec {E#4} in A#10[(app (letrec {X#14=T#13[(letrec {E#1} in S#2)];E#16} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#10[(letrec {X#14=T#13[(letrec {E#1} in S#2)];E#16} in (app S#7 S#6))]) ================================================================================ Critical Pair: ( (letrec {E#4} in A#10[(app S#7 S#6)]) , (letrec {E#4} in A#10[(letrec {E#5} in (app S#7 S#6))]) ) where Delta1 = {T#11,A#8,T#9,T#3,A#10} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#7,(letrec {E#5} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in A#10[(app [.] S#6)]), A#8 |-> A#10, T#9 |-> A#10[(app [.] S#6)], T#11 |-> (app [.] S#6), T#12 |-> [.], S#2 |-> S#7, E#1 |-> {E#5}} and instantiated rules: (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) S#6)]) <-gc1- (letrec {E#4} in A#10[(app S#7 S#6)]) ................................................................................ (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#10[(letrec {E#5} in (app S#7 S#6))]) ================================================================================ Critical Pair: ( (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) T#12[S#2])]) , (letrec {E#4} in A#10[(letrec {E#5} in (app S#7 T#12[(letrec {E#1} in S#2)]))]) ) where Delta1 = {T#11,A#8,T#9,T#3,A#10} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#12[(letrec {E#1} in S#2)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) T#12)]), A#8 |-> A#10, T#9 |-> A#10[(app (letrec {E#5} in S#7) T#12)], T#11 |-> (app (letrec {E#5} in S#7) T#12), S#6 |-> T#12[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) T#12[(letrec {E#1} in S#2)])]) <-gc1- (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) T#12[S#2])]) ................................................................................ (letrec {E#4} in A#10[(app (letrec {E#5} in S#7) T#12[(letrec {E#1} in S#2)])]) -SR,lapp2-> (letrec {E#4} in A#10[(letrec {E#5} in (app S#7 T#12[(letrec {E#1} in S#2)]))]) ================================================================================ Critical Pair: ( (letrec {E#4} in A#10[(app A#11[(app (letrec {E#5} in S#7) S#6)] T#12[S#2])]) , (letrec E#4 in A#10[(app A#11[(letrec {E#5} in (app S#7 S#6))] T#12[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#8,T#9,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in A#10[(app A#11[(app (letrec {E#5} in S#7) S#6)] T#12)]), T#9 |-> A#10[(app A#11[(app (letrec {E#5} in S#7) S#6)] T#12)], A#8 |-> A#10[(app A#11 T#12[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {E#4} in A#10[(app A#11[(app (letrec {E#5} in S#7) S#6)] T#12[(letrec {E#1} in S#2)])]) <-gc1- (letrec {E#4} in A#10[(app A#11[(app (letrec {E#5} in S#7) S#6)] T#12[S#2])]) ................................................................................ (letrec {E#4} in A#10[(app A#11[(app (letrec {E#5} in S#7) S#6)] T#12[(letrec {E#1} in S#2)])]) -SR,lapp2-> (letrec {E#4} in A#10[(app A#11[(letrec {E#5} in (app S#7 S#6))] T#12[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec {E#4} in (app (letrec {E#5} in T#11[S#2]) S#6)) , (letrec {E#4} in (letrec {E#5} in (app T#11[(letrec {E#1} in S#2)] S#6))) ) where Delta1 = {T#10,T#9,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in (app (letrec {E#5} in T#11) S#6)), A#8 |-> [.], T#9 |-> (app (letrec {E#5} in T#11) S#6), T#10 |-> (letrec {E#5} in T#11), S#7 |-> T#11[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#4} in (app (letrec {E#5} in T#11[(letrec {E#1} in S#2)]) S#6)) <-gc1- (letrec {E#4} in (app (letrec {E#5} in T#11[S#2]) S#6)) ................................................................................ (letrec {E#4} in (app (letrec {E#5} in T#11[(letrec {E#1} in S#2)]) S#6)) -SR,lapp2-> (letrec {E#4} in (letrec {E#5} in (app T#11[(letrec {E#1} in S#2)] S#6))) ================================================================================ Critical Pair: ( (letrec {E#4} in (app (letrec {X#12=T#11[S#2];E#14} in S#7) S#6)) , (letrec E#4 in (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in (app S#7 S#6)) ) ) where Delta1 = {T#10,T#9,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in (app (letrec {X#12=T#11;E#14} in S#7) S#6)), A#8 |-> [.], T#9 |-> (app (letrec {X#12=T#11;E#14} in S#7) S#6), T#10 |-> (letrec {X#12=T#11;E#14} in S#7), E#5 |-> {X#12=T#11[(letrec {E#1} in S#2)];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {E#4} in (app (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in S#7) S#6)) <-gc1- (letrec {E#4} in (app (letrec {X#12=T#11[S#2];E#14} in S#7) S#6)) ................................................................................ (letrec {E#4} in (app (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in S#7) S#6)) -SR,lapp2-> (letrec {E#4} in (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14} in (app S#7 S#6))) ================================================================================ Critical Pair: ( (letrec {E#4} in (app S#7 S#6)) , (letrec {E#4} in (letrec {E#5} in (app S#7 S#6))) ) where Delta1 = {T#9,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#7,(letrec {E#5} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in (app [.] S#6)), A#8 |-> [.], T#9 |-> (app [.] S#6), T#10 |-> [.], S#2 |-> S#7, E#1 |-> {E#5}} and instantiated rules: (letrec {E#4} in (app (letrec {E#5} in S#7) S#6)) <-gc1- (letrec {E#4} in (app S#7 S#6)) ................................................................................ (letrec {E#4} in (app (letrec {E#5} in S#7) S#6)) -SR,lapp2-> (letrec {E#4} in (letrec {E#5} in (app S#7 S#6))) ================================================================================ Critical Pair: ( (letrec {E#4} in (app (letrec {E#5} in S#7) T#10[S#2])) , (letrec {E#4} in (letrec {E#5} in (app S#7 T#10[(letrec {E#1} in S#2)]))) ) where Delta1 = {T#9,T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#10[(letrec {E#1} in S#2)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {E#4} in (app (letrec {E#5} in S#7) T#10)), A#8 |-> [.], T#9 |-> (app (letrec {E#5} in S#7) T#10), S#6 |-> T#10[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {E#4} in (app (letrec {E#5} in S#7) T#10[(letrec {E#1} in S#2)])) <-gc1- (letrec {E#4} in (app (letrec {E#5} in S#7) T#10[S#2])) ................................................................................ (letrec {E#4} in (app (letrec {E#5} in S#7) T#10[(letrec {E#1} in S#2)])) -SR,lapp2-> (letrec {E#4} in (letrec {E#5} in (app S#7 T#10[(letrec {E#1} in S#2)]))) ================================================================================ Critical Pair: ( (letrec {X#10=T#9[S#2];E#12} in A#8[(app (letrec {E#5} in S#7) S#6)]) , (letrec X#10= T#9[(letrec {E#1} in S#2)] ;E#12 in A#8[(letrec {E#5} in (app S#7 S#6))] ) ) where Delta1 = {T#3} Delta2 = {E#1,E#4,E#5} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> (letrec {X#10=T#9;E#12} in A#8[(app (letrec {E#5} in S#7) S#6)]), E#4 |-> {X#10=T#9[(letrec {E#1} in S#2)];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in A#8[(app (letrec {E#5} in S#7) S#6)]) <-gc1- (letrec {X#10=T#9[S#2];E#12} in A#8[(app (letrec {E#5} in S#7) S#6)]) ................................................................................ (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {X#10=T#9[(letrec {E#1} in S#2)];E#12} in A#8[(letrec {E#5} in (app S#7 S#6))]) ================================================================================ Critical Pair: ( A#8[(app (letrec {E#5} in S#7) S#6)] , (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) ) where Delta1 = {} Delta2 = {E#1,E#4,E#5} Delta3 = {(A#8[(app (letrec {E#5} in S#7) S#6)],(letrec {E#4} in [.])), (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) and constraints: E#4/= {}, E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)])} Delta1= {} Delta2= {E#1,E#4,E#5} Delta3= {(S#2,(letrec {E#1} in [.])),(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#3 |-> [.], S#2 |-> A#8[(app (letrec {E#5} in S#7) S#6)], E#1 |-> {E#4}} and instantiated rules: (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) <-gc1- A#8[(app (letrec {E#5} in S#7) S#6)] ................................................................................ (letrec {E#4} in A#8[(app (letrec {E#5} in S#7) S#6)]) -SR,lapp2-> (letrec {E#4} in A#8[(letrec {E#5} in (app S#7 S#6))]) ================================================================================ Critical Pair: ( (letrec E#5 ;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)] in A#12[(app A#13[(var X#4)] T#14[S#2])] ) , (letrec E#5 ;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))] in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])] ) ) where Delta1 = {A#9,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])]), ((var X#4),A#12[(app A#13[[.]] T#14[(letrec {E#1} in S#2)])])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14)]), T#11 |-> A#12[(app A#13[(var X#4)] T#14)], A#9 |-> A#12[(app A#13 T#14[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])]) <-gc1- (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14[S#2])]) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#12[(app A#13[(var X#4)] T#14[(letrec {E#1} in S#2)])]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[S#2] ;E#14 ;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)] in A#9[(var X#4)] ) , (letrec X#12= T#11[(letrec {E#1} in S#2)] ;E#14 ;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))] in A#9[(var X#4)] ) ) where Delta1 = {T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#12=T#11;E#14;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]), E#5 |-> {X#12=T#11[(letrec {E#1} in S#2)];E#14}, E#13 |-> {E#14;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]}} and instantiated rules: (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) <-gc1- (letrec {X#12=T#11[S#2];E#14;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#12=T#11[(letrec {E#1} in S#2)];E#14;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=A#15[(app (letrec {E#6} in T#18[S#2]) S#7)];E#5} in A#9[(var X#4)]) , (letrec X#4= A#15[(letrec {E#6} in (app T#18[(letrec {E#1} in S#2)] S#7))] ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {T#17,T#16,A#14,T#11,T#3,A#15} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app (letrec {E#6} in T#18) S#7)];E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[[.2]]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> A#15, T#11 |-> A#15[(app (letrec {E#6} in T#18) S#7)], T#16 |-> (app (letrec {E#6} in T#18) S#7), T#17 |-> (letrec {E#6} in T#18), S#8 |-> T#18[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=A#15[(app (letrec {E#6} in T#18[(letrec {E#1} in S#2)]) S#7)];E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app (letrec {E#6} in T#18[S#2]) S#7)];E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app (letrec {E#6} in T#18[(letrec {E#1} in S#2)]) S#7)];E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=A#15[(letrec {E#6} in (app T#18[(letrec {E#1} in S#2)] S#7))];E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= A#15[(app (letrec {X#19=T#18[S#2];E#21} in S#8) S#7)] ;E#5 in A#9[(var X#4)] ) , (letrec X#4= A#15[(letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in (app S#8 S#7))] ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {T#17,T#16,A#14,T#11,T#3,A#15} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app (letrec {X#19=T#18;E#21} in S#8) S#7)];E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[[.2]]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> A#15, T#11 |-> A#15[(app (letrec {X#19=T#18;E#21} in S#8) S#7)], T#16 |-> (app (letrec {X#19=T#18;E#21} in S#8) S#7), T#17 |-> (letrec {X#19=T#18;E#21} in S#8), E#6 |-> {X#19=T#18[(letrec {E#1} in S#2)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#4=A#15[(app (letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in S#8) S#7)];E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app (letrec {X#19=T#18[S#2];E#21} in S#8) S#7)];E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app (letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in S#8) S#7)];E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=A#15[(letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in (app S#8 S#7))];E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=A#15[(app S#8 S#7)];E#5} in A#9[(var X#4)]) , (letrec {X#4=A#15[(letrec {E#6} in (app S#8 S#7))];E#5} in A#9[(var X#4)]) ) where Delta1 = {T#16,A#14,T#11,T#3,A#15} Delta2 = {E#1,E#6} Delta3 = {(S#8,(letrec {E#6} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app [.] S#7)];E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[[.2]]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> A#15, T#11 |-> A#15[(app [.] S#7)], T#16 |-> (app [.] S#7), T#17 |-> [.], S#2 |-> S#8, E#1 |-> {E#6}} and instantiated rules: (letrec {X#4=A#15[(app (letrec {E#6} in S#8) S#7)];E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app S#8 S#7)];E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app (letrec {E#6} in S#8) S#7)];E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=A#15[(letrec {E#6} in (app S#8 S#7))];E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=A#15[(app (letrec {E#6} in S#8) T#17[S#2])];E#5} in A#9[(var X#4)]) , (letrec X#4= A#15[(letrec {E#6} in (app S#8 T#17[(letrec {E#1} in S#2)]))] ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {T#16,A#14,T#11,T#3,A#15} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#17[(letrec {E#1} in S#2)],(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app (letrec {E#6} in S#8) T#17)];E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[[.2]]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> A#15, T#11 |-> A#15[(app (letrec {E#6} in S#8) T#17)], T#16 |-> (app (letrec {E#6} in S#8) T#17), S#7 |-> T#17[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=A#15[(app (letrec {E#6} in S#8) T#17[(letrec {E#1} in S#2)])];E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app (letrec {E#6} in S#8) T#17[S#2])];E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app (letrec {E#6} in S#8) T#17[(letrec {E#1} in S#2)])];E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=A#15[(letrec {E#6} in (app S#8 T#17[(letrec {E#1} in S#2)]))];E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= A#15[(app A#16[(app (letrec {E#6} in S#8) S#7)] T#17[S#2])] ;E#5 in A#9[(var X#4)] ) , (letrec X#4= A#15[(app A#16[(letrec {E#6} in (app S#8 S#7))] T#17[(letrec {E#1} in S#2)])] ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#15[(app A#16[(app (letrec {E#6} in S#8) S#7)] T#17)];E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#15[(app A#16[[.2]] T#17[(letrec {E#1} in S#2)])]}, X#12 |-> X#4, E#13 |-> {E#5}, T#11 |-> A#15[(app A#16[(app (letrec {E#6} in S#8) S#7)] T#17)], A#14 |-> A#15[(app A#16 T#17[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=A#15[(app A#16[(app (letrec {E#6} in S#8) S#7)] T#17[(letrec {E#1} in S#2)])];E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#15[(app A#16[(app (letrec {E#6} in S#8) S#7)] T#17[S#2])];E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#15[(app A#16[(app (letrec {E#6} in S#8) S#7)] T#17[(letrec {E#1} in S#2)])];E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=A#15[(app A#16[(letrec {E#6} in (app S#8 S#7))] T#17[(letrec {E#1} in S#2)])];E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=(app (letrec {E#6} in T#16[S#2]) S#7);E#5} in A#9[(var X#4)]) , (letrec X#4= (letrec {E#6} in (app T#16[(letrec {E#1} in S#2)] S#7)) ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {T#15,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(app (letrec {E#6} in T#16) S#7);E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=[.2]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> [.], T#11 |-> (app (letrec {E#6} in T#16) S#7), T#15 |-> (letrec {E#6} in T#16), S#8 |-> T#16[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=(app (letrec {E#6} in T#16[(letrec {E#1} in S#2)]) S#7);E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=(app (letrec {E#6} in T#16[S#2]) S#7);E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=(app (letrec {E#6} in T#16[(letrec {E#1} in S#2)]) S#7);E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=(letrec {E#6} in (app T#16[(letrec {E#1} in S#2)] S#7));E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= (app (letrec {X#17=T#16[S#2];E#19} in S#8) S#7) ;E#5 in A#9[(var X#4)] ) , (letrec X#4= (letrec {X#17=T#16[(letrec {E#1} in S#2)];E#19} in (app S#8 S#7)) ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {T#15,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {X#17=T#16[(letrec {E#1} in S#2)];E#19} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(app (letrec {X#17=T#16;E#19} in S#8) S#7);E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=[.2]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> [.], T#11 |-> (app (letrec {X#17=T#16;E#19} in S#8) S#7), T#15 |-> (letrec {X#17=T#16;E#19} in S#8), E#6 |-> {X#17=T#16[(letrec {E#1} in S#2)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#4=(app (letrec {X#17=T#16[(letrec {E#1} in S#2)];E#19} in S#8) S#7);E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=(app (letrec {X#17=T#16[S#2];E#19} in S#8) S#7);E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=(app (letrec {X#17=T#16[(letrec {E#1} in S#2)];E#19} in S#8) S#7);E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=(letrec {X#17=T#16[(letrec {E#1} in S#2)];E#19} in (app S#8 S#7));E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=(app S#8 S#7);E#5} in A#9[(var X#4)]) , (letrec {X#4=(letrec {E#6} in (app S#8 S#7));E#5} in A#9[(var X#4)]) ) where Delta1 = {T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#8,(letrec {E#6} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(app [.] S#7);E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=[.2]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> [.], T#11 |-> (app [.] S#7), T#15 |-> [.], S#2 |-> S#8, E#1 |-> {E#6}} and instantiated rules: (letrec {X#4=(app (letrec {E#6} in S#8) S#7);E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=(app S#8 S#7);E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=(app (letrec {E#6} in S#8) S#7);E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=(letrec {E#6} in (app S#8 S#7));E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#4=(app (letrec {E#6} in S#8) T#15[S#2]);E#5} in A#9[(var X#4)]) , (letrec X#4= (letrec {E#6} in (app S#8 T#15[(letrec {E#1} in S#2)])) ;E#5 in A#9[(var X#4)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#15[(letrec {E#1} in S#2)],(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=(app (letrec {E#6} in S#8) T#15);E#5} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=[.2]}, X#12 |-> X#4, E#13 |-> {E#5}, A#14 |-> [.], T#11 |-> (app (letrec {E#6} in S#8) T#15), S#7 |-> T#15[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#4=(app (letrec {E#6} in S#8) T#15[(letrec {E#1} in S#2)]);E#5} in A#9[(var X#4)]) <-gc1- (letrec {X#4=(app (letrec {E#6} in S#8) T#15[S#2]);E#5} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=(app (letrec {E#6} in S#8) T#15[(letrec {E#1} in S#2)]);E#5} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=(letrec {E#6} in (app S#8 T#15[(letrec {E#1} in S#2)]));E#5} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#4= A#17[(app A#18[(var X#15)] T#19[S#2])] ;E#5 ;EE#16[X#15,(app (letrec {E#6} in S#8) S#7)] in A#9[(var X#4)] ) , (letrec X#4= A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])] ;E#5 ;EE#16[X#15,(letrec {E#6} in (app S#8 S#7))] in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#4=A#17[(app A#18[(var X#15)] T#19)];E#5;EE#16[X#15,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {[.1]=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];EE#16[X#15,[.2]]}, X#12 |-> X#4, E#13 |-> {E#5;EE#16[X#15,(app (letrec {E#6} in S#8) S#7)]}, T#11 |-> A#17[(app A#18[(var X#15)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#15,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) <-gc1- (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[S#2])];E#5;EE#16[X#15,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#15,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#4=A#17[(app A#18[(var X#15)] T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#15,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#19[(app A#20[(var X#16)] T#21[S#2])] ;E#5 ;EE#17[X#4,(var X#15)] ;EE#18[X#16,(app (letrec {E#6} in S#8) S#7)] in A#9[(var X#4)] ) , (letrec X#15= A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])] ;E#5 ;EE#17[X#4,(var X#15)] ;EE#18[X#16,(letrec {E#6} in (app S#8 S#7))] in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#19[(app A#20[(var X#16)] T#21)];E#5;EE#17[X#4,(var X#15)];EE#18[X#16,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];EE#17[[.1],(var X#15)];EE#18[X#16,[.2]]}, X#12 |-> X#15, E#13 |-> {E#5;EE#17[X#4,(var X#15)];EE#18[X#16,(app (letrec {E#6} in S#8) S#7)]}, T#11 |-> A#19[(app A#20[(var X#16)] T#21)], A#14 |-> A#19[(app A#20 T#21[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#5;EE#17[X#4,(var X#15)];EE#18[X#16,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[S#2])];E#5;EE#17[X#4,(var X#15)];EE#18[X#16,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#5;EE#17[X#4,(var X#15)];EE#18[X#16,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=A#19[(app A#20[(var X#16)] T#21[(letrec {E#1} in S#2)])];E#5;EE#17[X#4,(var X#15)];EE#18[X#16,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app (letrec {E#6} in T#20[S#2]) S#7)] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= A#17[(letrec {E#6} in (app T#20[(letrec {E#1} in S#2)] S#7))] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#19,T#18,A#14,T#11,T#3,A#17} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app (letrec {E#6} in T#20) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[[.2]];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> A#17, T#11 |-> A#17[(app (letrec {E#6} in T#20) S#7)], T#18 |-> (app (letrec {E#6} in T#20) S#7), T#19 |-> (letrec {E#6} in T#20), S#8 |-> T#20[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#15=A#17[(app (letrec {E#6} in T#20[(letrec {E#1} in S#2)]) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app (letrec {E#6} in T#20[S#2]) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app (letrec {E#6} in T#20[(letrec {E#1} in S#2)]) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=A#17[(letrec {E#6} in (app T#20[(letrec {E#1} in S#2)] S#7))];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app (letrec {X#21=T#20[S#2];E#23} in S#8) S#7)] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= A#17[(letrec {X#21=T#20[(letrec {E#1} in S#2)];E#23} in (app S#8 S#7))] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#19,T#18,A#14,T#11,T#3,A#17} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {X#21=T#20[(letrec {E#1} in S#2)];E#23} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app (letrec {X#21=T#20;E#23} in S#8) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[[.2]];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> A#17, T#11 |-> A#17[(app (letrec {X#21=T#20;E#23} in S#8) S#7)], T#18 |-> (app (letrec {X#21=T#20;E#23} in S#8) S#7), T#19 |-> (letrec {X#21=T#20;E#23} in S#8), E#6 |-> {X#21=T#20[(letrec {E#1} in S#2)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#15=A#17[(app (letrec {X#21=T#20[(letrec {E#1} in S#2)];E#23} in S#8) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app (letrec {X#21=T#20[S#2];E#23} in S#8) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app (letrec {X#21=T#20[(letrec {E#1} in S#2)];E#23} in S#8) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=A#17[(letrec {X#21=T#20[(letrec {E#1} in S#2)];E#23} in (app S#8 S#7))];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#15=A#17[(app S#8 S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) , (letrec X#15= A#17[(letrec {E#6} in (app S#8 S#7))] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#18,A#14,T#11,T#3,A#17} Delta2 = {E#1,E#6} Delta3 = {(S#8,(letrec {E#6} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app [.] S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[[.2]];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> A#17, T#11 |-> A#17[(app [.] S#7)], T#18 |-> (app [.] S#7), T#19 |-> [.], S#2 |-> S#8, E#1 |-> {E#6}} and instantiated rules: (letrec {X#15=A#17[(app (letrec {E#6} in S#8) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app S#8 S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app (letrec {E#6} in S#8) S#7)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=A#17[(letrec {E#6} in (app S#8 S#7))];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app (letrec {E#6} in S#8) T#19[S#2])] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= A#17[(letrec {E#6} in (app S#8 T#19[(letrec {E#1} in S#2)]))] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#18,A#14,T#11,T#3,A#17} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#19[(letrec {E#1} in S#2)],(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app (letrec {E#6} in S#8) T#19)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[[.2]];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> A#17, T#11 |-> A#17[(app (letrec {E#6} in S#8) T#19)], T#18 |-> (app (letrec {E#6} in S#8) T#19), S#7 |-> T#19[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#15=A#17[(app (letrec {E#6} in S#8) T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app (letrec {E#6} in S#8) T#19[S#2])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app (letrec {E#6} in S#8) T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=A#17[(letrec {E#6} in (app S#8 T#19[(letrec {E#1} in S#2)]))];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= A#17[(app A#18[(app (letrec {E#6} in S#8) S#7)] T#19[S#2])] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= A#17[(app A#18[(letrec {E#6} in (app S#8 S#7))] T#19[(letrec {E#1} in S#2)])] ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {A#14,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=A#17[(app A#18[(app (letrec {E#6} in S#8) S#7)] T#19)];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=A#17[(app A#18[[.2]] T#19[(letrec {E#1} in S#2)])];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, T#11 |-> A#17[(app A#18[(app (letrec {E#6} in S#8) S#7)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {E#1} in S#2)])]} and instantiated rules: (letrec {X#15=A#17[(app A#18[(app (letrec {E#6} in S#8) S#7)] T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=A#17[(app A#18[(app (letrec {E#6} in S#8) S#7)] T#19[S#2])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=A#17[(app A#18[(app (letrec {E#6} in S#8) S#7)] T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=A#17[(app A#18[(letrec {E#6} in (app S#8 S#7))] T#19[(letrec {E#1} in S#2)])];E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= (app (letrec {E#6} in T#18[S#2]) S#7) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= (letrec {E#6} in (app T#18[(letrec {E#1} in S#2)] S#7)) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#17,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=(app (letrec {E#6} in T#18) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=[.2];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> [.], T#11 |-> (app (letrec {E#6} in T#18) S#7), T#17 |-> (letrec {E#6} in T#18), S#8 |-> T#18[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#15=(app (letrec {E#6} in T#18[(letrec {E#1} in S#2)]) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=(app (letrec {E#6} in T#18[S#2]) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=(app (letrec {E#6} in T#18[(letrec {E#1} in S#2)]) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=(letrec {E#6} in (app T#18[(letrec {E#1} in S#2)] S#7));E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= (app (letrec {X#19=T#18[S#2];E#21} in S#8) S#7) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= (letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in (app S#8 S#7)) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#17,T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (S#7,(letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=(app (letrec {X#19=T#18;E#21} in S#8) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=[.2];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> [.], T#11 |-> (app (letrec {X#19=T#18;E#21} in S#8) S#7), T#17 |-> (letrec {X#19=T#18;E#21} in S#8), E#6 |-> {X#19=T#18[(letrec {E#1} in S#2)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#15=(app (letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in S#8) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=(app (letrec {X#19=T#18[S#2];E#21} in S#8) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=(app (letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in S#8) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=(letrec {X#19=T#18[(letrec {E#1} in S#2)];E#21} in (app S#8 S#7));E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec {X#15=(app S#8 S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) , (letrec X#15= (letrec {E#6} in (app S#8 S#7)) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#8,(letrec {E#6} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=(app [.] S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=[.2];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> [.], T#11 |-> (app [.] S#7), T#17 |-> [.], S#2 |-> S#8, E#1 |-> {E#6}} and instantiated rules: (letrec {X#15=(app (letrec {E#6} in S#8) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=(app S#8 S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=(app (letrec {E#6} in S#8) S#7);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=(letrec {E#6} in (app S#8 S#7));E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( (letrec X#15= (app (letrec {E#6} in S#8) T#17[S#2]) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) , (letrec X#15= (letrec {E#6} in (app S#8 T#17[(letrec {E#1} in S#2)])) ;E#5 ;EE#16[X#4,(var X#15)] in A#9[(var X#4)] ) ) where Delta1 = {T#11,T#3} Delta2 = {E#1,E#6} Delta3 = {(S#2,(letrec {E#1} in [.])), (T#17[(letrec {E#1} in S#2)],(letrec {E#6} in [.])), ((var X#4),A#9[[.]]), ((var X#4),A#9[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc1-> with input rules: T#3[(letrec {E#1} in S#2)] <-gc1- T#3[S#2] and constraints: E#1/= {}, (S#2,(letrec {E#1} in [.])) ................................................................................ (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {E#5;EE#10[X#4,(letrec {E#6} in (app S#8 S#7))]} in A#9[(var X#4)]) and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {E#1} in S#2)] =?= (letrec {E#5;EE#10[X#4,(app (letrec {E#6} in S#8) S#7)]} in A#9[(var X#4)])} Delta1= {} Delta2= {E#1,E#6} Delta3= {(S#2,(letrec {E#1} in [.])),(S#7,(letrec {E#6} in [.])),((var X#4),A#9[[.]]),((var X#4),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#15=(app (letrec {E#6} in S#8) T#17);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]), EE#10[.1,.2] |-> {X#15=[.2];EE#16[[.1],(var X#15)]}, X#12 |-> X#15, E#13 |-> {E#5;EE#16[X#4,(var X#15)]}, A#14 |-> [.], T#11 |-> (app (letrec {E#6} in S#8) T#17), S#7 |-> T#17[(letrec {E#1} in S#2)]} and instantiated rules: (letrec {X#15=(app (letrec {E#6} in S#8) T#17[(letrec {E#1} in S#2)]);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) <-gc1- (letrec {X#15=(app (letrec {E#6} in S#8) T#17[S#2]);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ................................................................................ (letrec {X#15=(app (letrec {E#6} in S#8) T#17[(letrec {E#1} in S#2)]);E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) -SR,lapp3-> (letrec {X#15=(letrec {E#6} in (app S#8 T#17[(letrec {E#1} in S#2)]));E#5;EE#16[X#4,(var X#15)]} in A#9[(var X#4)]) ================================================================================ Critical Pair: ( A#9[(app (\ X#5.S#7) T#11[(letrec {E#1} in S#3)])] , A#9[(letrec {X#5=T#11[(letrec {E#1;E#2} in S#3)]} in S#7)] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1;E#2} in S#3)],(\ X#5.[.])), (T#11[(letrec {E#1;E#2} in S#3)],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (\ X#5.S#7) T#11)], T#10 |-> (app (\ X#5.S#7) T#11), S#6 |-> T#11[(letrec {E#1;E#2} in S#3)]} and instantiated rules: A#9[(app (\ X#5.S#7) T#11[(letrec {E#1;E#2} in S#3)])] <-gc2- A#9[(app (\ X#5.S#7) T#11[(letrec {E#1} in S#3)])] ................................................................................ A#9[(app (\ X#5.S#7) T#11[(letrec {E#1;E#2} in S#3)])] -SR,lbeta1-> A#9[(letrec {X#5=T#11[(letrec {E#1;E#2} in S#3)]} in S#7)] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1} in S#3)])] , A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(letrec {E#1;E#2} in S#3)])] ) where Delta1 = {A#8,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] <-gc2- A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1} in S#3)])] ................................................................................ A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] -SR,lbeta1-> A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(letrec {E#1;E#2} in S#3)])] ================================================================================ Critical Pair: ( (app (\ X#5.S#7) T#9[(letrec {E#1} in S#3)]) , (letrec {X#5=T#9[(letrec {E#1;E#2} in S#3)]} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#9[(letrec {E#1;E#2} in S#3)],(\ X#5.[.])), (T#9[(letrec {E#1;E#2} in S#3)],(letrec {X#5=[.]} in S#7))} Delta4= {} from overlapping <-SR,lbeta1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (\ X#5.S#7) T#9), S#6 |-> T#9[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (app (\ X#5.S#7) T#9[(letrec {E#1;E#2} in S#3)]) <-gc2- (app (\ X#5.S#7) T#9[(letrec {E#1} in S#3)]) ................................................................................ (app (\ X#5.S#7) T#9[(letrec {E#1;E#2} in S#3)]) -SR,lbeta1-> (letrec {X#5=T#9[(letrec {E#1;E#2} in S#3)]} in S#7) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1} in S#3)])]) , (letrec {E#6} in A#11[(letrec {X#5=T#13[(letrec {E#1;E#2} in S#3)]} in S#8)]) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#13[(letrec {E#1;E#2} in S#3)],(\ X#5.[.])), (T#13[(letrec {E#1;E#2} in S#3)],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (\ X#5.S#8) T#13)], T#12 |-> (app (\ X#5.S#8) T#13), S#7 |-> T#13[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {E#1;E#2} in S#3)])]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#5=T#13[(letrec {E#1;E#2} in S#3)]} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#6 in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1} in S#3)])] ) , (letrec E#6 in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])]) -SR,lbeta2-> (letrec {E#6} in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1} in S#3)])) , (letrec {E#6} in (letrec {X#5=T#11[(letrec {E#1;E#2} in S#3)]} in S#8)) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1;E#2} in S#3)],(\ X#5.[.])), (T#11[(letrec {E#1;E#2} in S#3)],(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (\ X#5.S#8) T#11)), A#9 |-> [.], T#10 |-> (app (\ X#5.S#8) T#11), S#7 |-> T#11[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1;E#2} in S#3)])) <-gc2- (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1} in S#3)])) ................................................................................ (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {E#1;E#2} in S#3)])) -SR,lbeta2-> (letrec {E#6} in (letrec {X#5=T#11[(letrec {E#1;E#2} in S#3)]} in S#8)) ================================================================================ Critical Pair: ( (letrec {X#11=T#10[(letrec {E#1} in S#3)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) , (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;E#13 in A#9[(letrec {X#5=S#7} in S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (\ X#5.S#8) S#7)]), E#6 |-> {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) <-gc2- (letrec {X#11=T#10[(letrec {E#1} in S#3)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( (letrec {E#1} in A#9[(app (\ X#5.S#8) S#7)]) , (letrec {E#1;E#2} in A#9[(letrec {X#5=S#7} in S#8)]) ) where Delta1 = {} Delta2 = {E#1,E#2,E#6} Delta3 = {(A#9[(app (\ X#5.S#8) S#7)],(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8))} Delta4= {} from overlapping <-SR,lbeta2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8))} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#9[(app (\ X#5.S#8) S#7)], E#6 |-> {E#1;E#2}} and instantiated rules: (letrec {E#1;E#2} in A#9[(app (\ X#5.S#8) S#7)]) <-gc2- (letrec {E#1} in A#9[(app (\ X#5.S#8) S#7)]) ................................................................................ (letrec {E#1;E#2} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#1;E#2} in A#9[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in S#3)])] ) , (letrec E#7 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in S#3)] ;E#15 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;E#15 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), E#7 |-> {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-gc2- (letrec {X#13=T#12[(letrec {E#1} in S#3)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (\ X#6.S#9) T#18[(letrec {E#1} in S#3)])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#6=T#18[(letrec {E#1;E#2} in S#3)]} in S#9)] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1;E#2} in S#3)],(\ X#6.[.])), (T#18[(letrec {E#1;E#2} in S#3)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (\ X#6.S#9) T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16, T#12 |-> A#16[(app (\ X#6.S#9) T#18)], T#17 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1} in S#3)])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#6=T#18[(letrec {E#1;E#2} in S#3)]} in S#9)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1} in S#3)])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(letrec {E#1;E#2} in S#3)])] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1;E#2} in S#3)])]}, X#13 |-> X#5, E#14 |-> {E#7}, T#12 |-> A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1} in S#3)])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(letrec {E#1;E#2} in S#3)])];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (\ X#6.S#9) T#16[(letrec {E#1} in S#3)]) ;E#7 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#6=T#16[(letrec {E#1;E#2} in S#3)]} in S#9) ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#16[(letrec {E#1;E#2} in S#3)],(\ X#6.[.])), (T#16[(letrec {E#1;E#2} in S#3)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (\ X#6.S#9) T#16);E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#16), S#8 |-> T#16[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1;E#2} in S#3)]);E#7} in A#10[(var X#5)]) <-gc2- (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1} in S#3)]);E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {E#1;E#2} in S#3)]);E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=(letrec {X#6=T#16[(letrec {E#1;E#2} in S#3)]} in S#9);E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#3)])] ;E#7 ;EE#17[X#16,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#17[X#16,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#3)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#16,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#3)])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#3)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (\ X#6.S#9) T#20[(letrec {E#1} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#6=T#20[(letrec {E#1;E#2} in S#3)]} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#20[(letrec {E#1;E#2} in S#3)],(\ X#6.[.])), (T#20[(letrec {E#1;E#2} in S#3)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (\ X#6.S#9) T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (\ X#6.S#9) T#20)], T#19 |-> (app (\ X#6.S#9) T#20), S#8 |-> T#20[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#6=T#20[(letrec {E#1;E#2} in S#3)]} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1;E#2} in S#3)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (\ X#6.S#9) T#18[(letrec {E#1} in S#3)]) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#6=T#18[(letrec {E#1;E#2} in S#3)]} in S#9) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1;E#2} in S#3)],(\ X#6.[.])), (T#18[(letrec {E#1;E#2} in S#3)],(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (\ X#6.S#9) T#18);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1} in S#3)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {E#1;E#2} in S#3)]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=(letrec {X#6=T#18[(letrec {E#1;E#2} in S#3)]} in S#9);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {E#14;E#15} in A#10[(var X#5)]) , (letrec {E#13;E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ) where Delta1 = {} Delta2 = {E#1,E#2,E#13,E#14} Delta3 = {(A#10[(var X#5)],(letrec {E#12;E#13} in [.])), [{E#14;E#15},(letrec {E#12;E#13} in [.])], (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= { {E#12;E#14} =?= {EE#11[X#5,(app (\ X#6.S#9) S#8)]}} from overlapping <-SR,lbeta3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#10[(var X#5)], E#7 |-> {E#13;E#15}, E#1 |-> {E#14;E#15}, E#2 |-> {E#12;E#13}} and instantiated rules: (letrec {E#12;E#13;E#14;E#15} in A#10[(var X#5)]) <-gc2- (letrec {E#14;E#15} in A#10[(var X#5)]) ................................................................................ (letrec {E#13;E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#13;E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ............................ Delta4: {E#12;E#14} =?= {EE#11[X#5,(app (\ X#6.S#9) S#8)]} ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in S#3)])] ) , (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(\ X#6.S#8)] T#13[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,cp-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(\ X#6.S#8)] T#13[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in S#3)] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(\ X#6.S#8)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13}, E#12 |-> {X#5=(\ X#6.S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) <-gc2- (letrec {X#11=T#10[(letrec {E#1} in S#3)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#8);E#13} in A#9[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( (letrec {X#5=(\ X#6.S#8);E#10} in A#9[(var X#5)]) , (letrec {X#5=(\ X#6.S#8);E#10;E#2} in A#9[(\ X#6.S#8)]) ) where Delta1 = {} Delta2 = {E#1,E#2} Delta3 = {(A#9[(var X#5)],(letrec {E#2} in [.])), [{X#5=(\ X#6.S#8);E#10},(letrec {E#2} in [.])], ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#9[(var X#5)], E#1 |-> {X#5=(\ X#6.S#8);E#10}, E#7 |-> {E#10;E#2}} and instantiated rules: (letrec {X#5=(\ X#6.S#8);E#10;E#2} in A#9[(var X#5)]) <-gc2- (letrec {X#5=(\ X#6.S#8);E#10} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#10;E#2} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#10;E#2} in A#9[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1} in S#3)])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(\ X#6.S#9)] T#15[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {E#1;E#2} in S#3)])]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(\ X#6.S#9)] T#15[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in S#3)] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(var X#7)] ) , (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(\ X#6.S#9)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#10[[.]]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]), E#8 |-> {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15}, E#14 |-> {X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) <-gc2- (letrec {X#13=T#12[(letrec {E#1} in S#3)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ================================================================================ Critical Pair: ( (letrec {X#5=(\ X#6.S#9);E#13;E#14} in A#10[(var X#7)]) , (letrec {X#5=(\ X#6.S#9);E#14;E#16;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ) where Delta1 = {} Delta2 = {E#1,E#2,E#13,E#16} Delta3 = {(A#10[(var X#7)],(letrec {E#15;E#16} in [.])), [{X#5=(\ X#6.S#9);E#13;E#14},(letrec {E#15;E#16} in [.])], ((var X#5),[.]), ((var X#7),A#10[[.]]), ((var X#5),[.])} Delta4= { {E#13;E#15} =?= {VV#11|X#7,(var X#5)|}} from overlapping <-SR,cp-in2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#10[(var X#7)], E#1 |-> {X#5=(\ X#6.S#9);E#13;E#14}, E#8 |-> {E#14;E#16}, E#2 |-> {E#15;E#16}, E#12 |-> {E#13;E#14}} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#13;E#14;E#15;E#16} in A#10[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#9);E#13;E#14} in A#10[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#14;E#16;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#14;E#16;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ............................ Delta4: {E#13;E#15} =?= {VV#11|X#7,(var X#5)|} ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(var X#5)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in S#3)])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#11,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {E#1;E#2} in S#3)])]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1;E#2} in S#3)])]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#1} in S#3)] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#14= T#13[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]), E#8 |-> {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16}, E#15 |-> {X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]}} and instantiated rules: (letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) <-gc2- (letrec {X#14=T#13[(letrec {E#1} in S#3)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in S#3)])]] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1;E#2} in S#3)])]] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#10,A#17} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#19[(app A#20[[.]] T#21[(letrec {E#1;E#2} in S#3)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21)]];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> A#17, T#13 |-> A#17[A#19[(app A#20[(var X#5)] T#21)]], T#18 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])]];E#8} in A#11[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in S#3)])]];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])]];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1;E#2} in S#3)])]];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1} in S#3)])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(letrec {E#1;E#2} in S#3)])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {E#1;E#2} in S#3)])]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, T#13 |-> A#17[(app A#18[A#10[(var X#5)]] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1} in S#3)])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(var X#5)] T#19[(letrec {E#1} in S#3)])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(\ X#6.S#9)] T#19[(letrec {E#1;E#2} in S#3)])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#17[(app A#18[[.]] T#19[(letrec {E#1;E#2} in S#3)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> [.], T#13 |-> A#17[(app A#18[(var X#5)] T#19)], A#10 |-> A#17[(app A#18 T#19[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1} in S#3)])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(\ X#6.S#9)] T#19[(letrec {E#1;E#2} in S#3)])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in S#3)])] ;E#8 ;EE#18[X#17,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])] ;E#8 ;EE#18[X#17,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#17,A#10[(var X#5)]]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1} in S#3)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#1;E#2} in S#3)])];E#8;EE#18[X#17,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) <-gc2- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1} in S#3)])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(letrec {E#1;E#2} in S#3)])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#10,A#19} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#21[(app A#22[[.]] T#23[(letrec {E#1;E#2} in S#3)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23)]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[A#21[(app A#22[(var X#5)] T#23)]], T#20 |-> A#21[(app A#22[(var X#5)] T#23)], A#10 |-> A#21[(app A#22 T#23[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-gc2- (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1} in S#3)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {E#1;E#2} in S#3)])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[A#10[(var X#5)]] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-gc2- (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4,A#10} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),A#19[(app A#20[[.]] T#21[(letrec {E#1;E#2} in S#3)])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(var X#5)] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> [.], T#13 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-gc2- (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#5=(\ X#6.S#9);E#14;E#15} in A#11[(var X#7)]) , (letrec X#5= (\ X#6.S#9) ;E#15 ;E#17 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#10} Delta2 = {E#1,E#2,E#14,E#17} Delta3 = {(A#11[(var X#7)],(letrec {E#16;E#17} in [.])), [{X#5=(\ X#6.S#9);E#14;E#15},(letrec {E#16;E#17} in [.])], ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= { {E#14;E#16} =?= {EE#12[X#7,A#10[(var X#5)]]}} from overlapping <-SR,cp-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#11[(var X#7)], E#1 |-> {X#5=(\ X#6.S#9);E#14;E#15}, E#8 |-> {E#15;E#17}, E#2 |-> {E#16;E#17}, E#13 |-> {E#14;E#15}} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#14;E#15;E#16;E#17} in A#11[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#9);E#14;E#15} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#15;E#17;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#15;E#17;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ............................ Delta4: {E#14;E#16} =?= {EE#12[X#7,A#10[(var X#5)]]} ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in S#3)])] ) , (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#12,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(letrec {E#1;E#2} in S#3)])]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18)]), T#15 |-> A#16[(app A#17[(var X#7)] T#18)], A#12 |-> A#16[(app A#17 T#18[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1;E#2} in S#3)])]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {E#1} in S#3)] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#16= T#15[(letrec {E#1;E#2} in S#3)] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=T#15;X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), E#9 |-> {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18}, E#17 |-> {X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}} and instantiated rules: (letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#16=T#15[(letrec {E#1} in S#3)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in S#3)])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1;E#2} in S#3)])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#20,A#18,T#15,T#4,A#11,A#19} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(letrec {E#1;E#2} in S#3)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23)]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#8)] T#23)]], T#20 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in S#3)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1;E#2} in S#3)])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(letrec {E#1;E#2} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {E#1;E#2} in S#3)])]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, T#15 |-> A#19[(app A#20[A#11[(var X#8)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(var X#8)] T#21[(letrec {E#1} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(\ X#6.S#10)] T#21[(letrec {E#1;E#2} in S#3)])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#19[(app A#20[[.]] T#21[(letrec {E#1;E#2} in S#3)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#11 |-> A#19[(app A#20 T#21[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(\ X#6.S#10)] T#21[(letrec {E#1;E#2} in S#3)])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in S#3)])] ;E#9 ;EE#20[X#19,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])] ;E#9 ;EE#20[X#19,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])];EE#20[X#19,[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1} in S#3)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {E#1;E#2} in S#3)])];E#9;EE#20[X#19,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1} in S#3)])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(letrec {E#1;E#2} in S#3)])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#22,A#18,T#15,T#4,A#11,A#21} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#23[(app A#24[[.]] T#25[(letrec {E#1;E#2} in S#3)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25)]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#8)] T#25)]], T#22 |-> A#23[(app A#24[(var X#8)] T#25)], A#11 |-> A#23[(app A#24 T#25[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1} in S#3)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(letrec {E#1;E#2} in S#3)])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {E#1;E#2} in S#3)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[A#11[(var X#8)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1;E#2} in S#3)])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#4,A#11} Delta2 = {E#1,E#2} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(letrec {E#1;E#2} in S#3)])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-gc2- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {E#1;E#2} in S#3)])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#5=(\ X#6.S#10);E#16;E#17;E#18} in A#12[(var X#7)]) , (letrec X#5= (\ X#6.S#10) ;E#18 ;E#21 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#11} Delta2 = {E#1,E#2,E#16,E#17,E#21} Delta3 = {(A#12[(var X#7)],(letrec {E#19;E#20;E#21} in [.])), [{X#5=(\ X#6.S#10);E#16;E#17;E#18},(letrec {E#19;E#20;E#21} in [.])], ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= { {E#16;E#19} =?= {VV#14|X#8,(var X#5)|}, {E#17;E#20} =?= {EE#13[X#7,A#11[(var X#8)]]}} from overlapping <-SR,cp-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {E#1,E#2} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#12[(var X#7)], E#1 |-> {X#5=(\ X#6.S#10);E#16;E#17;E#18}, E#9 |-> {E#18;E#21}, E#2 |-> {E#19;E#20;E#21}, E#15 |-> {E#16;E#17;E#18}} and instantiated rules: (letrec {X#5=(\ X#6.S#10);E#16;E#17;E#18;E#19;E#20;E#21} in A#12[(var X#7)]) <-gc2- (letrec {X#5=(\ X#6.S#10);E#16;E#17;E#18} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#18;E#21;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#18;E#21;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ............................ Delta4: {E#16;E#19} =?= {VV#14|X#8,(var X#5)|}, {E#17;E#20} =?= {EE#13[X#7,A#11[(var X#8)]]} ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1} in S#3)])) , (letrec {E#5;E#6} in T#9[(letrec {E#1;E#2} in S#3)]) ) where Delta1 = {T#8,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], [{E#5},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {E#6} in T#9)), T#8 |-> (letrec {E#6} in T#9), S#7 |-> T#9[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1;E#2} in S#3)])) <-gc2- (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1} in S#3)])) ................................................................................ (letrec {E#5} in (letrec {E#6} in T#9[(letrec {E#1;E#2} in S#3)])) -SR,llet-in1-> (letrec {E#5;E#6} in T#9[(letrec {E#1;E#2} in S#3)]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1} in S#3)];E#12} in S#7)) , (letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12;E#5} in S#7) ) where Delta1 = {T#8,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], [{E#5},(letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in (letrec {X#10=T#9;E#12} in S#7)), T#8 |-> (letrec {X#10=T#9;E#12} in S#7), E#6 |-> {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12} in S#7)) <-gc2- (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1} in S#3)];E#12} in S#7)) ................................................................................ (letrec {E#5} in (letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12} in S#7)) -SR,llet-in1-> (letrec {X#10=T#9[(letrec {E#1;E#2} in S#3)];E#12;E#5} in S#7) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#1} in S#7)) , (letrec {E#1;E#2;E#5} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#7,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], [{E#5},(letrec {E#1;E#2} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {E#5} in [.]), T#8 |-> [.], S#3 |-> S#7, E#6 |-> {E#1;E#2}} and instantiated rules: (letrec {E#5} in (letrec {E#1;E#2} in S#7)) <-gc2- (letrec {E#5} in (letrec {E#1} in S#7)) ................................................................................ (letrec {E#5} in (letrec {E#1;E#2} in S#7)) -SR,llet-in1-> (letrec {E#1;E#2;E#5} in S#7) ================================================================================ Critical Pair: ( (letrec {X#9=T#8[(letrec {E#1} in S#3)];E#11} in (letrec {E#6} in S#7)) , (letrec {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11;E#6} in S#7) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], [{X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> (letrec {X#9=T#8;E#11} in (letrec {E#6} in S#7)), E#5 |-> {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11}, E#10 |-> {E#11}} and instantiated rules: (letrec {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11} in (letrec {E#6} in S#7)) <-gc2- (letrec {X#9=T#8[(letrec {E#1} in S#3)];E#11} in (letrec {E#6} in S#7)) ................................................................................ (letrec {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {X#9=T#8[(letrec {E#1;E#2} in S#3)];E#11;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec {E#1} in (letrec {E#6} in S#7)) , (letrec {E#1;E#2;E#6} in S#7) ) where Delta1 = {} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {((letrec {E#6} in S#7),(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], [{E#1;E#2},(letrec {E#6} in [.])]} Delta4= {} from overlapping <-SR,llet-in1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],[{E#5},(letrec {E#6} in [.])]} and found solution: Sol = {T#4 |-> [.], S#3 |-> (letrec {E#6} in S#7), E#5 |-> {E#1;E#2}} and instantiated rules: (letrec {E#1;E#2} in (letrec {E#6} in S#7)) <-gc2- (letrec {E#1} in (letrec {E#6} in S#7)) ................................................................................ (letrec {E#1;E#2} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#1;E#2;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in S#3)])] ) , (letrec X#5= S#8 ;E#6 ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {E#1;E#2} in S#3)])]), ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,llet-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in T#13[(letrec {E#1} in S#3)]) ;E#7 in A#9[(var X#5)] ) , (letrec {X#5=T#13[(letrec {E#1;E#2} in S#3)];E#6;E#7} in A#9[(var X#5)]) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#6} in T#13);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1;E#2} in S#3)]);E#7} in A#9[(var X#5)]) <-gc2- (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1} in S#3)]);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#6} in T#13[(letrec {E#1;E#2} in S#3)]);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=T#13[(letrec {E#1;E#2} in S#3)];E#6;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#14=T#13[(letrec {E#1} in S#3)];E#16} in S#8) ;E#7 in A#9[(var X#5)] ) , (letrec X#14= T#13[(letrec {E#1;E#2} in S#3)] ;X#5= S#8 ;E#16 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16} in [.])), [{E#7},(letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#14=T#13;E#16} in S#8);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16} in S#8);E#7} in A#9[(var X#5)]) <-gc2- (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1} in S#3)];E#16} in S#8);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];E#16} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#14=T#13[(letrec {E#1;E#2} in S#3)];X#5=S#8;E#16;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#1} in S#8);E#7} in A#9[(var X#5)]) , (letrec {X#5=S#8;E#1;E#2;E#7} in A#9[(var X#5)]) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#8,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#1;E#2} in [.])), [{E#7},(letrec {E#1;E#2} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=[.];E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> [.], S#3 |-> S#8, E#6 |-> {E#1;E#2}} and instantiated rules: (letrec {X#5=(letrec {E#1;E#2} in S#8);E#7} in A#9[(var X#5)]) <-gc2- (letrec {X#5=(letrec {E#1} in S#8);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#1;E#2} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#1;E#2;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in S#3)] ;X#5= (letrec {E#6} in S#8) ;E#13 in A#9[(var X#5)] ) , (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;X#5= S#8 ;E#13 ;E#6 in A#9[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13}, E#12 |-> {X#5=(letrec {E#6} in S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) <-gc2- (letrec {X#11=T#10[(letrec {E#1} in S#3)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];X#5=S#8;E#13;E#6} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#6} in S#8);E#10} in A#9[(var X#5)]) , (letrec {X#5=S#8;E#10;E#2;E#6} in A#9[(var X#5)]) ) where Delta1 = {} Delta2 = {E#1,E#2,E#6} Delta3 = {(A#9[(var X#5)],(letrec {E#2} in [.])), [{X#5=(letrec {E#6} in S#8);E#10},(letrec {E#2} in [.])], (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#10;E#2},(letrec {E#6} in [.])], ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#9[(var X#5)], E#1 |-> {X#5=(letrec {E#6} in S#8);E#10}, E#7 |-> {E#10;E#2}} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8);E#10;E#2} in A#9[(var X#5)]) <-gc2- (letrec {X#5=(letrec {E#6} in S#8);E#10} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#10;E#2} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#10;E#2;E#6} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in S#3)])] ) , (letrec X#5= S#9 ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])]), ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15)]), T#12 |-> A#13[(app A#14[(var X#6)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in T#15[(letrec {E#1} in S#3)]) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= T#15[(letrec {E#1;E#2} in S#3)] ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in T#15);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1;E#2} in S#3)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-gc2- (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1} in S#3)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in T#15[(letrec {E#1;E#2} in S#3)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=T#15[(letrec {E#1;E#2} in S#3)];E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#16=T#15[(letrec {E#1} in S#3)];E#18} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= T#15[(letrec {E#1;E#2} in S#3)] ;X#5= S#9 ;E#18 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {X#16=T#15;E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-gc2- (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1} in S#3)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=T#15[(letrec {E#1;E#2} in S#3)];X#5=S#9;E#18;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#1} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) , (letrec {X#5=S#9;E#1;E#2;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {E#1;E#2;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#1;E#2} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#1;E#2} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=[.];E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> [.], S#3 |-> S#9, E#7 |-> {E#1;E#2}} and instantiated rules: (letrec {X#5=(letrec {E#1;E#2} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-gc2- (letrec {X#5=(letrec {E#1} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#1;E#2} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#1;E#2;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in S#3)] ;X#5= (letrec {E#7} in S#9) ;E#15 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;X#5= S#9 ;E#15 ;E#7 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;E#7;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), E#8 |-> {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15}, E#14 |-> {X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-gc2- (letrec {X#13=T#12[(letrec {E#1} in S#3)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];X#5=S#9;E#15;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in S#3)])] ;E#8 in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])];E#7;E#8} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])];E#8},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18)];E#8} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1;E#2} in S#3)])]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8}, T#12 |-> A#16[(app A#17[(var X#5)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])];E#8} in A#10[(var X#6)]) <-gc2- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1} in S#3)])];E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])];E#8} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {E#1;E#2} in S#3)])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#3)])] ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#7 ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;E#8;EE#17[X#16,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#8;EE#17[X#16,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20)];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];EE#17[X#16,[.2]]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#16,(var X#5)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) <-gc2- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#3)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#3)])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])] ;X#5= S#9 ;E#7 ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) <-gc2- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];X#5=S#9;E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in S#3)])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])] ;X#5= S#9 ;E#7 ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], ((var X#5),(letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])];E#7;E#8;EE#17[X#6,(var X#16)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])];E#8;EE#17[X#6,(var X#16)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20)];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1;E#2} in S#3)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]}, T#12 |-> A#18[(app A#19[(var X#5)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-gc2- (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {E#1;E#2} in S#3)])];X#5=S#9;E#7;E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#7} in S#9);E#13;E#14} in A#10[(var X#6)]) , (letrec {X#5=S#9;E#14;E#16;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ) where Delta1 = {} Delta2 = {E#1,E#2,E#7,E#13,E#16} Delta3 = {(A#10[(var X#6)],(letrec {E#15;E#16} in [.])), [{X#5=(letrec {E#7} in S#9);E#13;E#14},(letrec {E#15;E#16} in [.])], ((var X#5),(letrec {E#14;E#16;E#7;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#14;E#16;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= { {E#13;E#15} =?= {EE#11[X#6,(var X#5)]}} from overlapping <-SR,llet-e2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#10[(var X#6)], E#1 |-> {X#5=(letrec {E#7} in S#9);E#13;E#14}, E#8 |-> {E#14;E#16}, E#2 |-> {E#15;E#16}, E#12 |-> {E#13;E#14}} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);E#13;E#14;E#15;E#16} in A#10[(var X#6)]) <-gc2- (letrec {X#5=(letrec {E#7} in S#9);E#13;E#14} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#14;E#16;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#14;E#16;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ............................ Delta4: {E#13;E#15} =?= {EE#11[X#6,(var X#5)]} ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in T#12[(letrec {E#1} in S#3)]) S#6)] , A#9[(letrec {E#5} in (app T#12[(letrec {E#1;E#2} in S#3)] S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in T#12) S#6)], T#10 |-> (app (letrec {E#5} in T#12) S#6), T#11 |-> (letrec {E#5} in T#12), S#7 |-> T#12[(letrec {E#1;E#2} in S#3)]} and instantiated rules: A#9[(app (letrec {E#5} in T#12[(letrec {E#1;E#2} in S#3)]) S#6)] <-gc2- A#9[(app (letrec {E#5} in T#12[(letrec {E#1} in S#3)]) S#6)] ................................................................................ A#9[(app (letrec {E#5} in T#12[(letrec {E#1;E#2} in S#3)]) S#6)] -SR,lapp1-> A#9[(letrec {E#5} in (app T#12[(letrec {E#1;E#2} in S#3)] S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {X#13=T#12[(letrec {E#1} in S#3)];E#15} in S#7) S#6)] , A#9[(letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in (app S#7 S#6))] ) where Delta1 = {T#11,T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {X#13=T#12;E#15} in S#7) S#6)], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#7) S#6), T#11 |-> (letrec {X#13=T#12;E#15} in S#7), E#5 |-> {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15}, E#14 |-> {E#15}} and instantiated rules: A#9[(app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#7) S#6)] <-gc2- A#9[(app (letrec {X#13=T#12[(letrec {E#1} in S#3)];E#15} in S#7) S#6)] ................................................................................ A#9[(app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#1} in S#7) S#6)] , A#9[(letrec {E#1;E#2} in (app S#7 S#6))] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#7,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#1;E#2} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app [.] S#6)], T#10 |-> (app [.] S#6), T#11 |-> [.], S#3 |-> S#7, E#5 |-> {E#1;E#2}} and instantiated rules: A#9[(app (letrec {E#1;E#2} in S#7) S#6)] <-gc2- A#9[(app (letrec {E#1} in S#7) S#6)] ................................................................................ A#9[(app (letrec {E#1;E#2} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {E#1;E#2} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1} in S#3)])] , A#9[(letrec {E#5} in (app S#7 T#11[(letrec {E#1;E#2} in S#3)]))] ) where Delta1 = {T#10,A#8,T#4,A#9} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1;E#2} in S#3)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> A#9, T#4 |-> A#9[(app (letrec {E#5} in S#7) T#11)], T#10 |-> (app (letrec {E#5} in S#7) T#11), S#6 |-> T#11[(letrec {E#1;E#2} in S#3)]} and instantiated rules: A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1;E#2} in S#3)])] <-gc2- A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1} in S#3)])] ................................................................................ A#9[(app (letrec {E#5} in S#7) T#11[(letrec {E#1;E#2} in S#3)])] -SR,lapp1-> A#9[(letrec {E#5} in (app S#7 T#11[(letrec {E#1;E#2} in S#3)]))] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1} in S#3)])] , A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(letrec {E#1;E#2} in S#3)])] ) where Delta1 = {A#8,T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {T#4 |-> A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] <-gc2- A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1} in S#3)])] ................................................................................ A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {E#1;E#2} in S#3)])] -SR,lapp1-> A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(letrec {E#1;E#2} in S#3)])] ================================================================================ Critical Pair: ( (app (letrec {E#5} in T#10[(letrec {E#1} in S#3)]) S#6) , (letrec {E#5} in (app T#10[(letrec {E#1;E#2} in S#3)] S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in T#10) S#6), T#9 |-> (letrec {E#5} in T#10), S#7 |-> T#10[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (app (letrec {E#5} in T#10[(letrec {E#1;E#2} in S#3)]) S#6) <-gc2- (app (letrec {E#5} in T#10[(letrec {E#1} in S#3)]) S#6) ................................................................................ (app (letrec {E#5} in T#10[(letrec {E#1;E#2} in S#3)]) S#6) -SR,lapp1-> (letrec {E#5} in (app T#10[(letrec {E#1;E#2} in S#3)] S#6)) ================================================================================ Critical Pair: ( (app (letrec {X#11=T#10[(letrec {E#1} in S#3)];E#13} in S#7) S#6) , (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in (app S#7 S#6)) ) where Delta1 = {T#9,T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {X#11=T#10;E#13} in S#7) S#6), T#9 |-> (letrec {X#11=T#10;E#13} in S#7), E#5 |-> {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13}, E#12 |-> {E#13}} and instantiated rules: (app (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in S#7) S#6) <-gc2- (app (letrec {X#11=T#10[(letrec {E#1} in S#3)];E#13} in S#7) S#6) ................................................................................ (app (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in S#7) S#6) -SR,lapp1-> (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in (app S#7 S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#1} in S#7) S#6) , (letrec {E#1;E#2} in (app S#7 S#6)) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#7,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#6,(letrec {E#1;E#2} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app [.] S#6), T#9 |-> [.], S#3 |-> S#7, E#5 |-> {E#1;E#2}} and instantiated rules: (app (letrec {E#1;E#2} in S#7) S#6) <-gc2- (app (letrec {E#1} in S#7) S#6) ................................................................................ (app (letrec {E#1;E#2} in S#7) S#6) -SR,lapp1-> (letrec {E#1;E#2} in (app S#7 S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#5} in S#7) T#9[(letrec {E#1} in S#3)]) , (letrec {E#5} in (app S#7 T#9[(letrec {E#1;E#2} in S#3)])) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#9[(letrec {E#1;E#2} in S#3)],(letrec {E#5} in [.]))} Delta4= {} from overlapping <-SR,lapp1- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#1,E#2,E#5} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#6,(letrec {E#5} in [.]))} and found solution: Sol = {A#8 |-> [.], T#4 |-> (app (letrec {E#5} in S#7) T#9), S#6 |-> T#9[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (app (letrec {E#5} in S#7) T#9[(letrec {E#1;E#2} in S#3)]) <-gc2- (app (letrec {E#5} in S#7) T#9[(letrec {E#1} in S#3)]) ................................................................................ (app (letrec {E#5} in S#7) T#9[(letrec {E#1;E#2} in S#3)]) -SR,lapp1-> (letrec {E#5} in (app S#7 T#9[(letrec {E#1;E#2} in S#3)])) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1} in S#3)]) S#7)]) , (letrec E#5 in A#11[(letrec {E#6} in (app T#14[(letrec {E#1;E#2} in S#3)] S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in T#14) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in T#14) S#7)], T#12 |-> (app (letrec {E#6} in T#14) S#7), T#13 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1;E#2} in S#3)]) S#7)]) <-gc2- (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1} in S#3)]) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {E#1;E#2} in S#3)]) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app T#14[(letrec {E#1;E#2} in S#3)] S#7))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app (letrec {X#15=T#14[(letrec {E#1} in S#3)];E#17} in S#8) S#7)] ) , (letrec E#5 in A#11[(letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in (app S#8 S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#8) S#7), T#13 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in S#8) S#7)]) <-gc2- (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1} in S#3)];E#17} in S#8) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {X#15=T#14[(letrec {E#1;E#2} in S#3)];E#17} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {E#1} in S#8) S#7)]) , (letrec {E#5} in A#11[(letrec {E#1;E#2} in (app S#8 S#7))]) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#8,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#1;E#2} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app [.] S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app [.] S#7)], T#12 |-> (app [.] S#7), T#13 |-> [.], S#3 |-> S#8, E#6 |-> {E#1;E#2}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#1;E#2} in S#8) S#7)]) <-gc2- (letrec {E#5} in A#11[(app (letrec {E#1} in S#8) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#1;E#2} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#1;E#2} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1} in S#3)])]) , (letrec E#5 in A#11[(letrec {E#6} in (app S#8 T#13[(letrec {E#1;E#2} in S#3)]))] ) ) where Delta1 = {T#12,A#9,T#10,T#4,A#11} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#13[(letrec {E#1;E#2} in S#3)],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in S#8) T#13)], T#12 |-> (app (letrec {E#6} in S#8) T#13), S#7 |-> T#13[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {E#1;E#2} in S#3)])]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 T#13[(letrec {E#1;E#2} in S#3)]))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1} in S#3)])] ) , (letrec E#5 in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#9,T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {E#1;E#2} in S#3)])]) -SR,lapp2-> (letrec {E#5} in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1} in S#3)]) S#7)) , (letrec {E#5} in (letrec {E#6} in (app T#12[(letrec {E#1;E#2} in S#3)] S#7))) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in T#12) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in T#12) S#7), T#11 |-> (letrec {E#6} in T#12), S#8 |-> T#12[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1;E#2} in S#3)]) S#7)) <-gc2- (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1} in S#3)]) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {E#1;E#2} in S#3)]) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app T#12[(letrec {E#1;E#2} in S#3)] S#7))) ================================================================================ Critical Pair: ( (letrec E#5 in (app (letrec {X#13=T#12[(letrec {E#1} in S#3)];E#15} in S#8) S#7) ) , (letrec E#5 in (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in (app S#8 S#7)) ) ) where Delta1 = {T#11,T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {X#13=T#12;E#15} in S#8) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#8) S#7), T#11 |-> (letrec {X#13=T#12;E#15} in S#8), E#6 |-> {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#8) S#7)) <-gc2- (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1} in S#3)];E#15} in S#8) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in S#8) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#1} in S#8) S#7)) , (letrec {E#5} in (letrec {E#1;E#2} in (app S#8 S#7))) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#8,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#1;E#2} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app [.] S#7)), A#9 |-> [.], T#10 |-> (app [.] S#7), T#11 |-> [.], S#3 |-> S#8, E#6 |-> {E#1;E#2}} and instantiated rules: (letrec {E#5} in (app (letrec {E#1;E#2} in S#8) S#7)) <-gc2- (letrec {E#5} in (app (letrec {E#1} in S#8) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#1;E#2} in S#8) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#1;E#2} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1} in S#3)])) , (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(letrec {E#1;E#2} in S#3)]))) ) where Delta1 = {T#10,T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#11[(letrec {E#1;E#2} in S#3)],(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {E#5} in (app (letrec {E#6} in S#8) T#11)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in S#8) T#11), S#7 |-> T#11[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1;E#2} in S#3)])) <-gc2- (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1} in S#3)])) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {E#1;E#2} in S#3)])) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(letrec {E#1;E#2} in S#3)]))) ================================================================================ Critical Pair: ( (letrec X#11= T#10[(letrec {E#1} in S#3)] ;E#13 in A#9[(app (letrec {E#6} in S#8) S#7)] ) , (letrec X#11= T#10[(letrec {E#1;E#2} in S#3)] ;E#13 in A#9[(letrec {E#6} in (app S#8 S#7))] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> (letrec {X#11=T#10;E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]), E#5 |-> {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) <-gc2- (letrec {X#11=T#10[(letrec {E#1} in S#3)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {X#11=T#10[(letrec {E#1;E#2} in S#3)];E#13} in A#9[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec {E#1} in A#9[(app (letrec {E#6} in S#8) S#7)]) , (letrec {E#1;E#2} in A#9[(letrec {E#6} in (app S#8 S#7))]) ) where Delta1 = {} Delta2 = {E#1,E#2,E#5,E#6} Delta3 = {(A#9[(app (letrec {E#6} in S#8) S#7)],(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#7,(letrec {E#6} in [.]))} Delta4= {} from overlapping <-SR,lapp2- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#1,E#2,E#5,E#6} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#7,(letrec {E#6} in [.]))} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#9[(app (letrec {E#6} in S#8) S#7)], E#5 |-> {E#1;E#2}} and instantiated rules: (letrec {E#1;E#2} in A#9[(app (letrec {E#6} in S#8) S#7)]) <-gc2- (letrec {E#1} in A#9[(app (letrec {E#6} in S#8) S#7)]) ................................................................................ (letrec {E#1;E#2} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#1;E#2} in A#9[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec E#6 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in S#3)])] ) , (letrec E#6 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])] ) ) where Delta1 = {A#10,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {E#1;E#2} in S#3)])])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) <-gc2- (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1} in S#3)])]) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#13[(app A#14[(var X#5)] T#15[(letrec {E#1;E#2} in S#3)])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[(letrec {E#1} in S#3)] ;E#15 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(letrec {E#1;E#2} in S#3)] ;E#15 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), E#6 |-> {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-gc2- (letrec {X#13=T#12[(letrec {E#1} in S#3)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#13=T#12[(letrec {E#1;E#2} in S#3)];E#15;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in T#19[(letrec {E#1} in S#3)]) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app T#19[(letrec {E#1;E#2} in S#3)] S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in T#19) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in T#19) S#8)], T#17 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8)];E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1} in S#3)]) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app T#19[(letrec {E#1;E#2} in S#3)] S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {X#20=T#19[(letrec {E#1} in S#3)];E#22} in S#9) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in (app S#9 S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)], T#17 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1} in S#3)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(app (letrec {E#1} in S#9) S#8)];E#6} in A#10[(var X#5)]) , (letrec {X#5=A#16[(letrec {E#1;E#2} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1;E#2} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app [.] S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app [.] S#8)], T#17 |-> (app [.] S#8), T#18 |-> [.], S#3 |-> S#9, E#7 |-> {E#1;E#2}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#1;E#2} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app (letrec {E#1} in S#9) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#1;E#2} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#1;E#2} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in S#3)])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app S#9 T#18[(letrec {E#1;E#2} in S#3)]))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#4,A#16} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1;E#2} in S#3)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in S#9) T#18)], T#17 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in S#3)])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app S#9 T#18[(letrec {E#1;E#2} in S#3)]))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1} in S#3)])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(letrec {E#1;E#2} in S#3)])] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {E#1;E#2} in S#3)])]}, X#13 |-> X#5, E#14 |-> {E#6}, T#12 |-> A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1} in S#3)])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(letrec {E#1;E#2} in S#3)])];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in T#17[(letrec {E#1} in S#3)]) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app T#17[(letrec {E#1;E#2} in S#3)] S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in T#17) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#17) S#8), T#16 |-> (letrec {E#7} in T#17), S#9 |-> T#17[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1;E#2} in S#3)]) S#8);E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1} in S#3)]) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {E#1;E#2} in S#3)]) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app T#17[(letrec {E#1;E#2} in S#3)] S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {X#18=T#17[(letrec {E#1} in S#3)];E#20} in S#9) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in (app S#9 S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {X#18=T#17;E#20} in S#9) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {X#18=T#17;E#20} in S#9) S#8), T#16 |-> (letrec {X#18=T#17;E#20} in S#9), E#7 |-> {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1} in S#3)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {X#18=T#17[(letrec {E#1;E#2} in S#3)];E#20} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(app (letrec {E#1} in S#9) S#8);E#6} in A#10[(var X#5)]) , (letrec {X#5=(letrec {E#1;E#2} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1;E#2} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app [.] S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app [.] S#8), T#16 |-> [.], S#3 |-> S#9, E#7 |-> {E#1;E#2}} and instantiated rules: (letrec {X#5=(app (letrec {E#1;E#2} in S#9) S#8);E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=(app (letrec {E#1} in S#9) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#1;E#2} in S#9) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#1;E#2} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {E#7} in S#9) T#16[(letrec {E#1} in S#3)]) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {E#7} in (app S#9 T#16[(letrec {E#1;E#2} in S#3)])) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#16[(letrec {E#1;E#2} in S#3)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=(app (letrec {E#7} in S#9) T#16);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#16), S#8 |-> T#16[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1;E#2} in S#3)]);E#6} in A#10[(var X#5)]) <-gc2- (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1} in S#3)]);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {E#1;E#2} in S#3)]);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app S#9 T#16[(letrec {E#1;E#2} in S#3)]));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#3)])] ;E#6 ;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-gc2- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1} in S#3)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#3)])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1} in S#3)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {E#1;E#2} in S#3)])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in T#21[(letrec {E#1} in S#3)]) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app T#21[(letrec {E#1;E#2} in S#3)] S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in T#21) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in T#21) S#8)], T#19 |-> (app (letrec {E#7} in T#21) S#8), T#20 |-> (letrec {E#7} in T#21), S#9 |-> T#21[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1;E#2} in S#3)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1} in S#3)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {E#1;E#2} in S#3)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app T#21[(letrec {E#1;E#2} in S#3)] S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {X#22=T#21[(letrec {E#1} in S#3)];E#24} in S#9) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#9) S#8), T#20 |-> (letrec {X#22=T#21;E#24} in S#9), E#7 |-> {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1} in S#3)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {X#22=T#21[(letrec {E#1;E#2} in S#3)];E#24} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#1} in S#9) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#1;E#2} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1;E#2} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app [.] S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app [.] S#8)], T#19 |-> (app [.] S#8), T#20 |-> [.], S#3 |-> S#9, E#7 |-> {E#1;E#2}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#1;E#2} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app (letrec {E#1} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#1;E#2} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#1;E#2} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app S#9 T#20[(letrec {E#1;E#2} in S#3)]))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#4,A#18} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#20[(letrec {E#1;E#2} in S#3)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in S#9) T#20)], T#19 |-> (app (letrec {E#7} in S#9) T#20), S#8 |-> T#20[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app S#9 T#20[(letrec {E#1;E#2} in S#3)]))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(letrec {E#1;E#2} in S#3)])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {E#1;E#2} in S#3)])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {E#1;E#2} in S#3)])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(letrec {E#1;E#2} in S#3)])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in T#19[(letrec {E#1} in S#3)]) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app T#19[(letrec {E#1;E#2} in S#3)] S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in T#19) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1} in S#3)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {E#1;E#2} in S#3)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app T#19[(letrec {E#1;E#2} in S#3)] S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {X#20=T#19[(letrec {E#1} in S#3)];E#22} in S#9) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in (app S#9 S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {X#20=T#19;E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1} in S#3)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {X#20=T#19[(letrec {E#1;E#2} in S#3)];E#22} in (app S#9 S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#1} in S#9) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#1;E#2} in (app S#9 S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#9,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (S#8,(letrec {E#1;E#2} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app [.] S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app [.] S#8), T#18 |-> [.], S#3 |-> S#9, E#7 |-> {E#1;E#2}} and instantiated rules: (letrec {X#16=(app (letrec {E#1;E#2} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=(app (letrec {E#1} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#1;E#2} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#1;E#2} in (app S#9 S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in S#9) T#18[(letrec {E#1} in S#3)]) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app S#9 T#18[(letrec {E#1;E#2} in S#3)])) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#4} Delta2 = {E#1,E#2,E#7} Delta3 = {(S#3,(letrec {E#2} in [.])), [{E#1},(letrec {E#2} in [.])], (T#18[(letrec {E#1;E#2} in S#3)],(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#16=(app (letrec {E#7} in S#9) T#18);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(letrec {E#1;E#2} in S#3)]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-gc2- (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1} in S#3)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {E#1;E#2} in S#3)]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app S#9 T#18[(letrec {E#1;E#2} in S#3)]));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {E#14;E#15} in A#10[(var X#5)]) , (letrec E#13 ;E#15 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {} Delta2 = {E#1,E#2,E#7,E#13,E#14} Delta3 = {(A#10[(var X#5)],(letrec {E#12;E#13} in [.])), [{E#14;E#15},(letrec {E#12;E#13} in [.])], (S#8,(letrec {E#7} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= { {E#12;E#14} =?= {EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]}} from overlapping <-SR,lapp3- . -gc2-> with input rules: T#4[(letrec {E#1;E#2} in S#3)] <-gc2- T#4[(letrec {E#1} in S#3)] and constraints: E#1/= {}, E#2/= {}, (S#3,(letrec {E#2} in [.])), ({E#1},(letrec {E#2} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {E#1;E#2} in S#3)] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#1,E#2,E#7} Delta3= {(S#3,(letrec {E#2} in [.])),[{E#1},(letrec {E#2} in [.])],(S#8,(letrec {E#7} in [.])),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], S#3 |-> A#10[(var X#5)], E#6 |-> {E#13;E#15}, E#1 |-> {E#14;E#15}, E#2 |-> {E#12;E#13}} and instantiated rules: (letrec {E#12;E#13;E#14;E#15} in A#10[(var X#5)]) <-gc2- (letrec {E#14;E#15} in A#10[(var X#5)]) ................................................................................ (letrec {E#13;E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#13;E#15;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ............................ Delta4: {E#12;E#14} =?= {EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} ================================================================================ Critical Pair: ( A#10[(app (\ X#6.S#8) T#12[(letrec {E#2} in T#5[S#3])])] , A#10[(letrec {X#6=T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#8)] ) where Delta1 = {T#11,A#9,T#4,A#10} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#6.[.])), (T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#6=[.]} in S#8)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (\ X#6.S#8) S#7)] -SR,lbeta1-> A#9[(letrec {X#6=S#7} in S#8)] and constraints: (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (\ X#6.S#8) S#7)]} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#6.[.])),(S#7,(letrec {X#6=[.]} in S#8)),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (\ X#6.S#8) T#12)], T#11 |-> (app (\ X#6.S#8) T#12), S#7 |-> T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: A#10[(app (\ X#6.S#8) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] <-ucp1- A#10[(app (\ X#6.S#8) T#12[(letrec {E#2} in T#5[S#3])])] ................................................................................ A#10[(app (\ X#6.S#8) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] -SR,lbeta1-> A#10[(letrec {X#6=T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#8)] ================================================================================ Critical Pair: ( A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {E#2} in T#5[S#3])])] , A#10[(app A#11[(letrec {X#6=S#7} in S#8)] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) where Delta1 = {A#9,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (\ X#6.S#8) S#7)] -SR,lbeta1-> A#9[(letrec {X#6=S#7} in S#8)] and constraints: (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (\ X#6.S#8) S#7)]} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#6.[.])),(S#7,(letrec {X#6=[.]} in S#8)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12)], A#9 |-> A#10[(app A#11 T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] <-ucp1- A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {E#2} in T#5[S#3])])] ................................................................................ A#10[(app A#11[(app (\ X#6.S#8) S#7)] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] -SR,lbeta1-> A#10[(app A#11[(letrec {X#6=S#7} in S#8)] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ================================================================================ Critical Pair: ( (app (\ X#6.S#8) T#10[(letrec {E#2} in T#5[S#3])]) , (letrec {X#6=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#8) ) where Delta1 = {T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#6.[.])), (T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#6=[.]} in S#8)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (\ X#6.S#8) S#7)] -SR,lbeta1-> A#9[(letrec {X#6=S#7} in S#8)] and constraints: (S#7,(\ X#6.[.])), (S#7,(letrec {X#6=[.]} in S#8)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (\ X#6.S#8) S#7)]} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#6.[.])),(S#7,(letrec {X#6=[.]} in S#8)),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (\ X#6.S#8) T#10), S#7 |-> T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (app (\ X#6.S#8) T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) <-ucp1- (app (\ X#6.S#8) T#10[(letrec {E#2} in T#5[S#3])]) ................................................................................ (app (\ X#6.S#8) T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) -SR,lbeta1-> (letrec {X#6=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#8) ================================================================================ Critical Pair: ( (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {E#2} in T#5[S#3])])]) , (letrec E#7 in A#12[(letrec {X#6=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#9)] ) ) where Delta1 = {T#13,A#10,T#11,T#4,A#12} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#6.[.])), (T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14)]), A#10 |-> A#12, T#11 |-> A#12[(app (\ X#6.S#9) T#14)], T#13 |-> (app (\ X#6.S#9) T#14), S#8 |-> T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {E#7} in A#12[(app (\ X#6.S#9) T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,lbeta2-> (letrec {E#7} in A#12[(letrec {X#6=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#9)]) ================================================================================ Critical Pair: ( (letrec E#7 in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {E#2} in T#5[S#3])])] ) , (letrec E#7 in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)]), T#11 |-> A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {E#7} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,lbeta2-> (letrec {E#7} in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {E#2} in T#5[S#3])])) , (letrec E#7 in (letrec {X#6=T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#9) ) ) where Delta1 = {T#11,T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#6.[.])), (T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7} in (app (\ X#6.S#9) T#12)), A#10 |-> [.], T#11 |-> (app (\ X#6.S#9) T#12), S#8 |-> T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) <-ucp1- (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {E#2} in T#5[S#3])])) ................................................................................ (letrec {E#7} in (app (\ X#6.S#9) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) -SR,lbeta2-> (letrec {E#7} in (letrec {X#6=T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#9)) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {E#2} in T#5[S#3])] ;E#14 in A#10[(app (\ X#6.S#9) S#8)] ) , (letrec X#12= T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#14 in A#10[(letrec {X#6=S#8} in S#9)] ) ) where Delta1 = {T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;E#14} in A#10[(app (\ X#6.S#9) S#8)]), E#7 |-> {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in A#10[(app (\ X#6.S#9) S#8)]) <-ucp1- (letrec {X#12=T#11[(letrec {E#2} in T#5[S#3])];E#14} in A#10[(app (\ X#6.S#9) S#8)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in A#10[(letrec {X#6=S#8} in S#9)]) ================================================================================ Critical Pair: ( (letrec {E#11} in A#12[(app (\ X#6.S#9) T#14[S#3])]) , (letrec {X#1=S#3;E#11} in A#12[(letrec {X#6=T#14[(var X#1)]} in S#9)]) ) where Delta1 = {T#13,A#10,T#5,A#12} Delta2 = {E#11,E#2,E#7} Delta3 = {((var X#1),A#12[(app (\ X#6.S#9) T#14)]), (S#3,A#12[(app (\ X#6.S#9) T#14)]), ((letrec {E#11} in A#12[(app (\ X#6.S#9) T#14[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#14[(var X#1)],(\ X#6.[.])), (T#14[(var X#1)],(letrec {X#6=[.]} in S#9)), ((var X#1),A#12[(app (\ X#6.S#9) T#14[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> A#12, T#5 |-> A#12[(app (\ X#6.S#9) T#14)], T#13 |-> (app (\ X#6.S#9) T#14), S#8 |-> T#14[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#11} in A#12[(app (\ X#6.S#9) T#14[(var X#1)])]) <-ucp1- (letrec {E#11} in A#12[(app (\ X#6.S#9) T#14[S#3])]) ................................................................................ (letrec {X#1=S#3;E#11} in A#12[(app (\ X#6.S#9) T#14[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=S#3;E#11} in A#12[(letrec {X#6=T#14[(var X#1)]} in S#9)]) ================================================================================ Critical Pair: ( (letrec {E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[S#3])]) , (letrec X#1= S#3 ;E#11 in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] T#14[(var X#1)])] ) ) where Delta1 = {A#10,T#5} Delta2 = {E#11,E#2,E#7} Delta3 = {((var X#1),A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)]), (S#3,A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)]), ((letrec {E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, T#5 |-> A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14)], A#10 |-> A#12[(app A#13 T#14[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(var X#1)])]) <-ucp1- (letrec {E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[S#3])]) ................................................................................ (letrec {X#1=S#3;E#11} in A#12[(app A#13[(app (\ X#6.S#9) S#8)] T#14[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=S#3;E#11} in A#12[(app A#13[(letrec {X#6=S#8} in S#9)] T#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {E#11} in (app (\ X#6.S#9) T#12[S#3])) , (letrec {X#1=S#3;E#11} in (letrec {X#6=T#12[(var X#1)]} in S#9)) ) where Delta1 = {T#5} Delta2 = {E#11,E#2,E#7} Delta3 = {((var X#1),(app (\ X#6.S#9) T#12)), (S#3,(app (\ X#6.S#9) T#12)), ((letrec {E#11} in (app (\ X#6.S#9) T#12[(dummy3 )])),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#12[(var X#1)],(\ X#6.[.])), (T#12[(var X#1)],(letrec {X#6=[.]} in S#9)), ((var X#1),(app (\ X#6.S#9) T#12[[.]]))} Delta4= {} from overlapping <-SR,lbeta2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)]) -SR,lbeta2-> (letrec {E#7} in A#10[(letrec {X#6=S#8} in S#9)]) and constraints: E#7/= {}, (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7} in A#10[(app (\ X#6.S#9) S#8)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> [.], T#5 |-> (app (\ X#6.S#9) T#12), S#8 |-> T#12[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#11} in (app (\ X#6.S#9) T#12[(var X#1)])) <-ucp1- (letrec {E#11} in (app (\ X#6.S#9) T#12[S#3])) ................................................................................ (letrec {X#1=S#3;E#11} in (app (\ X#6.S#9) T#12[(var X#1)])) -SR,lbeta2-> (letrec {X#1=S#3;E#11} in (letrec {X#6=T#12[(var X#1)]} in S#9)) ================================================================================ Critical Pair: ( (letrec E#8 ;EE#12[X#6,(app (\ X#7.S#10) S#9)] in A#14[(app A#15[(var X#6)] T#16[(letrec {E#2} in T#5[S#3])])] ) , (letrec E#8 ;EE#12[X#6,(letrec {X#7=S#9} in S#10)] in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16)]), T#13 |-> A#14[(app A#15[(var X#6)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#2} in T#5[S#3])] ;E#16 ;EE#12[X#6,(app (\ X#7.S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#14= T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#16 ;EE#12[X#6,(letrec {X#7=S#9} in S#10)] in A#11[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]), E#8 |-> {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16}, E#15 |-> {E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (\ X#7.S#10) T#19[(letrec {E#2} in T#5[S#3])])] ;E#8 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec {X#7=T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10)] ;E#8 in A#11[(var X#6)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#17} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#7.[.])), (T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (\ X#7.S#10) T#19)];E#8} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#8}, A#16 |-> A#17, T#13 |-> A#17[(app (\ X#7.S#10) T#19)], T#18 |-> (app (\ X#7.S#10) T#19), S#9 |-> T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=A#17[(app (\ X#7.S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app (\ X#7.S#10) T#19[(letrec {E#2} in T#5[S#3])])];E#8} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (\ X#7.S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#17[(letrec {X#7=T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10)];E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {E#2} in T#5[S#3])])] ;E#8 in A#11[(var X#6)] ) , (letrec X#6= A#17[(app A#18[(letrec {X#7=S#9} in S#10)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#8 in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19)];E#8} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]}, X#14 |-> X#6, E#15 |-> {E#8}, T#13 |-> A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {E#2} in T#5[S#3])])];E#8} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app A#18[(app (\ X#7.S#10) S#9)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#17[(app A#18[(letrec {X#7=S#9} in S#10)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (\ X#7.S#10) T#17[(letrec {E#2} in T#5[S#3])]) ;E#8 in A#11[(var X#6)] ) , (letrec X#6= (letrec {X#7=T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10) ;E#8 in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#7.[.])), (T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (\ X#7.S#10) T#17);E#8} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#8}, A#16 |-> [.], T#13 |-> (app (\ X#7.S#10) T#17), S#9 |-> T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(app (\ X#7.S#10) T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#8} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=(app (\ X#7.S#10) T#17[(letrec {E#2} in T#5[S#3])]);E#8} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (\ X#7.S#10) T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#8} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=(letrec {X#7=T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10);E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {E#2} in T#5[S#3])])] ;E#8 ;EE#18[X#17,(app (\ X#7.S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#8 ;EE#18[X#17,(letrec {X#7=S#9} in S#10)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#6, E#15 |-> {E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {E#2} in T#5[S#3])])];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#17,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#17,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#2} in T#5[S#3])])] ;E#8 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(app (\ X#7.S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#8 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(letrec {X#7=S#9} in S#10)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#2} in T#5[S#3])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#19[X#6,(var X#17)];EE#20[X#18,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (\ X#7.S#10) T#21[(letrec {E#2} in T#5[S#3])])] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {X#7=T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10)] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#19} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#7.[.])), (T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (\ X#7.S#10) T#21)];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#8;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (\ X#7.S#10) T#21)], T#20 |-> (app (\ X#7.S#10) T#21), S#9 |-> T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#17=A#19[(app (\ X#7.S#10) T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app (\ X#7.S#10) T#21[(letrec {E#2} in T#5[S#3])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (\ X#7.S#10) T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=A#19[(letrec {X#7=T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10)];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {E#2} in T#5[S#3])])] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(app A#20[(letrec {X#7=S#9} in S#10)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21)];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#8;EE#18[X#6,(var X#17)]}, T#13 |-> A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {E#2} in T#5[S#3])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (\ X#7.S#10) S#9)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=A#19[(app A#20[(letrec {X#7=S#9} in S#10)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (\ X#7.S#10) T#19[(letrec {E#2} in T#5[S#3])]) ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {X#7=T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10) ;E#8 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(\ X#7.[.])), (T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {X#7=[.]} in S#10)), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (\ X#7.S#10) T#19);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#8;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (\ X#7.S#10) T#19), S#9 |-> T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#17=(app (\ X#7.S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=(app (\ X#7.S#10) T#19[(letrec {E#2} in T#5[S#3])]);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (\ X#7.S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {X#17=(letrec {X#7=T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} in S#10);E#8;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec E#13 ;EE#12[X#6,(app (\ X#7.S#10) S#9)] in A#14[(app A#15[(var X#6)] T#16[S#3])] ) , (letrec X#1= S#3 ;E#13 ;EE#12[X#6,(letrec {X#7=S#9} in S#10)] in A#14[(app A#15[(var X#6)] T#16[(var X#1)])] ) ) where Delta1 = {A#11,T#5} Delta2 = {E#2} Delta3 = {((var X#1),A#14[(app A#15[(var X#6)] T#16)]), (S#3,A#14[(app A#15[(var X#6)] T#16)]), ((letrec {E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#1),A#14[(app A#15[(var X#6)] T#16[[.]])]), ((var X#6),A#14[(app A#15[[.]] T#16[(var X#1)])]), ((var X#6),A#14[(app A#15[[.]] T#16[(var X#1)])])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], E#8 |-> {X#1=S#3;E#13}, E#2 |-> {E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]}, T#5 |-> A#14[(app A#15[(var X#6)] T#16)], A#11 |-> A#14[(app A#15 T#16[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(var X#1)])]) <-ucp1- (letrec {E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[S#3])]) ................................................................................ (letrec {X#1=S#3;E#13;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(var X#1)])]) -SR,lbeta3-> (letrec {X#1=S#3;E#13;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#14[(app A#15[(var X#6)] T#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#14[A#13[(app (\ X#7.S#10) S#9)]]) , (letrec {X#6=A#13[(letrec {X#7=S#9} in S#10)];E#8} in A#14[(var X#6)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#8,E#2} Delta3 = {((var X#6),A#14[[.]]), (A#13[(app (\ X#7.S#10) S#9)],A#14[[.]]), ((letrec {E#8} in A#14[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(app (\ X#7.S#10) S#9)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(app (\ X#7.S#10) S#9)], E#2 |-> {E#8}, A#11 |-> A#14, T#5 |-> A#14[[.]], T#15 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(app (\ X#7.S#10) S#9)];E#8} in A#14[(var X#6)]) <-ucp1- (letrec {E#8} in A#14[A#13[(app (\ X#7.S#10) S#9)]]) ................................................................................ (letrec {X#6=A#13[(app (\ X#7.S#10) S#9)];E#8} in A#14[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#13[(letrec {X#7=S#9} in S#10)];E#8} in A#14[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#14[A#13[(app (\ X#7.S#10) S#9)]]) , (letrec {X#6=A#13[(letrec {X#7=S#9} in S#10)];E#8} in A#14[(var X#6)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#8,E#2} Delta3 = {((var X#6),A#14), (A#13[(app (\ X#7.S#10) S#9)],A#14), ((letrec {E#8} in A#14[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(app (\ X#7.S#10) S#9)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(app (\ X#7.S#10) S#9)], E#2 |-> {E#8}, A#11 |-> A#14[[.]], T#5 |-> A#14, A#15 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(app (\ X#7.S#10) S#9)];E#8} in A#14[(var X#6)]) <-ucp1- (letrec {E#8} in A#14[A#13[(app (\ X#7.S#10) S#9)]]) ................................................................................ (letrec {X#6=A#13[(app (\ X#7.S#10) S#9)];E#8} in A#14[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#13[(letrec {X#7=S#9} in S#10)];E#8} in A#14[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#13[(app (\ X#7.S#10) S#9)]) , (letrec {X#6=A#13[(letrec {X#7=S#9} in S#10)];E#8} in (var X#6)) ) where Delta1 = {} Delta2 = {E#8,E#2} Delta3 = {((var X#6),[.]), (A#13[(app (\ X#7.S#10) S#9)],[.]), ((letrec {E#8} in (dummy3 )),(letrec {X#6=(dummy3 )} in [.])), (A#13[(app (\ X#7.S#10) S#9)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(app (\ X#7.S#10) S#9)], E#2 |-> {E#8}, T#5 |-> [.], A#11 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(app (\ X#7.S#10) S#9)];E#8} in (var X#6)) <-ucp1- (letrec {E#8} in A#13[(app (\ X#7.S#10) S#9)]) ................................................................................ (letrec {X#6=A#13[(app (\ X#7.S#10) S#9)];E#8} in (var X#6)) -SR,lbeta3-> (letrec {X#6=A#13[(letrec {X#7=S#9} in S#10)];E#8} in (var X#6)) ================================================================================ Critical Pair: ( (letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[A#13[(var X#14)]]) , (letrec X#6= A#13[(var X#14)] ;E#8 ;EE#15[X#14,(letrec {X#7=S#9} in S#10)] in A#16[(var X#6)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2} Delta3 = {((var X#6),A#16[[.]]), (A#13[(var X#14)],A#16[[.]]), ((letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(var X#14)], E#2 |-> {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]}, A#11 |-> A#16, T#5 |-> A#16[[.]], T#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) <-ucp1- (letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[A#13[(var X#14)]]) ................................................................................ (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(letrec {X#7=S#9} in S#10)]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[A#13[(var X#14)]]) , (letrec X#6= A#13[(var X#14)] ;E#8 ;EE#15[X#14,(letrec {X#7=S#9} in S#10)] in A#16[(var X#6)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2} Delta3 = {((var X#6),A#16), (A#13[(var X#14)],A#16), ((letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(var X#14)], E#2 |-> {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]}, A#11 |-> A#16[[.]], T#5 |-> A#16, A#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) <-ucp1- (letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[A#13[(var X#14)]]) ................................................................................ (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#16[(var X#6)]) -SR,lbeta3-> (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(letrec {X#7=S#9} in S#10)]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#13[(var X#14)]) , (letrec X#6= A#13[(var X#14)] ;E#8 ;EE#15[X#14,(letrec {X#7=S#9} in S#10)] in (var X#6) ) ) where Delta1 = {} Delta2 = {E#2} Delta3 = {((var X#6),[.]), (A#13[(var X#14)],[.]), ((letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in (dummy3 )),(letrec {X#6=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)), ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)]) -SR,lbeta3-> (letrec {E#8;EE#12[X#6,(letrec {X#7=S#9} in S#10)]} in A#11[(var X#6)]) and constraints: (S#9,(\ X#7.[.])), (S#9,(letrec {X#7=[.]} in S#10)) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#8;EE#12[X#6,(app (\ X#7.S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(\ X#7.[.])),(S#9,(letrec {X#7=[.]} in S#10)),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(var X#14)], E#2 |-> {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]}, T#5 |-> [.], A#11 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in (var X#6)) <-ucp1- (letrec {E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in A#13[(var X#14)]) ................................................................................ (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(app (\ X#7.S#10) S#9)]} in (var X#6)) -SR,lbeta3-> (letrec {X#6=A#13[(var X#14)];E#8;EE#15[X#14,(letrec {X#7=S#9} in S#10)]} in (var X#6)) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#9) ;E#8 in A#12[(app A#13[(var X#6)] T#14[(letrec {E#2} in T#5[S#3])])] ) , (letrec X#6= (\ X#7.S#9) ;E#8 in A#12[(app A#13[(\ X#7.S#9)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14)]), T#11 |-> A#12[(app A#13[(var X#6)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#12[(app A#13[(\ X#7.S#9)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {E#2} in T#5[S#3])] ;X#6= (\ X#7.S#9) ;E#14 in A#10[(var X#6)] ) , (letrec X#12= T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= (\ X#7.S#9) ;E#14 in A#10[(\ X#7.S#9)] ) ) where Delta1 = {T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]), E#8 |-> {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14}, E#13 |-> {X#6=(\ X#7.S#9);E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]) <-ucp1- (letrec {X#12=T#11[(letrec {E#2} in T#5[S#3])];X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#9);E#14} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#9);E#14} in A#10[(\ X#7.S#9)]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#11[(\ X#7.S#9)]) , (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(\ X#7.S#9)]) ) where Delta1 = {A#10,T#5,A#11} Delta2 = {E#8,E#2} Delta3 = {((var X#6),A#11[[.]]), ((\ X#7.S#9),A#11[[.]]), ((letrec {E#8} in A#11[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), ((\ X#7.S#9),(letrec {X#6=(dummy3 )} in [.])), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], X#1 |-> X#6, S#3 |-> (\ X#7.S#9), E#2 |-> {E#8}, A#10 |-> A#11, T#5 |-> A#11[[.]], T#12 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(var X#6)]) <-ucp1- (letrec {E#8} in A#11[(\ X#7.S#9)]) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(\ X#7.S#9)]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#11[(\ X#7.S#9)]) , (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(\ X#7.S#9)]) ) where Delta1 = {A#10,T#5,A#11} Delta2 = {E#8,E#2} Delta3 = {((var X#6),A#11), ((\ X#7.S#9),A#11), ((letrec {E#8} in A#11[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), ((\ X#7.S#9),(letrec {X#6=(dummy3 )} in [.])), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], X#1 |-> X#6, S#3 |-> (\ X#7.S#9), E#2 |-> {E#8}, A#10 |-> A#11[[.]], T#5 |-> A#11, A#12 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(var X#6)]) <-ucp1- (letrec {E#8} in A#11[(\ X#7.S#9)]) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#11[(\ X#7.S#9)]) ================================================================================ Critical Pair: ( (letrec {E#8} in (\ X#7.S#9)) , (letrec {X#6=(\ X#7.S#9);E#8} in (\ X#7.S#9)) ) where Delta1 = {} Delta2 = {E#8,E#2} Delta3 = {((var X#6),[.]), ((\ X#7.S#9),[.]), ((letrec {E#8} in (dummy3 )),(letrec {X#6=(dummy3 )} in [.])), ((\ X#7.S#9),(letrec {X#6=(dummy3 )} in [.])), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], X#1 |-> X#6, S#3 |-> (\ X#7.S#9), E#2 |-> {E#8}, T#5 |-> [.], A#10 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(\ X#7.S#9);E#8} in (var X#6)) <-ucp1- (letrec {E#8} in (\ X#7.S#9)) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in (var X#6)) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in (\ X#7.S#9)) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[S#3])]) , (letrec X#1= S#3 ;X#6= (\ X#7.S#9) ;E#11 in A#12[(app A#13[(\ X#7.S#9)] T#14[(var X#1)])] ) ) where Delta1 = {A#10,T#5} Delta2 = {E#2} Delta3 = {((var X#1),A#12[(app A#13[(var X#6)] T#14)]), (S#3,A#12[(app A#13[(var X#6)] T#14)]), ((letrec {X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),A#12[(app A#13[(var X#6)] T#14[[.]])]), ((var X#6),A#12[(app A#13[[.]] T#14[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)]) -SR,cp-in1-> (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(\ X#7.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], E#8 |-> {X#1=S#3;E#11}, E#2 |-> {X#6=(\ X#7.S#9);E#11}, T#5 |-> A#12[(app A#13[(var X#6)] T#14)], A#10 |-> A#12[(app A#13 T#14[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[(var X#1)])]) <-ucp1- (letrec {X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[S#3])]) ................................................................................ (letrec {X#1=S#3;X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[(var X#1)])]) -SR,cp-in1-> (letrec {X#1=S#3;X#6=(\ X#7.S#9);E#11} in A#12[(app A#13[(\ X#7.S#9)] T#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#9 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(var X#8)] T#16[(letrec {E#2} in T#5[S#3])])] ) , (letrec X#6= (\ X#7.S#10) ;E#9 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(\ X#7.S#10)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16)]), T#13 |-> A#14[(app A#15[(var X#8)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(\ X#7.S#10)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#2} in T#5[S#3])] ;X#6= (\ X#7.S#10) ;E#16 ;VV#12|X#8,(var X#6)| in A#11[(var X#8)] ) , (letrec X#14= T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= (\ X#7.S#10) ;E#16 ;VV#12|X#8,(var X#6)| in A#11[(\ X#7.S#10)] ) ) where Delta1 = {T#4} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#11[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]), E#9 |-> {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16}, E#15 |-> {X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) <-ucp1- (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#10);E#16;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#13 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(var X#8)] T#16[S#3])] ) , (letrec X#1= S#3 ;X#6= (\ X#7.S#10) ;E#13 ;VV#12|X#8,(var X#6)| in A#14[(app A#15[(\ X#7.S#10)] T#16[(var X#1)])] ) ) where Delta1 = {A#11,T#5} Delta2 = {E#2} Delta3 = {((var X#1),A#14[(app A#15[(var X#8)] T#16)]), (S#3,A#14[(app A#15[(var X#8)] T#16)]), ((letrec {X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),A#14[(app A#15[(var X#8)] T#16[[.]])]), ((var X#6),[.]), ((var X#8),A#14[(app A#15[[.]] T#16[(var X#1)])]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], E#9 |-> {X#1=S#3;E#13}, E#2 |-> {X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|}, T#5 |-> A#14[(app A#15[(var X#8)] T#16)], A#11 |-> A#14[(app A#15 T#16[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(var X#1)])]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[S#3])]) ................................................................................ (letrec {X#1=S#3;X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(var X#8)] T#16[(var X#1)])]) -SR,cp-in2-> (letrec {X#1=S#3;X#6=(\ X#7.S#10);E#13;VV#12|X#8,(var X#6)|} in A#14[(app A#15[(\ X#7.S#10)] T#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9} in A#14[(var X#6)]) , (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#2} Delta3 = {((var X#8),A#14[[.]]), ((var X#6),A#14[[.]]), ((letrec {X#6=(\ X#7.S#10);E#9} in A#14[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), ((var X#6),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#14[[.]]), ((var X#6),[.]), ((var X#8),A#14[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, S#3 |-> (var X#6), E#2 |-> {X#6=(\ X#7.S#10);E#9}, A#11 |-> A#14, T#5 |-> A#14[[.]], T#15 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9} in A#14[(var X#6)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9} in A#14[(var X#6)]) , (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#2} Delta3 = {((var X#8),A#14), ((var X#6),A#14), ((letrec {X#6=(\ X#7.S#10);E#9} in A#14[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), ((var X#6),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#14[[.]]), ((var X#6),[.]), ((var X#8),A#14[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, S#3 |-> (var X#6), E#2 |-> {X#6=(\ X#7.S#10);E#9}, A#11 |-> A#14[[.]], T#5 |-> A#14, A#15 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9} in A#14[(var X#6)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in A#14[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9} in (var X#6)) , (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (\ X#7.S#10)) ) where Delta1 = {} Delta2 = {E#2} Delta3 = {((var X#8),[.]), ((var X#6),[.]), ((letrec {X#6=(\ X#7.S#10);E#9} in (dummy3 )),(letrec {X#8=(dummy3 )} in [.])), ((var X#6),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#8, S#3 |-> (var X#6), E#2 |-> {X#6=(\ X#7.S#10);E#9}, T#5 |-> [.], A#11 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (var X#8)) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9} in (var X#6)) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (var X#8)) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#6);E#9} in (\ X#7.S#10)) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#14)]) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(\ X#7.S#10)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2} Delta3 = {((var X#8),A#16[[.]]), ((var X#14),A#16[[.]]), ((letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in A#16[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), ((var X#14),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#16[[.]]), ((var X#6),[.]), ((var X#8),A#16[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, S#3 |-> (var X#14), E#2 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, A#11 |-> A#16, T#5 |-> A#16[[.]], T#17 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#14)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#14)]) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in A#16[(\ X#7.S#10)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2} Delta3 = {((var X#8),A#16), ((var X#14),A#16), ((letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in A#16[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), ((var X#14),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#16[[.]]), ((var X#6),[.]), ((var X#8),A#16[[.]]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, S#3 |-> (var X#14), E#2 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, A#11 |-> A#16[[.]], T#5 |-> A#16, A#17 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#14)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in A#16[(\ X#7.S#10)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in (var X#14)) , (letrec X#6= (\ X#7.S#10) ;X#8= (var X#14) ;E#9 ;VV#15|X#14,(var X#6)| in (\ X#7.S#10) ) ) where Delta1 = {} Delta2 = {E#2} Delta3 = {((var X#8),[.]), ((var X#14),[.]), ((letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in (dummy3 )),(letrec {X#8=(dummy3 )} in [.])), ((var X#14),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)]) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(\ X#7.S#10)]) and constraints: and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;VV#12|X#8,(var X#6)|} in A#11[(var X#8)])} Delta1= {} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#11[[.]]),((var X#6),[.])} and found solution: Sol = {T#4 |-> [.], VV#12|.1,.2| |-> {[.1]=(var X#14);VV#15|X#14,[.2]|}, X#1 |-> X#8, S#3 |-> (var X#14), E#2 |-> {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|}, T#5 |-> [.], A#11 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (var X#8)) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;VV#15|X#14,(var X#6)|} in (var X#14)) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (var X#8)) -SR,cp-in2-> (letrec {X#6=(\ X#7.S#10);X#8=(var X#14);E#9;VV#15|X#14,(var X#6)|} in (\ X#7.S#10)) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#9 ;EE#13[X#8,A#11[(var X#6)]] in A#15[(app A#16[(var X#8)] T#17[(letrec {E#2} in T#5[S#3])])] ) , (letrec X#6= (\ X#7.S#10) ;E#9 ;EE#13[X#8,A#11[(\ X#7.S#10)]] in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#12,T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#8),A#15[(app A#16[[.]] T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17)]), T#14 |-> A#15[(app A#16[(var X#8)] T#17)], A#12 |-> A#15[(app A#16 T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#15[(app A#16[(var X#8)] T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#15= T#14[(letrec {E#2} in T#5[S#3])] ;X#6= (\ X#7.S#10) ;E#17 ;EE#13[X#8,A#11[(var X#6)]] in A#12[(var X#8)] ) , (letrec X#15= T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= (\ X#7.S#10) ;E#17 ;EE#13[X#8,A#11[(\ X#7.S#10)]] in A#12[(var X#8)] ) ) where Delta1 = {T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#15=T#14;X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]), E#9 |-> {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#17}, E#16 |-> {X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]}} and instantiated rules: (letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) <-ucp1- (letrec {X#15=T#14[(letrec {E#2} in T#5[S#3])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) ................................................................................ (letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#10);E#17;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {E#2} in T#5[S#3])])]] ;E#9 in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#18[A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]] ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#19,A#17,T#14,T#4,A#11,A#18} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#20[(app A#21[[.]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22)]];E#9} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[[.2]]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9}, A#17 |-> A#18, T#14 |-> A#18[A#20[(app A#21[(var X#6)] T#22)]], T#19 |-> A#20[(app A#21[(var X#6)] T#22)], A#11 |-> A#20[(app A#21 T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];E#9} in A#12[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {E#2} in T#5[S#3])])]];E#9} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];E#9} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {E#2} in T#5[S#3])])] ;E#9 in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[A#11[(\ X#7.S#10)]] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20)];E#9} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9}, T#14 |-> A#18[(app A#19[A#11[(var X#6)]] T#20)], A#17 |-> A#18[(app A#19 T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#12[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {E#2} in T#5[S#3])])];E#9} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(var X#6)]] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[A#11[(\ X#7.S#10)]] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[(var X#6)] T#20[(letrec {E#2} in T#5[S#3])])] ;E#9 in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#18[(app A#19[(\ X#7.S#10)] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#18[(app A#19[[.]] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20)];E#9} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9}, A#17 |-> [.], T#14 |-> A#18[(app A#19[(var X#6)] T#20)], A#11 |-> A#18[(app A#19 T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#12[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20[(letrec {E#2} in T#5[S#3])])];E#9} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(var X#6)] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#18[(app A#19[(\ X#7.S#10)] T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {E#2} in T#5[S#3])])] ;E#9 ;EE#19[X#18,A#11[(var X#6)]] in A#12[(var X#8)] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#9 ;EE#19[X#18,A#11[(\ X#7.S#10)]] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22)];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#19[X#18,[.2]]}, X#15 |-> X#8, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#18,A#11[(var X#6)]]}, T#14 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {E#2} in T#5[S#3])])];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#19[X#18,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#20[(app A#21[(var X#18)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#19[X#18,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {E#2} in T#5[S#3])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,A#11[(var X#6)]] in A#12[(var X#8)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#20[X#8,(var X#18)] ;EE#21[X#19,A#11[(\ X#7.S#10)]] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24)];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]}, T#14 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]) <-ucp1- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {E#2} in T#5[S#3])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#20[X#8,(var X#18)];EE#21[X#19,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {E#2} in T#5[S#3])])]] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[A#22[(app A#23[(\ X#7.S#10)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {T#21,A#17,T#14,T#4,A#11,A#20} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#22[(app A#23[[.]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24)]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]}, A#17 |-> A#20, T#14 |-> A#20[A#22[(app A#23[(var X#6)] T#24)]], T#21 |-> A#22[(app A#23[(var X#6)] T#24)], A#11 |-> A#22[(app A#23 T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-ucp1- (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {E#2} in T#5[S#3])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[A#22[(app A#23[(var X#6)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(app A#23[(\ X#7.S#10)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {E#2} in T#5[S#3])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[A#11[(\ X#7.S#10)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {A#17,T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22)];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]}, T#14 |-> A#20[(app A#21[A#11[(var X#6)]] T#22)], A#17 |-> A#20[(app A#21 T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-ucp1- (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {E#2} in T#5[S#3])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[A#11[(var X#6)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[A#11[(\ X#7.S#10)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#6)] T#22[(letrec {E#2} in T#5[S#3])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) , (letrec X#18= A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= (\ X#7.S#10) ;E#9 ;EE#19[X#8,(var X#18)] in A#12[(var X#8)] ) ) where Delta1 = {T#14,T#4,A#11} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#20[(app A#21[[.]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#18=A#20[(app A#21[(var X#6)] T#22)];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]), EE#13[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#15 |-> X#18, E#16 |-> {X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]}, A#17 |-> [.], T#14 |-> A#20[(app A#21[(var X#6)] T#22)], A#11 |-> A#20[(app A#21 T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) <-ucp1- (letrec {X#18=A#20[(app A#21[(var X#6)] T#22[(letrec {E#2} in T#5[S#3])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#6)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[(\ X#7.S#10)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#10);E#9;EE#19[X#8,(var X#18)]} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#14 ;EE#13[X#8,A#11[(var X#6)]] in A#15[(app A#16[(var X#8)] T#17[S#3])] ) , (letrec X#1= S#3 ;X#6= (\ X#7.S#10) ;E#14 ;EE#13[X#8,A#11[(\ X#7.S#10)]] in A#15[(app A#16[(var X#8)] T#17[(var X#1)])] ) ) where Delta1 = {A#12,T#5,A#11} Delta2 = {E#2} Delta3 = {((var X#1),A#15[(app A#16[(var X#8)] T#17)]), (S#3,A#15[(app A#16[(var X#8)] T#17)]), ((letrec {X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),A#15[(app A#16[(var X#8)] T#17[[.]])]), ((var X#6),A#11[[.]]), ((var X#8),A#15[(app A#16[[.]] T#17[(var X#1)])]), ((var X#8),A#15[(app A#16[[.]] T#17[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], E#9 |-> {X#1=S#3;E#14}, E#2 |-> {X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]}, T#5 |-> A#15[(app A#16[(var X#8)] T#17)], A#12 |-> A#15[(app A#16 T#17[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(var X#1)])]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[S#3])]) ................................................................................ (letrec {X#1=S#3;X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(var X#6)]]} in A#15[(app A#16[(var X#8)] T#17[(var X#1)])]) -SR,cp-e1-> (letrec {X#1=S#3;X#6=(\ X#7.S#10);E#14;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#15[(app A#16[(var X#8)] T#17[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9} in A#15[A#14[A#11[(var X#6)]]]) , (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(\ X#7.S#10)]];E#9} in A#15[(var X#8)]) ) where Delta1 = {A#12,T#5,A#11,A#15} Delta2 = {E#2} Delta3 = {((var X#8),A#15[[.]]), (A#14[A#11[(var X#6)]],A#15[[.]]), ((letrec {X#6=(\ X#7.S#10);E#9} in A#15[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#14[A#11[(var X#6)]],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#15[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#15[[.]]), ((var X#8),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=A#14[[.2]]}, X#1 |-> X#8, S#3 |-> A#14[A#11[(var X#6)]], E#2 |-> {X#6=(\ X#7.S#10);E#9}, A#12 |-> A#15, T#5 |-> A#15[[.]], T#16 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(var X#6)]];E#9} in A#15[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9} in A#15[A#14[A#11[(var X#6)]]]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(var X#6)]];E#9} in A#15[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(\ X#7.S#10)]];E#9} in A#15[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9} in A#15[A#14[A#11[(var X#6)]]]) , (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(\ X#7.S#10)]];E#9} in A#15[(var X#8)]) ) where Delta1 = {A#12,T#5,A#11,A#15} Delta2 = {E#2} Delta3 = {((var X#8),A#15), (A#14[A#11[(var X#6)]],A#15), ((letrec {X#6=(\ X#7.S#10);E#9} in A#15[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#14[A#11[(var X#6)]],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#15[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#15[[.]]), ((var X#8),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=A#14[[.2]]}, X#1 |-> X#8, S#3 |-> A#14[A#11[(var X#6)]], E#2 |-> {X#6=(\ X#7.S#10);E#9}, A#12 |-> A#15[[.]], T#5 |-> A#15, A#16 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(var X#6)]];E#9} in A#15[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9} in A#15[A#14[A#11[(var X#6)]]]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(var X#6)]];E#9} in A#15[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(\ X#7.S#10)]];E#9} in A#15[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9} in A#14[A#11[(var X#6)]]) , (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(\ X#7.S#10)]];E#9} in (var X#8)) ) where Delta1 = {A#11} Delta2 = {E#2} Delta3 = {((var X#8),[.]), (A#14[A#11[(var X#6)]],[.]), ((letrec {X#6=(\ X#7.S#10);E#9} in (dummy3 )),(letrec {X#8=(dummy3 )} in [.])), (A#14[A#11[(var X#6)]],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#6),A#11[[.]]), ((var X#8),[.]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=A#14[[.2]]}, X#1 |-> X#8, S#3 |-> A#14[A#11[(var X#6)]], E#2 |-> {X#6=(\ X#7.S#10);E#9}, T#5 |-> [.], A#12 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(var X#6)]];E#9} in (var X#8)) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9} in A#14[A#11[(var X#6)]]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(var X#6)]];E#9} in (var X#8)) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#14[A#11[(\ X#7.S#10)]];E#9} in (var X#8)) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#9 ;EE#16[X#15,A#11[(var X#6)]] in A#17[A#14[(var X#15)]] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#14[(var X#15)] ;E#9 ;EE#16[X#15,A#11[(\ X#7.S#10)]] in A#17[(var X#8)] ) ) where Delta1 = {A#12,T#5,A#11,A#17} Delta2 = {E#2} Delta3 = {((var X#8),A#17[[.]]), (A#14[(var X#15)],A#17[[.]]), ((letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#14[(var X#15)],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#17[[.]]), ((var X#8),A#17[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=A#14[(var X#15)];EE#16[X#15,[.2]]}, X#1 |-> X#8, S#3 |-> A#14[(var X#15)], E#2 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]}, A#12 |-> A#17, T#5 |-> A#17[[.]], T#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[A#14[(var X#15)]]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(\ X#7.S#10)]]} in A#17[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#10) ;E#9 ;EE#16[X#15,A#11[(var X#6)]] in A#17[A#14[(var X#15)]] ) , (letrec X#6= (\ X#7.S#10) ;X#8= A#14[(var X#15)] ;E#9 ;EE#16[X#15,A#11[(\ X#7.S#10)]] in A#17[(var X#8)] ) ) where Delta1 = {A#12,T#5,A#11,A#17} Delta2 = {E#2} Delta3 = {((var X#8),A#17), (A#14[(var X#15)],A#17), ((letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#14[(var X#15)],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[[.]]), ((var X#6),A#11[[.]]), ((var X#8),A#17[[.]]), ((var X#8),A#17[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=A#14[(var X#15)];EE#16[X#15,[.2]]}, X#1 |-> X#8, S#3 |-> A#14[(var X#15)], E#2 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]}, A#12 |-> A#17[[.]], T#5 |-> A#17, A#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[A#14[(var X#15)]]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(var X#6)]]} in A#17[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(\ X#7.S#10)]]} in A#17[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in A#14[(var X#15)]) , (letrec X#6= (\ X#7.S#10) ;X#8= A#14[(var X#15)] ;E#9 ;EE#16[X#15,A#11[(\ X#7.S#10)]] in (var X#8) ) ) where Delta1 = {A#11} Delta2 = {E#2} Delta3 = {((var X#8),[.]), (A#14[(var X#15)],[.]), ((letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in (dummy3 )),(letrec {X#8=(dummy3 )} in [.])), (A#14[(var X#15)],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#6),A#11[[.]]), ((var X#8),[.]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)]) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(\ X#7.S#10)]]} in A#12[(var X#8)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#10);E#9;EE#13[X#8,A#11[(var X#6)]]} in A#12[(var X#8)])} Delta1= {A#11} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#4 |-> [.], EE#13[.1,.2] |-> {[.1]=A#14[(var X#15)];EE#16[X#15,[.2]]}, X#1 |-> X#8, S#3 |-> A#14[(var X#15)], E#2 |-> {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]}, T#5 |-> [.], A#12 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(var X#6)]]} in (var X#8)) <-ucp1- (letrec {X#6=(\ X#7.S#10);E#9;EE#16[X#15,A#11[(var X#6)]]} in A#14[(var X#15)]) ................................................................................ (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(var X#6)]]} in (var X#8)) -SR,cp-e1-> (letrec {X#6=(\ X#7.S#10);X#8=A#14[(var X#15)];E#9;EE#16[X#15,A#11[(\ X#7.S#10)]]} in (var X#8)) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] T#19[(letrec {E#2} in T#5[S#3])])] ) , (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#13,T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19)]), T#16 |-> A#17[(app A#18[(var X#8)] T#19)], A#13 |-> A#17[(app A#18 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {E#2} in T#5[S#3])] ;X#6= (\ X#7.S#11) ;E#19 ;EE#14[X#8,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#17= T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= (\ X#7.S#11) ;E#19 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=T#16;X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), E#10 |-> {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19}, E#18 |-> {X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#17=T#16[(letrec {E#2} in T#5[S#3])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(\ X#7.S#11);E#19;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {E#2} in T#5[S#3])])]] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#20[A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#21,A#19,T#16,T#4,A#12,A#20} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#22[(app A#23[[.]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24)]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, A#19 |-> A#20, T#16 |-> A#20[A#22[(app A#23[(var X#9)] T#24)]], T#21 |-> A#22[(app A#23[(var X#9)] T#24)], A#12 |-> A#22[(app A#23 T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {E#2} in T#5[S#3])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {E#2} in T#5[S#3])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[A#12[(\ X#7.S#11)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22)];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, T#16 |-> A#20[(app A#21[A#12[(var X#9)]] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {E#2} in T#5[S#3])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(var X#9)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[A#12[(\ X#7.S#11)]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[(var X#9)] T#22[(letrec {E#2} in T#5[S#3])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#20[(app A#21[(\ X#7.S#11)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#10 ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#20[(app A#21[[.]] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22)];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, A#19 |-> [.], T#16 |-> A#20[(app A#21[(var X#9)] T#22)], A#12 |-> A#20[(app A#21 T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22[(letrec {E#2} in T#5[S#3])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(var X#9)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#20[(app A#21[(\ X#7.S#11)] T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;X#8= A#22[(app A#23[(var X#20)] T#24[(letrec {E#2} in T#5[S#3])])] ;E#10 ;EE#21[X#20,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#10 ;EE#21[X#20,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24)];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#21[X#20,[.2]]}, X#17 |-> X#8, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {E#2} in T#5[S#3])])];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;EE#21[X#20,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#10;EE#21[X#20,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {E#2} in T#5[S#3])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#22[X#8,(var X#20)] ;EE#23[X#21,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#22[X#8,(var X#20)] ;EE#23[X#21,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {E#2} in T#5[S#3])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#22[X#8,(var X#20)];EE#23[X#21,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {E#2} in T#5[S#3])])]] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#22[A#24[(app A#25[(\ X#7.S#11)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#23,A#19,T#16,T#4,A#12,A#22} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#24[(app A#25[[.]] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26)]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|}, A#19 |-> A#22, T#16 |-> A#22[A#24[(app A#25[(var X#9)] T#26)]], T#23 |-> A#24[(app A#25[(var X#9)] T#26)], A#12 |-> A#24[(app A#25 T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {E#2} in T#5[S#3])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#22[A#24[(app A#25[(var X#9)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#22[A#24[(app A#25[(\ X#7.S#11)] T#26[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {E#2} in T#5[S#3])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#22[(app A#23[A#12[(\ X#7.S#11)]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {A#19,T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24)];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|}, T#16 |-> A#22[(app A#23[A#12[(var X#9)]] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {E#2} in T#5[S#3])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#22[(app A#23[A#12[(var X#9)]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#22[(app A#23[A#12[(\ X#7.S#11)]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#9)] T#24[(letrec {E#2} in T#5[S#3])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) , (letrec X#20= A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= (\ X#7.S#11) ;E#10 ;EE#21[X#8,(var X#20)] ;VV#15|X#9,(var X#6)| in A#13[(var X#8)] ) ) where Delta1 = {T#16,T#4,A#12} Delta2 = {E#2} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#8),A#13[[.]]), ((var X#9),A#22[(app A#23[[.]] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),[.]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#20=A#22[(app A#23[(var X#9)] T#24)];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|}, A#19 |-> [.], T#16 |-> A#22[(app A#23[(var X#9)] T#24)], A#12 |-> A#22[(app A#23 T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) <-ucp1- (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {E#2} in T#5[S#3])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(var X#9)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#20=A#22[(app A#23[(\ X#7.S#11)] T#24[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(\ X#7.S#11);E#10;EE#21[X#8,(var X#20)];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#16 ;EE#14[X#8,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] T#19[S#3])] ) , (letrec X#1= S#3 ;X#6= (\ X#7.S#11) ;E#16 ;EE#14[X#8,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#17[(app A#18[(var X#8)] T#19[(var X#1)])] ) ) where Delta1 = {A#13,T#5,A#12} Delta2 = {E#2} Delta3 = {((var X#1),A#17[(app A#18[(var X#8)] T#19)]), (S#3,A#17[(app A#18[(var X#8)] T#19)]), ((letrec {X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),A#17[(app A#18[(var X#8)] T#19[[.]])]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] T#19[(var X#1)])]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[(app A#18[[.]] T#19[(var X#1)])])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], E#10 |-> {X#1=S#3;E#16}, E#2 |-> {X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, T#5 |-> A#17[(app A#18[(var X#8)] T#19)], A#13 |-> A#17[(app A#18 T#19[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(var X#1)])]) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[S#3])]) ................................................................................ (letrec {X#1=S#3;X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(var X#1)])]) -SR,cp-e2-> (letrec {X#1=S#3;X#6=(\ X#7.S#11);E#16;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#17[(app A#18[(var X#8)] T#19[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;VV#15|X#9,(var X#6)| in A#17[A#16[A#12[(var X#9)]]] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#16[A#12[(\ X#7.S#11)]] ;E#10 ;VV#15|X#9,(var X#6)| in A#17[(var X#8)] ) ) where Delta1 = {A#13,T#5,A#12,A#17} Delta2 = {E#2} Delta3 = {((var X#8),A#17[[.]]), (A#16[A#12[(var X#9)]],A#17[[.]]), ((letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in A#17[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#16[A#12[(var X#9)]],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[[.]]), ((var X#6),[.]), ((var X#8),A#17[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=A#16[[.2]]}, X#1 |-> X#8, S#3 |-> A#16[A#12[(var X#9)]], E#2 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, A#13 |-> A#17, T#5 |-> A#17[[.]], T#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(var X#9)]];E#10;VV#15|X#9,(var X#6)|} in A#17[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in A#17[A#16[A#12[(var X#9)]]]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(var X#9)]];E#10;VV#15|X#9,(var X#6)|} in A#17[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(\ X#7.S#11)]];E#10;VV#15|X#9,(var X#6)|} in A#17[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;VV#15|X#9,(var X#6)| in A#17[A#16[A#12[(var X#9)]]] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#16[A#12[(\ X#7.S#11)]] ;E#10 ;VV#15|X#9,(var X#6)| in A#17[(var X#8)] ) ) where Delta1 = {A#13,T#5,A#12,A#17} Delta2 = {E#2} Delta3 = {((var X#8),A#17), (A#16[A#12[(var X#9)]],A#17), ((letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in A#17[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#16[A#12[(var X#9)]],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[[.]]), ((var X#6),[.]), ((var X#8),A#17[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#17[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=A#16[[.2]]}, X#1 |-> X#8, S#3 |-> A#16[A#12[(var X#9)]], E#2 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, A#13 |-> A#17[[.]], T#5 |-> A#17, A#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(var X#9)]];E#10;VV#15|X#9,(var X#6)|} in A#17[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in A#17[A#16[A#12[(var X#9)]]]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(var X#9)]];E#10;VV#15|X#9,(var X#6)|} in A#17[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(\ X#7.S#11)]];E#10;VV#15|X#9,(var X#6)|} in A#17[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in A#16[A#12[(var X#9)]]) , (letrec X#6= (\ X#7.S#11) ;X#8= A#16[A#12[(\ X#7.S#11)]] ;E#10 ;VV#15|X#9,(var X#6)| in (var X#8) ) ) where Delta1 = {A#12} Delta2 = {E#2} Delta3 = {((var X#8),[.]), (A#16[A#12[(var X#9)]],[.]), ((letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in (dummy3 )),(letrec {X#8=(dummy3 )} in [.])), (A#16[A#12[(var X#9)]],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=A#16[[.2]]}, X#1 |-> X#8, S#3 |-> A#16[A#12[(var X#9)]], E#2 |-> {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|}, T#5 |-> [.], A#13 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(var X#9)]];E#10;VV#15|X#9,(var X#6)|} in (var X#8)) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;VV#15|X#9,(var X#6)|} in A#16[A#12[(var X#9)]]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(var X#9)]];E#10;VV#15|X#9,(var X#6)|} in (var X#8)) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#16[A#12[(\ X#7.S#11)]];E#10;VV#15|X#9,(var X#6)|} in (var X#8)) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#18[X#17,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#19[A#16[(var X#17)]] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#16[(var X#17)] ;E#10 ;EE#18[X#17,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#19[(var X#8)] ) ) where Delta1 = {A#13,T#5,A#12,A#19} Delta2 = {E#2} Delta3 = {((var X#8),A#19[[.]]), (A#16[(var X#17)],A#19[[.]]), ((letrec {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#16[(var X#17)],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#19[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=A#16[(var X#17)];EE#18[X#17,[.2]]}, X#1 |-> X#8, S#3 |-> A#16[(var X#17)], E#2 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, A#13 |-> A#19, T#5 |-> A#19[[.]], T#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[A#16[(var X#17)]]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#18[X#17,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#19[A#16[(var X#17)]] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#16[(var X#17)] ;E#10 ;EE#18[X#17,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in A#19[(var X#8)] ) ) where Delta1 = {A#13,T#5,A#12,A#19} Delta2 = {E#2} Delta3 = {((var X#8),A#19), (A#16[(var X#17)],A#19), ((letrec {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(dummy3 )]),(letrec {X#8=(dummy3 )} in [.])), (A#16[(var X#17)],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#19[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),A#19[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=A#16[(var X#17)];EE#18[X#17,[.2]]}, X#1 |-> X#8, S#3 |-> A#16[(var X#17)], E#2 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, A#13 |-> A#19[[.]], T#5 |-> A#19, A#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[A#16[(var X#17)]]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#19[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#6= (\ X#7.S#11) ;E#10 ;EE#18[X#17,A#12[(var X#9)]] ;VV#15|X#9,(var X#6)| in A#16[(var X#17)] ) , (letrec X#6= (\ X#7.S#11) ;X#8= A#16[(var X#17)] ;E#10 ;EE#18[X#17,A#12[(\ X#7.S#11)]] ;VV#15|X#9,(var X#6)| in (var X#8) ) ) where Delta1 = {A#12} Delta2 = {E#2} Delta3 = {((var X#8),[.]), (A#16[(var X#17)],[.]), ((letrec {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in (dummy3 )),(letrec {X#8=(dummy3 )} in [.])), (A#16[(var X#17)],(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#6),[.]), ((var X#8),[.]), ((var X#9),A#12[[.]]), ((var X#6),[.]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)]) and constraints: A#12/= [.] and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(\ X#7.S#11);E#10;EE#14[X#8,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#13[(var X#8)])} Delta1= {A#12} Delta2= {E#2} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#5[[.]]),((var X#6),[.]),((var X#8),A#13[[.]]),((var X#9),A#12[[.]]),((var X#6),[.]),((var X#8),A#13[[.]])} and found solution: Sol = {T#4 |-> [.], EE#14[.1,.2] |-> {[.1]=A#16[(var X#17)];EE#18[X#17,[.2]]}, X#1 |-> X#8, S#3 |-> A#16[(var X#17)], E#2 |-> {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|}, T#5 |-> [.], A#13 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in (var X#8)) <-ucp1- (letrec {X#6=(\ X#7.S#11);E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in A#16[(var X#17)]) ................................................................................ (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(var X#9)]];VV#15|X#9,(var X#6)|} in (var X#8)) -SR,cp-e2-> (letrec {X#6=(\ X#7.S#11);X#8=A#16[(var X#17)];E#10;EE#18[X#17,A#12[(\ X#7.S#11)]];VV#15|X#9,(var X#6)|} in (var X#8)) ================================================================================ Critical Pair: ( (letrec {E#6} in (letrec {E#7} in T#10[(letrec {E#2} in T#5[S#3])])) , (letrec {E#6;E#7} in T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) ) where Delta1 = {T#9,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), [{E#6},(letrec {E#7} in [.])], ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),[{E#6},(letrec {E#7} in [.])],((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (letrec {E#7} in T#10)), T#9 |-> (letrec {E#7} in T#10), S#8 |-> T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in (letrec {E#7} in T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) <-ucp1- (letrec {E#6} in (letrec {E#7} in T#10[(letrec {E#2} in T#5[S#3])])) ................................................................................ (letrec {E#6} in (letrec {E#7} in T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) -SR,llet-in1-> (letrec {E#6;E#7} in T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (letrec {X#11=T#10[(letrec {E#2} in T#5[S#3])];E#13} in S#8)) , (letrec {X#11=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#13;E#6} in S#8) ) where Delta1 = {T#9,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), [{E#6},(letrec {X#11=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#13} in [.])], ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),[{E#6},(letrec {E#7} in [.])],((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (letrec {X#11=T#10;E#13} in S#8)), T#9 |-> (letrec {X#11=T#10;E#13} in S#8), E#7 |-> {X#11=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {E#6} in (letrec {X#11=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#13} in S#8)) <-ucp1- (letrec {E#6} in (letrec {X#11=T#10[(letrec {E#2} in T#5[S#3])];E#13} in S#8)) ................................................................................ (letrec {E#6} in (letrec {X#11=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#13} in S#8)) -SR,llet-in1-> (letrec {X#11=T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#13;E#6} in S#8) ================================================================================ Critical Pair: ( (letrec {E#6} in (letrec {E#2} in T#5[S#3])) , (letrec {X#1=S#3;E#2;E#6} in T#5[(var X#1)]) ) where Delta1 = {T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), [{E#6},(letrec {X#1=S#3;E#2} in [.])], ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),[{E#6},(letrec {E#7} in [.])],((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in [.]), T#9 |-> [.], S#8 |-> T#5[(var X#1)], E#7 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {E#6} in (letrec {X#1=S#3;E#2} in T#5[(var X#1)])) <-ucp1- (letrec {E#6} in (letrec {E#2} in T#5[S#3])) ................................................................................ (letrec {E#6} in (letrec {X#1=S#3;E#2} in T#5[(var X#1)])) -SR,llet-in1-> (letrec {X#1=S#3;E#2;E#6} in T#5[(var X#1)]) ================================================================================ Critical Pair: ( (letrec {X#10=T#9[(letrec {E#2} in T#5[S#3])];E#12} in (letrec {E#7} in S#8)) , (letrec {X#10=T#9[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#12;E#7} in S#8) ) where Delta1 = {T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), [{X#10=T#9[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#12},(letrec {E#7} in [.])], ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),[{E#6},(letrec {E#7} in [.])],((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#10=T#9;E#12} in (letrec {E#7} in S#8)), E#6 |-> {X#10=T#9[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {X#10=T#9[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#12} in (letrec {E#7} in S#8)) <-ucp1- (letrec {X#10=T#9[(letrec {E#2} in T#5[S#3])];E#12} in (letrec {E#7} in S#8)) ................................................................................ (letrec {X#10=T#9[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#12} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {X#10=T#9[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#12;E#7} in S#8) ================================================================================ Critical Pair: ( (letrec {E#9} in (letrec {E#7} in T#10[S#3])) , (letrec {X#1=S#3;E#7;E#9} in T#10[(var X#1)]) ) where Delta1 = {T#5} Delta2 = {E#9,E#2,E#6,E#7} Delta3 = {((var X#1),(letrec {E#7} in T#10)), (S#3,(letrec {E#7} in T#10)), ((letrec {E#9} in (letrec {E#7} in T#10[(dummy3 )])),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), [{X#1=S#3;E#9},(letrec {E#7} in [.])], ((var X#1),(letrec {E#7} in T#10[[.]]))} Delta4= {} from overlapping <-SR,llet-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),[{E#6},(letrec {E#7} in [.])],((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#9}, E#2 |-> {E#9}, T#5 |-> (letrec {E#7} in T#10), S#8 |-> T#10[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#9} in (letrec {E#7} in T#10[(var X#1)])) <-ucp1- (letrec {E#9} in (letrec {E#7} in T#10[S#3])) ................................................................................ (letrec {X#1=S#3;E#9} in (letrec {E#7} in T#10[(var X#1)])) -SR,llet-in1-> (letrec {X#1=S#3;E#7;E#9} in T#10[(var X#1)]) ================================================================================ Critical Pair: ( (letrec {E#9} in (letrec {X#11=T#10[S#3];E#13} in S#8)) , (letrec {X#1=S#3;X#11=T#10[(var X#1)];E#13;E#9} in S#8) ) where Delta1 = {T#5} Delta2 = {E#9,E#2,E#6,E#7} Delta3 = {((var X#1),(letrec {X#11=T#10;E#13} in S#8)), (S#3,(letrec {X#11=T#10;E#13} in S#8)), ((letrec {E#9} in (letrec {X#11=T#10[(dummy3 )];E#13} in S#8)),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), [{X#1=S#3;E#9},(letrec {X#11=T#10[(var X#1)];E#13} in [.])], ((var X#1),(letrec {X#11=T#10[[.]];E#13} in S#8))} Delta4= {} from overlapping <-SR,llet-in1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in (letrec {E#7} in S#8)) -SR,llet-in1-> (letrec {E#6;E#7} in S#8) and constraints: E#6/= {}, E#7/= {}, ({E#6},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in (letrec {E#7} in S#8))} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),[{E#6},(letrec {E#7} in [.])],((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#9}, E#2 |-> {E#9}, T#5 |-> (letrec {X#11=T#10;E#13} in S#8), E#7 |-> {X#11=T#10[(var X#1)];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#1=S#3;E#9} in (letrec {X#11=T#10[(var X#1)];E#13} in S#8)) <-ucp1- (letrec {E#9} in (letrec {X#11=T#10[S#3];E#13} in S#8)) ................................................................................ (letrec {X#1=S#3;E#9} in (letrec {X#11=T#10[(var X#1)];E#13} in S#8)) -SR,llet-in1-> (letrec {X#1=S#3;X#11=T#10[(var X#1)];E#13;E#9} in S#8) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#7} in S#9) ;E#8 in A#12[(app A#13[(var X#6)] T#14[(letrec {E#2} in T#5[S#3])])] ) , (letrec X#6= S#9 ;E#7 ;E#8 in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])],(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#1),T#5[[.]]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),A#12[(app A#13[[.]] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14)]), T#11 |-> A#12[(app A#13[(var X#6)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#12[(app A#13[(var X#6)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#7} in T#14[(letrec {E#2} in T#5[S#3])]) ;E#8 in A#10[(var X#6)] ) , (letrec X#6= T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {T#11,T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#1),T#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#7} in T#14);E#8} in A#10[(var X#6)]), X#12 |-> X#6, E#13 |-> {E#8}, T#11 |-> (letrec {E#7} in T#14), S#9 |-> T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(letrec {E#7} in T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#8} in A#10[(var X#6)]) <-ucp1- (letrec {X#6=(letrec {E#7} in T#14[(letrec {E#2} in T#5[S#3])]);E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {E#7} in T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {X#15=T#14[(letrec {E#2} in T#5[S#3])];E#17} in S#9) ;E#8 in A#10[(var X#6)] ) , (letrec X#15= T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= S#9 ;E#17 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {T#11,T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (A#10[(var X#6)],(letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#17} in [.])), [{E#8},(letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#17} in [.])], ((var X#1),T#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {X#15=T#14;E#17} in S#9);E#8} in A#10[(var X#6)]), X#12 |-> X#6, E#13 |-> {E#8}, T#11 |-> (letrec {X#15=T#14;E#17} in S#9), E#7 |-> {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#6=(letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#17} in S#9);E#8} in A#10[(var X#6)]) <-ucp1- (letrec {X#6=(letrec {X#15=T#14[(letrec {E#2} in T#5[S#3])];E#17} in S#9);E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#17} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#15=T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=S#9;E#17;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {X#6=(letrec {E#2} in T#5[S#3]);E#8} in A#10[(var X#6)]) , (letrec {X#1=S#3;X#6=T#5[(var X#1)];E#2;E#8} in A#10[(var X#6)]) ) where Delta1 = {T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (A#10[(var X#6)],(letrec {X#1=S#3;E#2} in [.])), [{E#8},(letrec {X#1=S#3;E#2} in [.])], ((var X#1),T#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=[.];E#8} in A#10[(var X#6)]), X#12 |-> X#6, E#13 |-> {E#8}, T#11 |-> [.], S#9 |-> T#5[(var X#1)], E#7 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {X#6=(letrec {X#1=S#3;E#2} in T#5[(var X#1)]);E#8} in A#10[(var X#6)]) <-ucp1- (letrec {X#6=(letrec {E#2} in T#5[S#3]);E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {X#1=S#3;E#2} in T#5[(var X#1)]);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#1=S#3;X#6=T#5[(var X#1)];E#2;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {E#2} in T#5[S#3])] ;X#6= (letrec {E#7} in S#9) ;E#14 in A#10[(var X#6)] ) , (letrec X#12= T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= S#9 ;E#14 ;E#7 in A#10[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#2,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14},(letrec {E#7} in [.])], ((var X#1),T#5[[.]]), ((var X#6),A#10[[.]]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]), E#8 |-> {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14}, E#13 |-> {X#6=(letrec {E#7} in S#9);E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]) <-ucp1- (letrec {X#12=T#11[(letrec {E#2} in T#5[S#3])];X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(letrec {E#7} in S#9);E#14} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=S#9;E#14;E#7} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#11[(letrec {E#7} in S#9)]) , (letrec {X#6=S#9;E#7;E#8} in A#11[(var X#6)]) ) where Delta1 = {A#10,T#5,A#11} Delta2 = {E#8,E#2,E#7} Delta3 = {((var X#6),A#11[[.]]), ((letrec {E#7} in S#9),A#11[[.]]), ((letrec {E#8} in A#11[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), ((letrec {E#7} in S#9),(letrec {X#6=(dummy3 )} in [.])), (A#11[(var X#6)],(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], X#1 |-> X#6, S#3 |-> (letrec {E#7} in S#9), E#2 |-> {E#8}, A#10 |-> A#11, T#5 |-> A#11[[.]], T#12 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#11[(var X#6)]) <-ucp1- (letrec {E#8} in A#11[(letrec {E#7} in S#9)]) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#11[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#11[(letrec {E#7} in S#9)]) , (letrec {X#6=S#9;E#7;E#8} in A#11[(var X#6)]) ) where Delta1 = {A#10,T#5,A#11} Delta2 = {E#8,E#2,E#7} Delta3 = {((var X#6),A#11), ((letrec {E#7} in S#9),A#11), ((letrec {E#8} in A#11[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), ((letrec {E#7} in S#9),(letrec {X#6=(dummy3 )} in [.])), (A#11[(var X#6)],(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], X#1 |-> X#6, S#3 |-> (letrec {E#7} in S#9), E#2 |-> {E#8}, A#10 |-> A#11[[.]], T#5 |-> A#11, A#12 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#11[(var X#6)]) <-ucp1- (letrec {E#8} in A#11[(letrec {E#7} in S#9)]) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#11[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#8} in (letrec {E#7} in S#9)) , (letrec {X#6=S#9;E#7;E#8} in (var X#6)) ) where Delta1 = {} Delta2 = {E#8,E#2,E#7} Delta3 = {((var X#6),[.]), ((letrec {E#7} in S#9),[.]), ((letrec {E#8} in (dummy3 )),(letrec {X#6=(dummy3 )} in [.])), ((letrec {E#7} in S#9),(letrec {X#6=(dummy3 )} in [.])), ((var X#6),(letrec {E#7} in [.])), [{E#8},(letrec {E#7} in [.])], ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], X#1 |-> X#6, S#3 |-> (letrec {E#7} in S#9), E#2 |-> {E#8}, T#5 |-> [.], A#10 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=(letrec {E#7} in S#9);E#8} in (var X#6)) <-ucp1- (letrec {E#8} in (letrec {E#7} in S#9)) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in (var X#6)) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in (var X#6)) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#7} in S#9) ;E#11 in A#12[(app A#13[(var X#6)] T#14[S#3])] ) , (letrec X#1= S#3 ;X#6= S#9 ;E#11 ;E#7 in A#12[(app A#13[(var X#6)] T#14[(var X#1)])] ) ) where Delta1 = {A#10,T#5} Delta2 = {E#2,E#7} Delta3 = {((var X#1),A#12[(app A#13[(var X#6)] T#14)]), (S#3,A#12[(app A#13[(var X#6)] T#14)]), ((letrec {X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (A#12[(app A#13[(var X#6)] T#14[(var X#1)])],(letrec {E#7} in [.])), [{X#1=S#3;E#11},(letrec {E#7} in [.])], ((var X#1),A#12[(app A#13[(var X#6)] T#14[[.]])]), ((var X#6),A#12[(app A#13[[.]] T#14[(var X#1)])]), ((var X#6),A#12[(app A#13[[.]] T#14[(var X#1)])])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)]) -SR,llet-e1-> (letrec {X#6=S#9;E#7;E#8} in A#10[(var X#6)]) and constraints: E#7/= {}, (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#7} in S#9);E#8} in A#10[(var X#6)])} Delta1= {} Delta2= {E#2,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8},(letrec {E#7} in [.])],((var X#1),T#5[[.]]),((var X#6),A#10[[.]]),((var X#6),A#10[[.]])} and found solution: Sol = {T#4 |-> [.], E#8 |-> {X#1=S#3;E#11}, E#2 |-> {X#6=(letrec {E#7} in S#9);E#11}, T#5 |-> A#12[(app A#13[(var X#6)] T#14)], A#10 |-> A#12[(app A#13 T#14[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[(var X#1)])]) <-ucp1- (letrec {X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[S#3])]) ................................................................................ (letrec {X#1=S#3;X#6=(letrec {E#7} in S#9);E#11} in A#12[(app A#13[(var X#6)] T#14[(var X#1)])]) -SR,llet-e1-> (letrec {X#1=S#3;X#6=S#9;E#11;E#7} in A#12[(app A#13[(var X#6)] T#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;E#9 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] T#16[(letrec {E#2} in T#5[S#3])])] ) , (letrec X#6= S#10 ;E#8 ;E#9 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])],(letrec {E#8} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in T#16[(letrec {E#2} in T#5[S#3])]) ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#6= T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#8 ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in T#16);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), X#14 |-> X#6, E#15 |-> {E#9;EE#12[X#7,(var X#6)]}, T#13 |-> (letrec {E#8} in T#16), S#10 |-> T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in T#16[(letrec {E#2} in T#5[S#3])]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {E#8} in T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {X#17=T#16[(letrec {E#2} in T#5[S#3])];E#19} in S#10) ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#17= T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= S#10 ;E#19 ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {X#17=T#16;E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), X#14 |-> X#6, E#15 |-> {E#9;EE#12[X#7,(var X#6)]}, T#13 |-> (letrec {X#17=T#16;E#19} in S#10), E#8 |-> {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#6=(letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {X#17=T#16[(letrec {E#2} in T#5[S#3])];E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#19} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#17=T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=S#10;E#19;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#2} in T#5[S#3]) ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#1= S#3 ;X#6= T#5[(var X#1)] ;E#2 ;E#9 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#1=S#3;E#2;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {X#1=S#3;E#2} in [.])), [{E#9;EE#12[X#7,(var X#6)]},(letrec {X#1=S#3;E#2} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=[.];E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), X#14 |-> X#6, E#15 |-> {E#9;EE#12[X#7,(var X#6)]}, T#13 |-> [.], S#10 |-> T#5[(var X#1)], E#8 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {X#6=(letrec {X#1=S#3;E#2} in T#5[(var X#1)]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#2} in T#5[S#3]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {X#1=S#3;E#2} in T#5[(var X#1)]);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#1=S#3;X#6=T#5[(var X#1)];E#2;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#2} in T#5[S#3])] ;X#6= (letrec {E#8} in S#10) ;E#16 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) , (letrec X#14= T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;X#6= S#10 ;E#16 ;E#8 ;EE#12[X#7,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;E#8;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]), E#9 |-> {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16}, E#15 |-> {X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=(letrec {E#8} in S#10);E#16;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];X#6=S#10;E#16;E#8;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= A#17[(app A#18[(var X#6)] T#19[(letrec {E#2} in T#5[S#3])])] ;E#9 in A#11[(var X#7)] ) , (letrec X#6= S#10 ;X#7= A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#8 ;E#9 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;E#9} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19)];E#9} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]}, X#14 |-> X#7, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9}, T#13 |-> A#17[(app A#18[(var X#6)] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#11[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {E#2} in T#5[S#3])])];E#9} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#17[(app A#18[(var X#6)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;E#9} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {E#2} in T#5[S#3])])] ;E#9 ;EE#18[X#17,(var X#6)] in A#11[(var X#7)] ) , (letrec X#6= S#10 ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#8 ;E#9 ;EE#18[X#17,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;E#9;EE#18[X#17,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#18[X#17,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21)];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#18[X#17,(var X#6)]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {E#2} in T#5[S#3])])];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;E#9;EE#18[X#17,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#2} in T#5[S#3])])] ;X#6= (letrec {E#8} in S#10) ;E#9 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,(var X#6)] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= S#10 ;E#8 ;E#9 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,(var X#6)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#2} in T#5[S#3])])];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=S#10;E#8;E#9;EE#19[X#7,(var X#17)];EE#20[X#18,(var X#6)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#6)] T#21[(letrec {E#2} in T#5[S#3])])] ;X#6= (letrec {E#8} in S#10) ;E#9 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;X#6= S#10 ;E#8 ;E#9 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#8;E#9;EE#18[X#7,(var X#17)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), [{X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#9;EE#18[X#7,(var X#17)]},(letrec {E#8} in [.])], ((var X#1),T#5[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]]), ((var X#6),[.]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(var X#6)] T#21)];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[(var X#6)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-ucp1- (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {E#2} in T#5[S#3])])];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=(letrec {E#8} in S#10);E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#17=A#19[(app A#20[(var X#6)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];X#6=S#10;E#8;E#9;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;E#13 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] T#16[S#3])] ) , (letrec X#1= S#3 ;X#6= S#10 ;E#13 ;E#8 ;EE#12[X#7,(var X#6)] in A#14[(app A#15[(var X#7)] T#16[(var X#1)])] ) ) where Delta1 = {A#11,T#5} Delta2 = {E#2,E#8} Delta3 = {((var X#1),A#14[(app A#15[(var X#7)] T#16)]), (S#3,A#14[(app A#15[(var X#7)] T#16)]), ((letrec {X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), ((var X#6),(letrec {X#1=S#3;E#13;E#8;EE#12[X#7,(var X#6)]} in [.])), (A#14[(app A#15[(var X#7)] T#16[(var X#1)])],(letrec {E#8} in [.])), [{X#1=S#3;E#13;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])], ((var X#1),A#14[(app A#15[(var X#7)] T#16[[.]])]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] T#16[(var X#1)])]), ((var X#6),[.]), ((var X#7),A#14[(app A#15[[.]] T#16[(var X#1)])])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], E#9 |-> {X#1=S#3;E#13}, E#2 |-> {X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]}, T#5 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(var X#1)])]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[S#3])]) ................................................................................ (letrec {X#1=S#3;X#6=(letrec {E#8} in S#10);E#13;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(var X#1)])]) -SR,llet-e2-> (letrec {X#1=S#3;X#6=S#10;E#13;E#8;EE#12[X#7,(var X#6)]} in A#14[(app A#15[(var X#7)] T#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {X#6=(letrec {E#8} in S#10);E#9} in A#14[A#13[(var X#6)]]) , (letrec {X#6=S#10;X#7=A#13[(var X#6)];E#8;E#9} in A#14[(var X#7)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#2,E#8} Delta3 = {((var X#7),A#14[[.]]), (A#13[(var X#6)],A#14[[.]]), ((letrec {X#6=(letrec {E#8} in S#10);E#9} in A#14[(dummy3 )]),(letrec {X#7=(dummy3 )} in [.])), (A#13[(var X#6)],(letrec {X#7=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#13[(var X#6)];E#8;E#9} in [.])), (A#14[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#13[(var X#6)];E#9},(letrec {E#8} in [.])], ((var X#7),A#14[[.]]), ((var X#6),[.]), ((var X#7),A#14[[.]]), ((var X#6),[.]), ((var X#7),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#7, S#3 |-> A#13[(var X#6)], E#2 |-> {X#6=(letrec {E#8} in S#10);E#9}, A#11 |-> A#14, T#5 |-> A#14[[.]], T#15 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#6)];E#9} in A#14[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9} in A#14[A#13[(var X#6)]]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#6)];E#9} in A#14[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#13[(var X#6)];E#8;E#9} in A#14[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#6=(letrec {E#8} in S#10);E#9} in A#14[A#13[(var X#6)]]) , (letrec {X#6=S#10;X#7=A#13[(var X#6)];E#8;E#9} in A#14[(var X#7)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#2,E#8} Delta3 = {((var X#7),A#14), (A#13[(var X#6)],A#14), ((letrec {X#6=(letrec {E#8} in S#10);E#9} in A#14[(dummy3 )]),(letrec {X#7=(dummy3 )} in [.])), (A#13[(var X#6)],(letrec {X#7=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#13[(var X#6)];E#8;E#9} in [.])), (A#14[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#13[(var X#6)];E#9},(letrec {E#8} in [.])], ((var X#7),A#14[[.]]), ((var X#6),[.]), ((var X#7),A#14[[.]]), ((var X#6),[.]), ((var X#7),A#14[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#7, S#3 |-> A#13[(var X#6)], E#2 |-> {X#6=(letrec {E#8} in S#10);E#9}, A#11 |-> A#14[[.]], T#5 |-> A#14, A#15 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#6)];E#9} in A#14[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9} in A#14[A#13[(var X#6)]]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#6)];E#9} in A#14[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#13[(var X#6)];E#8;E#9} in A#14[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {X#6=(letrec {E#8} in S#10);E#9} in A#13[(var X#6)]) , (letrec {X#6=S#10;X#7=A#13[(var X#6)];E#8;E#9} in (var X#7)) ) where Delta1 = {} Delta2 = {E#2,E#8} Delta3 = {((var X#7),[.]), (A#13[(var X#6)],[.]), ((letrec {X#6=(letrec {E#8} in S#10);E#9} in (dummy3 )),(letrec {X#7=(dummy3 )} in [.])), (A#13[(var X#6)],(letrec {X#7=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#13[(var X#6)];E#8;E#9} in [.])), ((var X#7),(letrec {E#8} in [.])), [{X#7=A#13[(var X#6)];E#9},(letrec {E#8} in [.])], ((var X#7),[.]), ((var X#6),[.]), ((var X#7),[.]), ((var X#6),[.]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#7, S#3 |-> A#13[(var X#6)], E#2 |-> {X#6=(letrec {E#8} in S#10);E#9}, T#5 |-> [.], A#11 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#6)];E#9} in (var X#7)) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9} in A#13[(var X#6)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#6)];E#9} in (var X#7)) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#13[(var X#6)];E#8;E#9} in (var X#7)) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;E#9 ;EE#15[X#14,(var X#6)] in A#16[A#13[(var X#14)]] ) , (letrec X#6= S#10 ;X#7= A#13[(var X#14)] ;E#8 ;E#9 ;EE#15[X#14,(var X#6)] in A#16[(var X#7)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2,E#8} Delta3 = {((var X#7),A#16[[.]]), (A#13[(var X#14)],A#16[[.]]), ((letrec {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]} in A#16[(dummy3 )]),(letrec {X#7=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#7=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#13[(var X#14)];E#8;E#9;EE#15[X#14,(var X#6)]} in [.])), (A#16[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#7, S#3 |-> A#13[(var X#14)], E#2 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]}, A#11 |-> A#16, T#5 |-> A#16[[.]], T#17 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]} in A#16[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]} in A#16[A#13[(var X#14)]]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]} in A#16[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#13[(var X#14)];E#8;E#9;EE#15[X#14,(var X#6)]} in A#16[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;E#9 ;EE#15[X#14,(var X#6)] in A#16[A#13[(var X#14)]] ) , (letrec X#6= S#10 ;X#7= A#13[(var X#14)] ;E#8 ;E#9 ;EE#15[X#14,(var X#6)] in A#16[(var X#7)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2,E#8} Delta3 = {((var X#7),A#16), (A#13[(var X#14)],A#16), ((letrec {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]} in A#16[(dummy3 )]),(letrec {X#7=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#7=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#13[(var X#14)];E#8;E#9;EE#15[X#14,(var X#6)]} in [.])), (A#16[(var X#7)],(letrec {E#8} in [.])), [{X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]]), ((var X#6),[.]), ((var X#7),A#16[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#7, S#3 |-> A#13[(var X#14)], E#2 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]}, A#11 |-> A#16[[.]], T#5 |-> A#16, A#17 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]} in A#16[(var X#7)]) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]} in A#16[A#13[(var X#14)]]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]} in A#16[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#13[(var X#14)];E#8;E#9;EE#15[X#14,(var X#6)]} in A#16[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#6= (letrec {E#8} in S#10) ;E#9 ;EE#15[X#14,(var X#6)] in A#13[(var X#14)] ) , (letrec X#6= S#10 ;X#7= A#13[(var X#14)] ;E#8 ;E#9 ;EE#15[X#14,(var X#6)] in (var X#7) ) ) where Delta1 = {} Delta2 = {E#2,E#8} Delta3 = {((var X#7),[.]), (A#13[(var X#14)],[.]), ((letrec {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]} in (dummy3 )),(letrec {X#7=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#7=(dummy3 )} in [.])), ((var X#6),(letrec {X#7=A#13[(var X#14)];E#8;E#9;EE#15[X#14,(var X#6)]} in [.])), ((var X#7),(letrec {E#8} in [.])), [{X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]},(letrec {E#8} in [.])], ((var X#7),[.]), ((var X#6),[.]), ((var X#7),[.]), ((var X#6),[.]), ((var X#7),[.])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) -SR,llet-e2-> (letrec {X#6=S#10;E#8;E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)]) and constraints: E#8/= {}, ((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])), (A#11[(var X#7)],(letrec {E#8} in [.])), ({E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#12[X#7,(var X#6)]} in A#11[(var X#7)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),((var X#6),(letrec {E#8;E#9;EE#12[X#7,(var X#6)]} in [.])),(A#11[(var X#7)],(letrec {E#8} in [.])),[{E#9;EE#12[X#7,(var X#6)]},(letrec {E#8} in [.])],((var X#1),T#5[[.]]),((var X#6),[.]),((var X#7),A#11[[.]]),((var X#6),[.]),((var X#7),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#7, S#3 |-> A#13[(var X#14)], E#2 |-> {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]}, T#5 |-> [.], A#11 |-> [.], X#7 |-> X#7} and instantiated rules: (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]} in (var X#7)) <-ucp1- (letrec {X#6=(letrec {E#8} in S#10);E#9;EE#15[X#14,(var X#6)]} in A#13[(var X#14)]) ................................................................................ (letrec {X#6=(letrec {E#8} in S#10);X#7=A#13[(var X#14)];E#9;EE#15[X#14,(var X#6)]} in (var X#7)) -SR,llet-e2-> (letrec {X#6=S#10;X#7=A#13[(var X#14)];E#8;E#9;EE#15[X#14,(var X#6)]} in (var X#7)) ================================================================================ Critical Pair: ( A#10[(app (letrec {E#6} in T#13[(letrec {E#2} in T#5[S#3])]) S#7)] , A#10[(letrec {E#6} in (app T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#7))] ) where Delta1 = {T#12,T#11,A#9,T#4,A#10} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (letrec {E#6} in T#13) S#7)], T#11 |-> (app (letrec {E#6} in T#13) S#7), T#12 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: A#10[(app (letrec {E#6} in T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#7)] <-ucp1- A#10[(app (letrec {E#6} in T#13[(letrec {E#2} in T#5[S#3])]) S#7)] ................................................................................ A#10[(app (letrec {E#6} in T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#7)] -SR,lapp1-> A#10[(letrec {E#6} in (app T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#7))] ================================================================================ Critical Pair: ( A#10[(app (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];E#16} in S#8) S#7)] , A#10[(letrec X#14= T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#16 in (app S#8 S#7) )] ) where Delta1 = {T#12,T#11,A#9,T#4,A#10} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (letrec {X#14=T#13;E#16} in S#8) S#7)], T#11 |-> (app (letrec {X#14=T#13;E#16} in S#8) S#7), T#12 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16}, E#15 |-> {E#16}} and instantiated rules: A#10[(app (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in S#8) S#7)] <-ucp1- A#10[(app (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];E#16} in S#8) S#7)] ................................................................................ A#10[(app (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in S#8) S#7)] -SR,lapp1-> A#10[(letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in (app S#8 S#7))] ================================================================================ Critical Pair: ( A#10[(app (letrec {E#2} in T#5[S#3]) S#7)] , A#10[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#7))] ) where Delta1 = {T#11,A#9,T#4,A#10} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app [.] S#7)], T#11 |-> (app [.] S#7), T#12 |-> [.], S#8 |-> T#5[(var X#1)], E#6 |-> {X#1=S#3;E#2}} and instantiated rules: A#10[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#7)] <-ucp1- A#10[(app (letrec {E#2} in T#5[S#3]) S#7)] ................................................................................ A#10[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#7)] -SR,lapp1-> A#10[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#7))] ================================================================================ Critical Pair: ( A#10[(app (letrec {E#6} in S#8) T#12[(letrec {E#2} in T#5[S#3])])] , A#10[(letrec {E#6} in (app S#8 T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))] ) where Delta1 = {T#11,A#9,T#4,A#10} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#6} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> A#10, T#4 |-> A#10[(app (letrec {E#6} in S#8) T#12)], T#11 |-> (app (letrec {E#6} in S#8) T#12), S#7 |-> T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: A#10[(app (letrec {E#6} in S#8) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] <-ucp1- A#10[(app (letrec {E#6} in S#8) T#12[(letrec {E#2} in T#5[S#3])])] ................................................................................ A#10[(app (letrec {E#6} in S#8) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] -SR,lapp1-> A#10[(letrec {E#6} in (app S#8 T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))] ================================================================================ Critical Pair: ( A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {E#2} in T#5[S#3])])] , A#10[(app A#11[(letrec {E#6} in (app S#8 S#7))] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) where Delta1 = {A#9,T#4} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12)], A#9 |-> A#10[(app A#11 T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] <-ucp1- A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {E#2} in T#5[S#3])])] ................................................................................ A#10[(app A#11[(app (letrec {E#6} in S#8) S#7)] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] -SR,lapp1-> A#10[(app A#11[(letrec {E#6} in (app S#8 S#7))] T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ================================================================================ Critical Pair: ( (app (letrec {E#6} in T#11[(letrec {E#2} in T#5[S#3])]) S#7) , (letrec {E#6} in (app T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#7)) ) where Delta1 = {T#10,T#4} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (letrec {E#6} in T#11) S#7), T#10 |-> (letrec {E#6} in T#11), S#8 |-> T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (app (letrec {E#6} in T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#7) <-ucp1- (app (letrec {E#6} in T#11[(letrec {E#2} in T#5[S#3])]) S#7) ................................................................................ (app (letrec {E#6} in T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#7) -SR,lapp1-> (letrec {E#6} in (app T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#7)) ================================================================================ Critical Pair: ( (app (letrec {X#12=T#11[(letrec {E#2} in T#5[S#3])];E#14} in S#8) S#7) , (letrec X#12= T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#14 in (app S#8 S#7) ) ) where Delta1 = {T#10,T#4} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (letrec {X#12=T#11;E#14} in S#8) S#7), T#10 |-> (letrec {X#12=T#11;E#14} in S#8), E#6 |-> {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (app (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in S#8) S#7) <-ucp1- (app (letrec {X#12=T#11[(letrec {E#2} in T#5[S#3])];E#14} in S#8) S#7) ................................................................................ (app (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in S#8) S#7) -SR,lapp1-> (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in (app S#8 S#7)) ================================================================================ Critical Pair: ( (app (letrec {E#2} in T#5[S#3]) S#7) , (letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#7)) ) where Delta1 = {T#4} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app [.] S#7), T#10 |-> [.], S#8 |-> T#5[(var X#1)], E#6 |-> {X#1=S#3;E#2}} and instantiated rules: (app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#7) <-ucp1- (app (letrec {E#2} in T#5[S#3]) S#7) ................................................................................ (app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#7) -SR,lapp1-> (letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#7)) ================================================================================ Critical Pair: ( (app (letrec {E#6} in S#8) T#10[(letrec {E#2} in T#5[S#3])]) , (letrec {E#6} in (app S#8 T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) ) where Delta1 = {T#4} Delta2 = {E#2,E#6} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#6} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#9[(app (letrec {E#6} in S#8) S#7)] -SR,lapp1-> A#9[(letrec {E#6} in (app S#8 S#7))] and constraints: E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= A#9[(app (letrec {E#6} in S#8) S#7)]} Delta1= {} Delta2= {E#2,E#6} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {A#9 |-> [.], T#4 |-> (app (letrec {E#6} in S#8) T#10), S#7 |-> T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (app (letrec {E#6} in S#8) T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) <-ucp1- (app (letrec {E#6} in S#8) T#10[(letrec {E#2} in T#5[S#3])]) ................................................................................ (app (letrec {E#6} in S#8) T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) -SR,lapp1-> (letrec {E#6} in (app S#8 T#10[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app (letrec {E#7} in T#15[(letrec {E#2} in T#5[S#3])]) S#8)] ) , (letrec E#6 in A#12[(letrec {E#7} in (app T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#8))] ) ) where Delta1 = {T#14,T#13,A#10,T#11,T#4,A#12} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app (letrec {E#7} in T#15) S#8)]), A#10 |-> A#12, T#11 |-> A#12[(app (letrec {E#7} in T#15) S#8)], T#13 |-> (app (letrec {E#7} in T#15) S#8), T#14 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {E#7} in T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#8)]) <-ucp1- (letrec {E#6} in A#12[(app (letrec {E#7} in T#15[(letrec {E#2} in T#5[S#3])]) S#8)]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {E#7} in T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#8)]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {E#7} in (app T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#8))]) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app (letrec {X#16=T#15[(letrec {E#2} in T#5[S#3])];E#18} in S#9) S#8)] ) , (letrec E#6 in A#12[(letrec X#16= T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#18 in (app S#9 S#8) )] ) ) where Delta1 = {T#14,T#13,A#10,T#11,T#4,A#12} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#16=T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#18} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)]), A#10 |-> A#12, T#11 |-> A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#9) S#8), T#14 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {X#16=T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#18} in S#9) S#8)]) <-ucp1- (letrec {E#6} in A#12[(app (letrec {X#16=T#15[(letrec {E#2} in T#5[S#3])];E#18} in S#9) S#8)]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {X#16=T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#18} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {X#16=T#15[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#18} in (app S#9 S#8))]) ================================================================================ Critical Pair: ( (letrec {E#6} in A#12[(app (letrec {E#2} in T#5[S#3]) S#8)]) , (letrec {E#6} in A#12[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#8))]) ) where Delta1 = {T#13,A#10,T#11,T#4,A#12} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app [.] S#8)]), A#10 |-> A#12, T#11 |-> A#12[(app [.] S#8)], T#13 |-> (app [.] S#8), T#14 |-> [.], S#9 |-> T#5[(var X#1)], E#7 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#8)]) <-ucp1- (letrec {E#6} in A#12[(app (letrec {E#2} in T#5[S#3]) S#8)]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#8)]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#8))]) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {E#2} in T#5[S#3])])] ) , (letrec E#6 in A#12[(letrec {E#7} in (app S#9 T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))] ) ) where Delta1 = {T#13,A#10,T#11,T#4,A#12} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14)]), A#10 |-> A#12, T#11 |-> A#12[(app (letrec {E#7} in S#9) T#14)], T#13 |-> (app (letrec {E#7} in S#9) T#14), S#8 |-> T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {E#6} in A#12[(app (letrec {E#7} in S#9) T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,lapp2-> (letrec {E#6} in A#12[(letrec {E#7} in (app S#9 T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))]) ================================================================================ Critical Pair: ( (letrec E#6 in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {E#2} in T#5[S#3])])] ) , (letrec E#6 in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#10,T#11,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)]), T#11 |-> A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)], A#10 |-> A#12[(app A#13 T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {E#6} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,lapp2-> (letrec {E#6} in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] T#14[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {E#2} in T#5[S#3])]) S#8)) , (letrec E#6 in (letrec {E#7} in (app T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#8)) ) ) where Delta1 = {T#12,T#11,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (letrec {E#7} in T#13) S#8)), A#10 |-> [.], T#11 |-> (app (letrec {E#7} in T#13) S#8), T#12 |-> (letrec {E#7} in T#13), S#9 |-> T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#8)) <-ucp1- (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {E#2} in T#5[S#3])]) S#8)) ................................................................................ (letrec {E#6} in (app (letrec {E#7} in T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#8)) -SR,lapp2-> (letrec {E#6} in (letrec {E#7} in (app T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#8))) ================================================================================ Critical Pair: ( (letrec E#6 in (app (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];E#16} in S#9) S#8) ) , (letrec E#6 in (letrec X#14= T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#16 in (app S#9 S#8) ) ) ) where Delta1 = {T#12,T#11,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (letrec {X#14=T#13;E#16} in S#9) S#8)), A#10 |-> [.], T#11 |-> (app (letrec {X#14=T#13;E#16} in S#9) S#8), T#12 |-> (letrec {X#14=T#13;E#16} in S#9), E#7 |-> {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {E#6} in (app (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in S#9) S#8)) <-ucp1- (letrec {E#6} in (app (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];E#16} in S#9) S#8)) ................................................................................ (letrec {E#6} in (app (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in S#9) S#8)) -SR,lapp2-> (letrec {E#6} in (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16} in (app S#9 S#8))) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (letrec {E#2} in T#5[S#3]) S#8)) , (letrec {E#6} in (letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#8))) ) where Delta1 = {T#11,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app [.] S#8)), A#10 |-> [.], T#11 |-> (app [.] S#8), T#12 |-> [.], S#9 |-> T#5[(var X#1)], E#7 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {E#6} in (app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#8)) <-ucp1- (letrec {E#6} in (app (letrec {E#2} in T#5[S#3]) S#8)) ................................................................................ (letrec {E#6} in (app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#8)) -SR,lapp2-> (letrec {E#6} in (letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#8))) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {E#2} in T#5[S#3])])) , (letrec E#6 in (letrec {E#7} in (app S#9 T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) ) ) where Delta1 = {T#11,T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#6} in (app (letrec {E#7} in S#9) T#12)), A#10 |-> [.], T#11 |-> (app (letrec {E#7} in S#9) T#12), S#8 |-> T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) <-ucp1- (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {E#2} in T#5[S#3])])) ................................................................................ (letrec {E#6} in (app (letrec {E#7} in S#9) T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) -SR,lapp2-> (letrec {E#6} in (letrec {E#7} in (app S#9 T#12[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {E#2} in T#5[S#3])] ;E#14 in A#10[(app (letrec {E#7} in S#9) S#8)] ) , (letrec X#12= T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#14 in A#10[(letrec {E#7} in (app S#9 S#8))] ) ) where Delta1 = {T#4} Delta2 = {E#2,E#6,E#7} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#5[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#12=T#11;E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]), E#6 |-> {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]) <-ucp1- (letrec {X#12=T#11[(letrec {E#2} in T#5[S#3])];E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {X#12=T#11[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#14} in A#10[(letrec {E#7} in (app S#9 S#8))]) ================================================================================ Critical Pair: ( (letrec {E#11} in A#12[(app (letrec {E#7} in T#15[S#3]) S#8)]) , (letrec {X#1=S#3;E#11} in A#12[(letrec {E#7} in (app T#15[(var X#1)] S#8))]) ) where Delta1 = {T#14,T#13,A#10,T#5,A#12} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),A#12[(app (letrec {E#7} in T#15) S#8)]), (S#3,A#12[(app (letrec {E#7} in T#15) S#8)]), ((letrec {E#11} in A#12[(app (letrec {E#7} in T#15[(dummy3 )]) S#8)]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),A#12[(app (letrec {E#7} in T#15[[.]]) S#8)])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> A#12, T#5 |-> A#12[(app (letrec {E#7} in T#15) S#8)], T#13 |-> (app (letrec {E#7} in T#15) S#8), T#14 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#11} in A#12[(app (letrec {E#7} in T#15[(var X#1)]) S#8)]) <-ucp1- (letrec {E#11} in A#12[(app (letrec {E#7} in T#15[S#3]) S#8)]) ................................................................................ (letrec {X#1=S#3;E#11} in A#12[(app (letrec {E#7} in T#15[(var X#1)]) S#8)]) -SR,lapp2-> (letrec {X#1=S#3;E#11} in A#12[(letrec {E#7} in (app T#15[(var X#1)] S#8))]) ================================================================================ Critical Pair: ( (letrec {E#11} in A#12[(app (letrec {X#16=T#15[S#3];E#18} in S#9) S#8)]) , (letrec X#1= S#3 ;E#11 in A#12[(letrec {X#16=T#15[(var X#1)];E#18} in (app S#9 S#8))] ) ) where Delta1 = {T#14,T#13,A#10,T#5,A#12} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)]), (S#3,A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)]), ((letrec {E#11} in A#12[(app (letrec {X#16=T#15[(dummy3 )];E#18} in S#9) S#8)]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#16=T#15[(var X#1)];E#18} in [.])), ((var X#1),A#12[(app (letrec {X#16=T#15[[.]];E#18} in S#9) S#8)])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> A#12, T#5 |-> A#12[(app (letrec {X#16=T#15;E#18} in S#9) S#8)], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#9) S#8), T#14 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(var X#1)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#1=S#3;E#11} in A#12[(app (letrec {X#16=T#15[(var X#1)];E#18} in S#9) S#8)]) <-ucp1- (letrec {E#11} in A#12[(app (letrec {X#16=T#15[S#3];E#18} in S#9) S#8)]) ................................................................................ (letrec {X#1=S#3;E#11} in A#12[(app (letrec {X#16=T#15[(var X#1)];E#18} in S#9) S#8)]) -SR,lapp2-> (letrec {X#1=S#3;E#11} in A#12[(letrec {X#16=T#15[(var X#1)];E#18} in (app S#9 S#8))]) ================================================================================ Critical Pair: ( (letrec {E#11} in A#12[(app (letrec {E#7} in S#9) T#14[S#3])]) , (letrec {X#1=S#3;E#11} in A#12[(letrec {E#7} in (app S#9 T#14[(var X#1)]))]) ) where Delta1 = {T#13,A#10,T#5,A#12} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),A#12[(app (letrec {E#7} in S#9) T#14)]), (S#3,A#12[(app (letrec {E#7} in S#9) T#14)]), ((letrec {E#11} in A#12[(app (letrec {E#7} in S#9) T#14[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#14[(var X#1)],(letrec {E#7} in [.])), ((var X#1),A#12[(app (letrec {E#7} in S#9) T#14[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> A#12, T#5 |-> A#12[(app (letrec {E#7} in S#9) T#14)], T#13 |-> (app (letrec {E#7} in S#9) T#14), S#8 |-> T#14[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#11} in A#12[(app (letrec {E#7} in S#9) T#14[(var X#1)])]) <-ucp1- (letrec {E#11} in A#12[(app (letrec {E#7} in S#9) T#14[S#3])]) ................................................................................ (letrec {X#1=S#3;E#11} in A#12[(app (letrec {E#7} in S#9) T#14[(var X#1)])]) -SR,lapp2-> (letrec {X#1=S#3;E#11} in A#12[(letrec {E#7} in (app S#9 T#14[(var X#1)]))]) ================================================================================ Critical Pair: ( (letrec {E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[S#3])]) , (letrec X#1= S#3 ;E#11 in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] T#14[(var X#1)])] ) ) where Delta1 = {A#10,T#5} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)]), (S#3,A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)]), ((letrec {E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, T#5 |-> A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14)], A#10 |-> A#12[(app A#13 T#14[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(var X#1)])]) <-ucp1- (letrec {E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[S#3])]) ................................................................................ (letrec {X#1=S#3;E#11} in A#12[(app A#13[(app (letrec {E#7} in S#9) S#8)] T#14[(var X#1)])]) -SR,lapp2-> (letrec {X#1=S#3;E#11} in A#12[(app A#13[(letrec {E#7} in (app S#9 S#8))] T#14[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {E#11} in (app (letrec {E#7} in T#13[S#3]) S#8)) , (letrec {X#1=S#3;E#11} in (letrec {E#7} in (app T#13[(var X#1)] S#8))) ) where Delta1 = {T#12,T#5} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),(app (letrec {E#7} in T#13) S#8)), (S#3,(app (letrec {E#7} in T#13) S#8)), ((letrec {E#11} in (app (letrec {E#7} in T#13[(dummy3 )]) S#8)),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),(app (letrec {E#7} in T#13[[.]]) S#8))} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> [.], T#5 |-> (app (letrec {E#7} in T#13) S#8), T#12 |-> (letrec {E#7} in T#13), S#9 |-> T#13[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#11} in (app (letrec {E#7} in T#13[(var X#1)]) S#8)) <-ucp1- (letrec {E#11} in (app (letrec {E#7} in T#13[S#3]) S#8)) ................................................................................ (letrec {X#1=S#3;E#11} in (app (letrec {E#7} in T#13[(var X#1)]) S#8)) -SR,lapp2-> (letrec {X#1=S#3;E#11} in (letrec {E#7} in (app T#13[(var X#1)] S#8))) ================================================================================ Critical Pair: ( (letrec {E#11} in (app (letrec {X#14=T#13[S#3];E#16} in S#9) S#8)) , (letrec {X#1=S#3;E#11} in (letrec {X#14=T#13[(var X#1)];E#16} in (app S#9 S#8))) ) where Delta1 = {T#12,T#5} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),(app (letrec {X#14=T#13;E#16} in S#9) S#8)), (S#3,(app (letrec {X#14=T#13;E#16} in S#9) S#8)), ((letrec {E#11} in (app (letrec {X#14=T#13[(dummy3 )];E#16} in S#9) S#8)),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#14=T#13[(var X#1)];E#16} in [.])), ((var X#1),(app (letrec {X#14=T#13[[.]];E#16} in S#9) S#8))} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> [.], T#5 |-> (app (letrec {X#14=T#13;E#16} in S#9) S#8), T#12 |-> (letrec {X#14=T#13;E#16} in S#9), E#7 |-> {X#14=T#13[(var X#1)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#1=S#3;E#11} in (app (letrec {X#14=T#13[(var X#1)];E#16} in S#9) S#8)) <-ucp1- (letrec {E#11} in (app (letrec {X#14=T#13[S#3];E#16} in S#9) S#8)) ................................................................................ (letrec {X#1=S#3;E#11} in (app (letrec {X#14=T#13[(var X#1)];E#16} in S#9) S#8)) -SR,lapp2-> (letrec {X#1=S#3;E#11} in (letrec {X#14=T#13[(var X#1)];E#16} in (app S#9 S#8))) ================================================================================ Critical Pair: ( (letrec {E#11} in (app (letrec {E#7} in S#9) T#12[S#3])) , (letrec {X#1=S#3;E#11} in (letrec {E#7} in (app S#9 T#12[(var X#1)]))) ) where Delta1 = {T#5} Delta2 = {E#11,E#2,E#6,E#7} Delta3 = {((var X#1),(app (letrec {E#7} in S#9) T#12)), (S#3,(app (letrec {E#7} in S#9) T#12)), ((letrec {E#11} in (app (letrec {E#7} in S#9) T#12[(dummy3 )])),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#12[(var X#1)],(letrec {E#7} in [.])), ((var X#1),(app (letrec {E#7} in S#9) T#12[[.]]))} Delta4= {} from overlapping <-SR,lapp2- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)]) -SR,lapp2-> (letrec {E#6} in A#10[(letrec {E#7} in (app S#9 S#8))]) and constraints: E#6/= {}, E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#6} in A#10[(app (letrec {E#7} in S#9) S#8)])} Delta1= {} Delta2= {E#2,E#6,E#7} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#5[[.]])} and found solution: Sol = {T#4 |-> [.], E#6 |-> {X#1=S#3;E#11}, E#2 |-> {E#11}, A#10 |-> [.], T#5 |-> (app (letrec {E#7} in S#9) T#12), S#8 |-> T#12[(var X#1)]} and instantiated rules: (letrec {X#1=S#3;E#11} in (app (letrec {E#7} in S#9) T#12[(var X#1)])) <-ucp1- (letrec {E#11} in (app (letrec {E#7} in S#9) T#12[S#3])) ................................................................................ (letrec {X#1=S#3;E#11} in (app (letrec {E#7} in S#9) T#12[(var X#1)])) -SR,lapp2-> (letrec {X#1=S#3;E#11} in (letrec {E#7} in (app S#9 T#12[(var X#1)]))) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)] in A#14[(app A#15[(var X#6)] T#16[(letrec {E#2} in T#5[S#3])])] ) , (letrec E#7 ;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))] in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]), ((var X#6),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16)]), T#13 |-> A#14[(app A#15[(var X#6)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) <-ucp1- (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {E#2} in T#5[S#3])])]) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#14[(app A#15[(var X#6)] T#16[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {E#2} in T#5[S#3])] ;E#16 ;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#14= T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#16 ;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))] in A#11[(var X#6)] ) ) where Delta1 = {T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#14=T#13;E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]), E#7 |-> {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16}, E#15 |-> {E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#14=T#13[(letrec {E#2} in T#5[S#3])];E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#14=T#13[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#16;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec {E#8} in T#20[(letrec {E#2} in T#5[S#3])]) S#9)] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec {E#8} in (app T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9))] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#18,A#16,T#13,T#4,A#17} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (letrec {E#8} in T#20) S#9)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app (letrec {E#8} in T#20) S#9)], T#18 |-> (app (letrec {E#8} in T#20) S#9), T#19 |-> (letrec {E#8} in T#20), S#10 |-> T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=A#17[(app (letrec {E#8} in T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9)];E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app (letrec {E#8} in T#20[(letrec {E#2} in T#5[S#3])]) S#9)];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {E#8} in T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9)];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {E#8} in (app T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec {X#21=T#20[(letrec {E#2} in T#5[S#3])];E#23} in S#10) S#9)] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec X#21= T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#23 in (app S#10 S#9) )] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#18,A#16,T#13,T#4,A#17} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (letrec {X#21=T#20;E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app (letrec {X#21=T#20;E#23} in S#10) S#9)], T#18 |-> (app (letrec {X#21=T#20;E#23} in S#10) S#9), T#19 |-> (letrec {X#21=T#20;E#23} in S#10), E#8 |-> {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#6=A#17[(app (letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app (letrec {X#21=T#20[(letrec {E#2} in T#5[S#3])];E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in S#10) S#9)];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in (app S#10 S#9))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {X#6=A#17[(app (letrec {E#2} in T#5[S#3]) S#9)];E#7} in A#11[(var X#6)]) , (letrec X#6= A#17[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9))] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#17} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app [.] S#9)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app [.] S#9)], T#18 |-> (app [.] S#9), T#19 |-> [.], S#10 |-> T#5[(var X#1)], E#8 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {X#6=A#17[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9)];E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app (letrec {E#2} in T#5[S#3]) S#9)];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9)];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app (letrec {E#8} in S#10) T#19[(letrec {E#2} in T#5[S#3])])] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(letrec {E#8} in (app S#10 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#18,A#16,T#13,T#4,A#17} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> A#17, T#13 |-> A#17[(app (letrec {E#8} in S#10) T#19)], T#18 |-> (app (letrec {E#8} in S#10) T#19), S#9 |-> T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19[(letrec {E#2} in T#5[S#3])])];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app (letrec {E#8} in S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(letrec {E#8} in (app S#10 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {E#2} in T#5[S#3])])] ;E#7 in A#11[(var X#6)] ) , (letrec X#6= A#17[(app A#18[(letrec {E#8} in (app S#10 S#9))] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19)];E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]}, X#14 |-> X#6, E#15 |-> {E#7}, T#13 |-> A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {E#2} in T#5[S#3])])];E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#17[(app A#18[(app (letrec {E#8} in S#10) S#9)] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#17[(app A#18[(letrec {E#8} in (app S#10 S#9))] T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec {E#8} in T#18[(letrec {E#2} in T#5[S#3])]) S#9) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec {E#8} in (app T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9)) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#17,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (letrec {E#8} in T#18) S#9);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in T#18) S#9), T#17 |-> (letrec {E#8} in T#18), S#10 |-> T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(app (letrec {E#8} in T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9);E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=(app (letrec {E#8} in T#18[(letrec {E#2} in T#5[S#3])]) S#9);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {E#8} in T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {E#8} in (app T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec {X#19=T#18[(letrec {E#2} in T#5[S#3])];E#21} in S#10) S#9) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec X#19= T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#21 in (app S#10 S#9) ) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#17,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#19=T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#21} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (letrec {X#19=T#18;E#21} in S#10) S#9);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app (letrec {X#19=T#18;E#21} in S#10) S#9), T#17 |-> (letrec {X#19=T#18;E#21} in S#10), E#8 |-> {X#19=T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#6=(app (letrec {X#19=T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#21} in S#10) S#9);E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=(app (letrec {X#19=T#18[(letrec {E#2} in T#5[S#3])];E#21} in S#10) S#9);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {X#19=T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#21} in S#10) S#9);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {X#19=T#18[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#21} in (app S#10 S#9));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {X#6=(app (letrec {E#2} in T#5[S#3]) S#9);E#7} in A#11[(var X#6)]) , (letrec X#6= (letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9)) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app [.] S#9);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app [.] S#9), T#17 |-> [.], S#10 |-> T#5[(var X#1)], E#8 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {X#6=(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9);E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=(app (letrec {E#2} in T#5[S#3]) S#9);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= (app (letrec {E#8} in S#10) T#17[(letrec {E#2} in T#5[S#3])]) ;E#7 in A#11[(var X#6)] ) , (letrec X#6= (letrec {E#8} in (app S#10 T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) ;E#7 in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=(app (letrec {E#8} in S#10) T#17);E#7} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#6, E#15 |-> {E#7}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in S#10) T#17), S#9 |-> T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#6=(app (letrec {E#8} in S#10) T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#7} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=(app (letrec {E#8} in S#10) T#17[(letrec {E#2} in T#5[S#3])]);E#7} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=(app (letrec {E#8} in S#10) T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#7} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=(letrec {E#8} in (app S#10 T#17[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]));E#7} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {E#2} in T#5[S#3])])] ;E#7 ;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#6= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#7 ;EE#18[X#17,(letrec {E#8} in (app S#10 S#9))] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21)];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#6, E#15 |-> {E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {E#2} in T#5[S#3])])];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#17,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#17,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {E#2} in T#5[S#3])])] ;E#7 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(app (letrec {E#8} in S#10) S#9)] in A#11[(var X#6)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#7 ;EE#19[X#6,(var X#17)] ;EE#20[X#18,(letrec {E#8} in (app S#10 S#9))] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {E#2} in T#5[S#3])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#19[X#6,(var X#17)];EE#20[X#18,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#8} in T#22[(letrec {E#2} in T#5[S#3])]) S#9)] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {E#8} in (app T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9))] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#21,T#20,A#16,T#13,T#4,A#19} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (letrec {E#8} in T#22) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (letrec {E#8} in T#22) S#9)], T#20 |-> (app (letrec {E#8} in T#22) S#9), T#21 |-> (letrec {E#8} in T#22), S#10 |-> T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#8} in T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app (letrec {E#8} in T#22[(letrec {E#2} in T#5[S#3])]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#8} in T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#8} in (app T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {X#23=T#22[(letrec {E#2} in T#5[S#3])];E#25} in S#10) S#9)] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec X#23= T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#25 in (app S#10 S#9) )] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#21,T#20,A#16,T#13,T#4,A#19} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#23=T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#25} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (letrec {X#23=T#22;E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (letrec {X#23=T#22;E#25} in S#10) S#9)], T#20 |-> (app (letrec {X#23=T#22;E#25} in S#10) S#9), T#21 |-> (letrec {X#23=T#22;E#25} in S#10), E#8 |-> {X#23=T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#17=A#19[(app (letrec {X#23=T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app (letrec {X#23=T#22[(letrec {E#2} in T#5[S#3])];E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {X#23=T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#25} in S#10) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {X#23=T#22[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#25} in (app S#10 S#9))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#2} in T#5[S#3]) S#9)] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9))] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#19} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app [.] S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app [.] S#9)], T#20 |-> (app [.] S#9), T#21 |-> [.], S#10 |-> T#5[(var X#1)], E#8 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {X#17=A#19[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app (letrec {E#2} in T#5[S#3]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#8} in S#10) T#21[(letrec {E#2} in T#5[S#3])])] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(letrec {E#8} in (app S#10 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#20,A#16,T#13,T#4,A#19} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[(app (letrec {E#8} in S#10) T#21)], T#20 |-> (app (letrec {E#8} in S#10) T#21), S#9 |-> T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21[(letrec {E#2} in T#5[S#3])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#8} in S#10) T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#8} in (app S#10 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]))];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {E#2} in T#5[S#3])])] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= A#19[(app A#20[(letrec {E#8} in (app S#10 S#9))] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])] ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {A#16,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21)];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, T#13 |-> A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {E#2} in T#5[S#3])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (letrec {E#8} in S#10) S#9)] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=A#19[(app A#20[(letrec {E#8} in (app S#10 S#9))] T#21[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])];E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#8} in T#20[(letrec {E#2} in T#5[S#3])]) S#9) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {E#8} in (app T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9)) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (letrec {E#8} in T#20) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in T#20) S#9), T#19 |-> (letrec {E#8} in T#20), S#10 |-> T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#17=(app (letrec {E#8} in T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=(app (letrec {E#8} in T#20[(letrec {E#2} in T#5[S#3])]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {E#8} in T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {E#8} in (app T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] S#9));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {X#21=T#20[(letrec {E#2} in T#5[S#3])];E#23} in S#10) S#9) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec X#21= T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] ;E#23 in (app S#10 S#9) ) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#19,T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (letrec {X#21=T#20;E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (letrec {X#21=T#20;E#23} in S#10) S#9), T#19 |-> (letrec {X#21=T#20;E#23} in S#10), E#8 |-> {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#17=(app (letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=(app (letrec {X#21=T#20[(letrec {E#2} in T#5[S#3])];E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in S#10) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {X#21=T#20[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])];E#23} in (app S#10 S#9));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#2} in T#5[S#3]) S#9) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9)) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {X#1=S#3;E#2} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app [.] S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app [.] S#9), T#19 |-> [.], S#10 |-> T#5[(var X#1)], E#8 |-> {X#1=S#3;E#2}} and instantiated rules: (letrec {X#17=(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=(app (letrec {E#2} in T#5[S#3]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {X#1=S#3;E#2} in T#5[(var X#1)]) S#9);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {X#1=S#3;E#2} in (app T#5[(var X#1)] S#9));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#8} in S#10) T#19[(letrec {E#2} in T#5[S#3])]) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) , (letrec X#17= (letrec {E#8} in (app S#10 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])])) ;E#7 ;EE#18[X#6,(var X#17)] in A#11[(var X#6)] ) ) where Delta1 = {T#13,T#4} Delta2 = {E#2,E#8} Delta3 = {((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])],(letrec {E#8} in [.])), ((var X#1),T#5[[.]]), ((var X#6),A#11[[.]]), ((var X#6),A#11[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> (letrec {X#17=(app (letrec {E#8} in S#10) T#19);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {E#7;EE#18[X#6,(var X#17)]}, A#16 |-> [.], T#13 |-> (app (letrec {E#8} in S#10) T#19), S#9 |-> T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]} and instantiated rules: (letrec {X#17=(app (letrec {E#8} in S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) <-ucp1- (letrec {X#17=(app (letrec {E#8} in S#10) T#19[(letrec {E#2} in T#5[S#3])]);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ................................................................................ (letrec {X#17=(app (letrec {E#8} in S#10) T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]);E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {X#17=(letrec {E#8} in (app S#10 T#19[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])]));E#7;EE#18[X#6,(var X#17)]} in A#11[(var X#6)]) ================================================================================ Critical Pair: ( (letrec E#13 ;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)] in A#14[(app A#15[(var X#6)] T#16[S#3])] ) , (letrec X#1= S#3 ;E#13 ;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))] in A#14[(app A#15[(var X#6)] T#16[(var X#1)])] ) ) where Delta1 = {A#11,T#5} Delta2 = {E#2,E#8} Delta3 = {((var X#1),A#14[(app A#15[(var X#6)] T#16)]), (S#3,A#14[(app A#15[(var X#6)] T#16)]), ((letrec {E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(dummy3 )])]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#1),A#14[(app A#15[(var X#6)] T#16[[.]])]), ((var X#6),A#14[(app A#15[[.]] T#16[(var X#1)])]), ((var X#6),A#14[(app A#15[[.]] T#16[(var X#1)])])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], E#7 |-> {X#1=S#3;E#13}, E#2 |-> {E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]}, T#5 |-> A#14[(app A#15[(var X#6)] T#16)], A#11 |-> A#14[(app A#15 T#16[(var X#1)])]} and instantiated rules: (letrec {X#1=S#3;E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(var X#1)])]) <-ucp1- (letrec {E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[S#3])]) ................................................................................ (letrec {X#1=S#3;E#13;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#14[(app A#15[(var X#6)] T#16[(var X#1)])]) -SR,lapp3-> (letrec {X#1=S#3;E#13;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#14[(app A#15[(var X#6)] T#16[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {E#7} in A#14[A#13[(app (letrec {E#8} in S#10) S#9)]]) , (letrec {X#6=A#13[(letrec {E#8} in (app S#10 S#9))];E#7} in A#14[(var X#6)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#7,E#2,E#8} Delta3 = {((var X#6),A#14[[.]]), (A#13[(app (letrec {E#8} in S#10) S#9)],A#14[[.]]), ((letrec {E#7} in A#14[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(app (letrec {E#8} in S#10) S#9)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(app (letrec {E#8} in S#10) S#9)], E#2 |-> {E#7}, A#11 |-> A#14, T#5 |-> A#14[[.]], T#15 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(app (letrec {E#8} in S#10) S#9)];E#7} in A#14[(var X#6)]) <-ucp1- (letrec {E#7} in A#14[A#13[(app (letrec {E#8} in S#10) S#9)]]) ................................................................................ (letrec {X#6=A#13[(app (letrec {E#8} in S#10) S#9)];E#7} in A#14[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#13[(letrec {E#8} in (app S#10 S#9))];E#7} in A#14[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#7} in A#14[A#13[(app (letrec {E#8} in S#10) S#9)]]) , (letrec {X#6=A#13[(letrec {E#8} in (app S#10 S#9))];E#7} in A#14[(var X#6)]) ) where Delta1 = {A#11,T#5,A#14} Delta2 = {E#7,E#2,E#8} Delta3 = {((var X#6),A#14), (A#13[(app (letrec {E#8} in S#10) S#9)],A#14), ((letrec {E#7} in A#14[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(app (letrec {E#8} in S#10) S#9)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]]), ((var X#6),A#14[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(app (letrec {E#8} in S#10) S#9)], E#2 |-> {E#7}, A#11 |-> A#14[[.]], T#5 |-> A#14, A#15 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(app (letrec {E#8} in S#10) S#9)];E#7} in A#14[(var X#6)]) <-ucp1- (letrec {E#7} in A#14[A#13[(app (letrec {E#8} in S#10) S#9)]]) ................................................................................ (letrec {X#6=A#13[(app (letrec {E#8} in S#10) S#9)];E#7} in A#14[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#13[(letrec {E#8} in (app S#10 S#9))];E#7} in A#14[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) S#9)]) , (letrec {X#6=A#13[(letrec {E#8} in (app S#10 S#9))];E#7} in (var X#6)) ) where Delta1 = {} Delta2 = {E#7,E#2,E#8} Delta3 = {((var X#6),[.]), (A#13[(app (letrec {E#8} in S#10) S#9)],[.]), ((letrec {E#7} in (dummy3 )),(letrec {X#6=(dummy3 )} in [.])), (A#13[(app (letrec {E#8} in S#10) S#9)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(app (letrec {E#8} in S#10) S#9)], E#2 |-> {E#7}, T#5 |-> [.], A#11 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(app (letrec {E#8} in S#10) S#9)];E#7} in (var X#6)) <-ucp1- (letrec {E#7} in A#13[(app (letrec {E#8} in S#10) S#9)]) ................................................................................ (letrec {X#6=A#13[(app (letrec {E#8} in S#10) S#9)];E#7} in (var X#6)) -SR,lapp3-> (letrec {X#6=A#13[(letrec {E#8} in (app S#10 S#9))];E#7} in (var X#6)) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)] in A#16[A#13[(var X#14)]] ) , (letrec X#6= A#13[(var X#14)] ;E#7 ;EE#15[X#14,(letrec {E#8} in (app S#10 S#9))] in A#16[(var X#6)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2,E#8} Delta3 = {((var X#6),A#16[[.]]), (A#13[(var X#14)],A#16[[.]]), ((letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(var X#14)], E#2 |-> {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]}, A#11 |-> A#16, T#5 |-> A#16[[.]], T#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) <-ucp1- (letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[A#13[(var X#14)]]) ................................................................................ (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(letrec {E#8} in (app S#10 S#9))]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)] in A#16[A#13[(var X#14)]] ) , (letrec X#6= A#13[(var X#14)] ;E#7 ;EE#15[X#14,(letrec {E#8} in (app S#10 S#9))] in A#16[(var X#6)] ) ) where Delta1 = {A#11,T#5,A#16} Delta2 = {E#2,E#8} Delta3 = {((var X#6),A#16), (A#13[(var X#14)],A#16), ((letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[(dummy3 )]),(letrec {X#6=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]]), ((var X#6),A#16[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(var X#14)], E#2 |-> {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]}, A#11 |-> A#16[[.]], T#5 |-> A#16, A#17 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) <-ucp1- (letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[A#13[(var X#14)]]) ................................................................................ (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#16[(var X#6)]) -SR,lapp3-> (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(letrec {E#8} in (app S#10 S#9))]} in A#16[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#13[(var X#14)]) , (letrec X#6= A#13[(var X#14)] ;E#7 ;EE#15[X#14,(letrec {E#8} in (app S#10 S#9))] in (var X#6) ) ) where Delta1 = {} Delta2 = {E#2,E#8} Delta3 = {((var X#6),[.]), (A#13[(var X#14)],[.]), ((letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in (dummy3 )),(letrec {X#6=(dummy3 )} in [.])), (A#13[(var X#14)],(letrec {X#6=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#6),[.]), ((var X#6),[.]), ((var X#6),[.])} Delta4= {} from overlapping <-SR,lapp3- . -ucp1-> with input rules: T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] <-ucp1- T#4[(letrec {E#2} in T#5[S#3])] and constraints: E#2/= {}, ((var X#1),T#5), (S#3,T#5), ((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#3,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)]) -SR,lapp3-> (letrec {E#7;EE#12[X#6,(letrec {E#8} in (app S#10 S#9))]} in A#11[(var X#6)]) and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#4[(letrec {X#1=S#3;E#2} in T#5[(var X#1)])] =?= (letrec {E#7;EE#12[X#6,(app (letrec {E#8} in S#10) S#9)]} in A#11[(var X#6)])} Delta1= {} Delta2= {E#2,E#8} Delta3= {((var X#1),T#5),(S#3,T#5),((letrec {E#2} in T#5[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])),(S#3,(letrec {X#1=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#1),T#5[[.]]),((var X#6),A#11[[.]]),((var X#6),A#11[[.]])} and found solution: Sol = {T#4 |-> [.], EE#12[.1,.2] |-> {[.1]=A#13[(var X#14)];EE#15[X#14,[.2]]}, X#1 |-> X#6, S#3 |-> A#13[(var X#14)], E#2 |-> {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]}, T#5 |-> [.], A#11 |-> [.], X#6 |-> X#6} and instantiated rules: (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in (var X#6)) <-ucp1- (letrec {E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in A#13[(var X#14)]) ................................................................................ (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(app (letrec {E#8} in S#10) S#9)]} in (var X#6)) -SR,lapp3-> (letrec {X#6=A#13[(var X#14)];E#7;EE#15[X#14,(letrec {E#8} in (app S#10 S#9))]} in (var X#6)) ================================================================================ Critical Pair: ( A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] , A#12[(letrec {X#8=T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#10)] ) where Delta1 = {T#13,A#11,T#6,A#12} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#8.[.])), (T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#8=[.]} in S#10)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (\ X#8.S#10) S#9)] -SR,lbeta1-> A#11[(letrec {X#8=S#9} in S#10)] and constraints: (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (\ X#8.S#10) S#9)]} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(\ X#8.[.])),(S#9,(letrec {X#8=[.]} in S#10)),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (\ X#8.S#10) T#14)], T#13 |-> (app (\ X#8.S#10) T#14), S#9 |-> T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] <-ucp2- A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ................................................................................ A#12[(app (\ X#8.S#10) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] -SR,lbeta1-> A#12[(letrec {X#8=T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#10)] ================================================================================ Critical Pair: ( A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] , A#12[(app A#13[(letrec {X#8=S#9} in S#10)] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) where Delta1 = {A#11,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (\ X#8.S#10) S#9)] -SR,lbeta1-> A#11[(letrec {X#8=S#9} in S#10)] and constraints: (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (\ X#8.S#10) S#9)]} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(\ X#8.[.])),(S#9,(letrec {X#8=[.]} in S#10)),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14)], A#11 |-> A#12[(app A#13 T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] <-ucp2- A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ................................................................................ A#12[(app A#13[(app (\ X#8.S#10) S#9)] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] -SR,lbeta1-> A#12[(app A#13[(letrec {X#8=S#9} in S#10)] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ================================================================================ Critical Pair: ( (app (\ X#8.S#10) T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)]) , (letrec {X#8=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#10) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#8.[.])), (T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#8=[.]} in S#10)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (\ X#8.S#10) S#9)] -SR,lbeta1-> A#11[(letrec {X#8=S#9} in S#10)] and constraints: (S#9,(\ X#8.[.])), (S#9,(letrec {X#8=[.]} in S#10)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (\ X#8.S#10) S#9)]} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(\ X#8.[.])),(S#9,(letrec {X#8=[.]} in S#10)),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (\ X#8.S#10) T#12), S#9 |-> T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (app (\ X#8.S#10) T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) <-ucp2- (app (\ X#8.S#10) T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ................................................................................ (app (\ X#8.S#10) T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) -SR,lbeta1-> (letrec {X#8=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#10) ================================================================================ Critical Pair: ( (letrec E#9 in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec E#9 in A#14[(letrec {X#8=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#11)] ) ) where Delta1 = {T#15,A#12,T#13,T#6,A#14} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#8.[.])), (T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16)]), A#12 |-> A#14, T#13 |-> A#14[(app (\ X#8.S#11) T#16)], T#15 |-> (app (\ X#8.S#11) T#16), S#10 |-> T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {E#9} in A#14[(app (\ X#8.S#11) T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,lbeta2-> (letrec {E#9} in A#14[(letrec {X#8=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#11)]) ================================================================================ Critical Pair: ( (letrec E#9 in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec E#9 in A#14[(app A#15[(letrec {X#8=S#10} in S#11)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16)]), T#13 |-> A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {E#9} in A#14[(app A#15[(app (\ X#8.S#11) S#10)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,lbeta2-> (letrec {E#9} in A#14[(app A#15[(letrec {X#8=S#10} in S#11)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])) , (letrec E#9 in (letrec {X#8=T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#11) ) ) where Delta1 = {T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#8.[.])), (T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#8=[.]} in S#11)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9} in (app (\ X#8.S#11) T#14)), A#12 |-> [.], T#13 |-> (app (\ X#8.S#11) T#14), S#10 |-> T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) <-ucp2- (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])) ................................................................................ (letrec {E#9} in (app (\ X#8.S#11) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) -SR,lbeta2-> (letrec {E#9} in (letrec {X#8=T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#11)) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;E#16 in A#12[(app (\ X#8.S#11) S#10)] ) , (letrec X#14= T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#16 in A#12[(letrec {X#8=S#10} in S#11)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;E#16} in A#12[(app (\ X#8.S#11) S#10)]), E#9 |-> {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in A#12[(app (\ X#8.S#11) S#10)]) <-ucp2- (letrec {X#14=T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#16} in A#12[(app (\ X#8.S#11) S#10)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in A#12[(letrec {X#8=S#10} in S#11)]) ================================================================================ Critical Pair: ( (letrec {X#1=T#7[S#4];E#14} in A#12[(app (\ X#8.S#11) S#10)]) , (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(letrec {X#8=S#10} in S#11)]) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#14} in A#12[(app (\ X#8.S#11) S#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {E#9} in A#12[(letrec {X#8=S#10} in S#11)]) and constraints: E#9/= {}, (S#10,(\ X#8.[.])), (S#10,(letrec {X#8=[.]} in S#11)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9} in A#12[(app (\ X#8.S#11) S#10)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(\ X#8.[.])),(S#10,(letrec {X#8=[.]} in S#11)),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(app (\ X#8.S#11) S#10)], E#9 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#14}, E#13 |-> {X#1=T#7[(var X#2)];E#14}, E#3 |-> {E#14}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(app (\ X#8.S#11) S#10)]) <-ucp2- (letrec {X#1=T#7[S#4];E#14} in A#12[(app (\ X#8.S#11) S#10)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(app (\ X#8.S#11) S#10)]) -SR,lbeta2-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(letrec {X#8=S#10} in S#11)]) ================================================================================ Critical Pair: ( (letrec E#10 ;EE#14[X#8,(app (\ X#9.S#12) S#11)] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec E#10 ;EE#14[X#8,(letrec {X#9=S#11} in S#12)] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18)]), T#15 |-> A#16[(app A#17[(var X#8)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;E#18 ;EE#14[X#8,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#18 ;EE#14[X#8,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]), E#10 |-> {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18}, E#17 |-> {E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#10 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec {X#9=T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12)] ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#19} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#9.[.])), (T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (\ X#9.S#12) T#21)];E#10} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#10}, A#18 |-> A#19, T#15 |-> A#19[(app (\ X#9.S#12) T#21)], T#20 |-> (app (\ X#9.S#12) T#21), S#11 |-> T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=A#19[(letrec {X#9=T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12)];E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#10 in A#13[(var X#8)] ) , (letrec X#8= A#19[(app A#20[(letrec {X#9=S#11} in S#12)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)];E#10} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]}, X#16 |-> X#8, E#17 |-> {E#10}, T#15 |-> A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=A#19[(app A#20[(letrec {X#9=S#11} in S#12)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (\ X#9.S#12) T#19[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ;E#10 in A#13[(var X#8)] ) , (letrec X#8= (letrec {X#9=T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#9.[.])), (T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (\ X#9.S#12) T#19);E#10} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#10}, A#18 |-> [.], T#15 |-> (app (\ X#9.S#12) T#19), S#11 |-> T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=(app (\ X#9.S#12) T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#10} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (\ X#9.S#12) T#19[(letrec {X#1=T#7[S#4];E#3} in S#5)]);E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (\ X#9.S#12) T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=(letrec {X#9=T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#10 ;EE#20[X#19,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#10 ;EE#20[X#19,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23)];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#8, E#17 |-> {E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#19,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#19,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#10 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#10 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#21[X#8,(var X#19)];EE#22[X#20,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {X#9=T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12)] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#21} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#9.[.])), (T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (\ X#9.S#12) T#23)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#10;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (\ X#9.S#12) T#23)], T#22 |-> (app (\ X#9.S#12) T#23), S#11 |-> T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#19=A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (\ X#9.S#12) T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(letrec {X#9=T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(app A#22[(letrec {X#9=S#11} in S#12)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#10;EE#20[X#8,(var X#19)]}, T#15 |-> A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(app (\ X#9.S#12) S#11)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=A#21[(app A#22[(letrec {X#9=S#11} in S#12)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (\ X#9.S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {X#9=T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12) ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(\ X#9.[.])), (T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (\ X#9.S#12) T#21);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#10;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (\ X#9.S#12) T#21), S#11 |-> T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#19=(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)]);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (\ X#9.S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#19=(letrec {X#9=T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} in S#12);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= T#7[S#4] ;E#16 ;EE#14[X#8,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;E#16 ;EE#14[X#8,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#16}, E#15 |-> {X#1=T#7[(var X#2)];E#16}, E#3 |-> {E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#1=T#7[S#4];E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=A#17[(app (\ X#9.S#12) T#19[S#4])];E#15} in A#13[(var X#8)]) , (letrec X#2= S#4 ;X#8= A#17[(letrec {X#9=T#19[(var X#2)]} in S#12)] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#18,A#16,T#7,A#17} Delta2 = {} Delta3 = {((var X#2),A#17[(app (\ X#9.S#12) T#19)]), (S#4,A#17[(app (\ X#9.S#12) T#19)]), ((letrec {X#8=A#17[(app (\ X#9.S#12) T#19[(dummy3 )])];E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#19[(var X#2)],(\ X#9.[.])), (T#19[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),A#17[(app (\ X#9.S#12) T#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> A#17, T#7 |-> A#17[(app (\ X#9.S#12) T#19)], T#18 |-> (app (\ X#9.S#12) T#19), S#11 |-> T#19[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=A#17[(app (\ X#9.S#12) T#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#17[(app (\ X#9.S#12) T#19[S#4])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#17[(app (\ X#9.S#12) T#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=S#4;X#8=A#17[(letrec {X#9=T#19[(var X#2)]} in S#12)];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19[S#4])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#17[(app A#18[(letrec {X#9=S#11} in S#12)] T#19[(var X#2)])] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {} Delta3 = {((var X#2),A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19)]), (S#4,A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19)]), ((letrec {X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19[(dummy3 )])];E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(var X#2)])]}, X#1 |-> X#8, E#3 |-> {E#15}, T#7 |-> A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19)], A#16 |-> A#17[(app A#18 T#19[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19[S#4])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#17[(app A#18[(app (\ X#9.S#12) S#11)] T#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=S#4;X#8=A#17[(app A#18[(letrec {X#9=S#11} in S#12)] T#19[(var X#2)])];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=(app (\ X#9.S#12) T#17[S#4]);E#15} in A#13[(var X#8)]) , (letrec X#2= S#4 ;X#8= (letrec {X#9=T#17[(var X#2)]} in S#12) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#7} Delta2 = {} Delta3 = {((var X#2),(app (\ X#9.S#12) T#17)), (S#4,(app (\ X#9.S#12) T#17)), ((letrec {X#8=(app (\ X#9.S#12) T#17[(dummy3 )]);E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#17[(var X#2)],(\ X#9.[.])), (T#17[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),(app (\ X#9.S#12) T#17[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> [.], T#7 |-> (app (\ X#9.S#12) T#17), S#11 |-> T#17[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=(app (\ X#9.S#12) T#17[(var X#2)]);E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (\ X#9.S#12) T#17[S#4]);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=(app (\ X#9.S#12) T#17[(var X#2)]);E#15} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=S#4;X#8=(letrec {X#9=T#17[(var X#2)]} in S#12);E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app A#20[(var X#17)] T#21[S#4])] ;E#15 ;EE#18[X#17,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#19[(app A#20[(var X#17)] T#21[(var X#2)])] ;E#15 ;EE#18[X#17,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {} Delta3 = {((var X#2),A#19[(app A#20[(var X#17)] T#21)]), (S#4,A#19[(app A#20[(var X#17)] T#21)]), ((letrec {X#8=A#19[(app A#20[(var X#17)] T#21[(dummy3 )])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#19[(app A#20[(var X#17)] T#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];EE#18[X#17,[.2]]}, X#1 |-> X#8, E#3 |-> {E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]}, T#7 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#8=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app A#20[(var X#17)] T#21[S#4])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#2=S#4;X#8=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[S#4])] ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(var X#2)])] ;X#2= S#4 ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {} Delta3 = {((var X#2),A#21[(app A#22[(var X#18)] T#23)]), (S#4,A#21[(app A#22[(var X#18)] T#23)]), ((letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(dummy3 )])];E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#21[(app A#22[(var X#18)] T#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, E#3 |-> {E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]}, T#7 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(var X#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[S#4])];E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (\ X#9.S#12) T#21[S#4])] ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {X#9=T#21[(var X#2)]} in S#12)] ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#16,T#7,A#19} Delta2 = {} Delta3 = {((var X#2),A#19[(app (\ X#9.S#12) T#21)]), (S#4,A#19[(app (\ X#9.S#12) T#21)]), ((letrec {X#17=A#19[(app (\ X#9.S#12) T#21[(dummy3 )])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#21[(var X#2)],(\ X#9.[.])), (T#21[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),A#19[(app (\ X#9.S#12) T#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, T#7 |-> A#19[(app (\ X#9.S#12) T#21)], T#20 |-> (app (\ X#9.S#12) T#21), S#11 |-> T#21[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (\ X#9.S#12) T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#19[(app (\ X#9.S#12) T#21[S#4])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (\ X#9.S#12) T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#19[(letrec {X#9=T#21[(var X#2)]} in S#12)];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[S#4])] ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(app A#20[(letrec {X#9=S#11} in S#12)] T#21[(var X#2)])] ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {} Delta3 = {((var X#2),A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)]), (S#4,A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)]), ((letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(dummy3 )])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#2),A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(var X#2)])];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, T#7 |-> A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21)], A#16 |-> A#19[(app A#20 T#21[(var X#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[S#4])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (\ X#9.S#12) S#11)] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=A#19[(app A#20[(letrec {X#9=S#11} in S#12)] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (\ X#9.S#12) T#19[S#4]) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {X#9=T#19[(var X#2)]} in S#12) ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#7} Delta2 = {} Delta3 = {((var X#2),(app (\ X#9.S#12) T#19)), (S#4,(app (\ X#9.S#12) T#19)), ((letrec {X#17=(app (\ X#9.S#12) T#19[(dummy3 )]);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#19[(var X#2)],(\ X#9.[.])), (T#19[(var X#2)],(letrec {X#9=[.]} in S#12)), ((var X#2),(app (\ X#9.S#12) T#19[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#10 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], T#7 |-> (app (\ X#9.S#12) T#19), S#11 |-> T#19[(var X#2)]} and instantiated rules: (letrec {X#17=(app (\ X#9.S#12) T#19[(var X#2)]);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=(app (\ X#9.S#12) T#19[S#4]);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (\ X#9.S#12) T#19[(var X#2)]);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#17=(letrec {X#9=T#19[(var X#2)]} in S#12);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[A#15[(var X#17)]] ;E#10 ;EE#19[X#17,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= A#21[(var X#16)] ;E#10 ;EE#19[X#17,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21[[.]]), (A#15[(var X#17)],A#21[[.]]), ((letrec {X#8=A#21[(dummy3 )];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=A#21[(var X#16)];EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#3 |-> {E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]}, A#20 |-> A#21, T#7 |-> A#21[[.]], T#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#21[A#15[(var X#17)]];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#10;EE#19[X#17,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[A#15[(var X#17)]] ;E#10 ;EE#19[X#17,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= A#21[(var X#16)] ;E#10 ;EE#19[X#17,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21), (A#15[(var X#17)],A#21), ((letrec {X#8=A#21[(dummy3 )];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=A#21[(var X#16)];EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#3 |-> {E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]}, A#20 |-> A#21[[.]], T#7 |-> A#21, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#21[A#15[(var X#17)]];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#10;EE#19[X#17,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#15[(var X#17)] ;E#10 ;EE#19[X#17,(app (\ X#9.S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= (var X#16) ;E#10 ;EE#19[X#17,(letrec {X#9=S#11} in S#12)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), (A#15[(var X#17)],[.]), ((letrec {X#8=(dummy3 );E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=(var X#16);EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]}, T#7 |-> [.], A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=(var X#16);E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#15[(var X#17)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=(var X#16);E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#8=(var X#16);E#10;EE#19[X#17,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#15[(var X#17)]] ;E#10 ;EE#19[X#17,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= A#23[(var X#16)] ;E#10 ;EE#19[X#17,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#23} Delta2 = {} Delta3 = {((var X#16),A#23[[.]]), (A#15[(var X#17)],A#23[[.]]), ((letrec {X#21=A#23[(dummy3 )];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23, T#7 |-> A#23[[.]], T#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#21=A#23[A#15[(var X#17)]];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;EE#19[X#17,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#15[(var X#17)]] ;E#10 ;EE#19[X#17,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= A#23[(var X#16)] ;E#10 ;EE#19[X#17,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#23} Delta2 = {} Delta3 = {((var X#16),A#23), (A#15[(var X#17)],A#23), ((letrec {X#21=A#23[(dummy3 )];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23[[.]], T#7 |-> A#23, A#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#21=A#23[A#15[(var X#17)]];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;EE#19[X#17,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#21= A#15[(var X#17)] ;E#10 ;EE#19[X#17,(app (\ X#9.S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= (var X#16) ;E#10 ;EE#19[X#17,(letrec {X#9=S#11} in S#12)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), (A#15[(var X#17)],[.]), ((letrec {X#21=(dummy3 );E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=(var X#16);EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]}, T#7 |-> [.], A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#21=A#15[(var X#17)];E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#10;EE#19[X#17,(app (\ X#9.S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#10;EE#19[X#17,(letrec {X#9=S#11} in S#12)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=A#19[A#15[(app (\ X#9.S#12) S#11)]];E#10} in A#13[(var X#8)]) , (letrec X#16= A#15[(letrec {X#9=S#11} in S#12)] ;X#8= A#19[(var X#16)] ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#19} Delta2 = {} Delta3 = {((var X#16),A#19[[.]]), (A#15[(app (\ X#9.S#12) S#11)],A#19[[.]]), ((letrec {X#8=A#19[(dummy3 )];E#10} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (\ X#9.S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#19[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, S#4 |-> A#15[(app (\ X#9.S#12) S#11)], EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#8, E#3 |-> {E#10}, A#18 |-> A#19, T#7 |-> A#19[[.]], T#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#8=A#19[(var X#16)];E#10} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[A#15[(app (\ X#9.S#12) S#11)]];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#8=A#19[(var X#16)];E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#9=S#11} in S#12)];X#8=A#19[(var X#16)];E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=A#19[A#15[(app (\ X#9.S#12) S#11)]];E#10} in A#13[(var X#8)]) , (letrec X#16= A#15[(letrec {X#9=S#11} in S#12)] ;X#8= A#19[(var X#16)] ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#19} Delta2 = {} Delta3 = {((var X#16),A#19), (A#15[(app (\ X#9.S#12) S#11)],A#19), ((letrec {X#8=A#19[(dummy3 )];E#10} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (\ X#9.S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#19[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, S#4 |-> A#15[(app (\ X#9.S#12) S#11)], EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#8, E#3 |-> {E#10}, A#18 |-> A#19[[.]], T#7 |-> A#19, A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#8=A#19[(var X#16)];E#10} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[A#15[(app (\ X#9.S#12) S#11)]];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#8=A#19[(var X#16)];E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#9=S#11} in S#12)];X#8=A#19[(var X#16)];E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=A#15[(app (\ X#9.S#12) S#11)];E#10} in A#13[(var X#8)]) , (letrec X#16= A#15[(letrec {X#9=S#11} in S#12)] ;X#8= (var X#16) ;E#10 in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), (A#15[(app (\ X#9.S#12) S#11)],[.]), ((letrec {X#8=(dummy3 );E#10} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (\ X#9.S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=(var X#16)}, X#2 |-> X#16, S#4 |-> A#15[(app (\ X#9.S#12) S#11)], EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#10}, T#7 |-> [.], A#18 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#8=(var X#16);E#10} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#15[(app (\ X#9.S#12) S#11)];E#10} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#8=(var X#16);E#10} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#9=S#11} in S#12)];X#8=(var X#16);E#10} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#15[(app (\ X#9.S#12) S#11)]] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {X#9=S#11} in S#12)] ;X#19= A#21[(var X#16)] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21[[.]]), (A#15[(app (\ X#9.S#12) S#11)],A#21[[.]]), ((letrec {X#19=A#21[(dummy3 )];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (\ X#9.S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(app (\ X#9.S#12) S#11)], EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {E#10;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#7 |-> A#21[[.]], T#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#19=A#21[(var X#16)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[A#15[(app (\ X#9.S#12) S#11)]];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#19=A#21[(var X#16)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#9=S#11} in S#12)];X#19=A#21[(var X#16)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#15[(app (\ X#9.S#12) S#11)]] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {X#9=S#11} in S#12)] ;X#19= A#21[(var X#16)] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#21} Delta2 = {} Delta3 = {((var X#16),A#21), (A#15[(app (\ X#9.S#12) S#11)],A#21), ((letrec {X#19=A#21[(dummy3 )];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (\ X#9.S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(app (\ X#9.S#12) S#11)], EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {E#10;EE#20[X#8,(var X#19)]}, A#18 |-> A#21[[.]], T#7 |-> A#21, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#19=A#21[(var X#16)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[A#15[(app (\ X#9.S#12) S#11)]];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#19=A#21[(var X#16)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#9=S#11} in S#12)];X#19=A#21[(var X#16)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#15[(app (\ X#9.S#12) S#11)] ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {X#9=S#11} in S#12)] ;X#19= (var X#16) ;E#10 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), (A#15[(app (\ X#9.S#12) S#11)],[.]), ((letrec {X#19=(dummy3 );E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (\ X#9.S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {E#10;EE#14[X#8,(letrec {X#9=S#11} in S#12)]} in A#13[(var X#8)]) and constraints: (S#11,(\ X#9.[.])), (S#11,(letrec {X#9=[.]} in S#12)) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#10;EE#14[X#8,(app (\ X#9.S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(\ X#9.[.])),(S#11,(letrec {X#9=[.]} in S#12)),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=(var X#16);EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(app (\ X#9.S#12) S#11)], EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {E#10;EE#20[X#8,(var X#19)]}, T#7 |-> [.], A#18 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#19=(var X#16);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#15[(app (\ X#9.S#12) S#11)];E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (\ X#9.S#12) S#11)];X#19=(var X#16);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lbeta3-> (letrec {X#16=A#15[(letrec {X#9=S#11} in S#12)];X#19=(var X#16);E#10;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#11) ;E#10 in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec X#8= (\ X#9.S#11) ;E#10 in A#14[(app A#15[(\ X#9.S#11)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16)]), T#13 |-> A#14[(app A#15[(var X#8)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#14[(app A#15[(\ X#9.S#11)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;X#8= (\ X#9.S#11) ;E#16 in A#12[(var X#8)] ) , (letrec X#14= T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= (\ X#9.S#11) ;E#16 in A#12[(\ X#9.S#11)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]), E#10 |-> {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16}, E#15 |-> {X#8=(\ X#9.S#11);E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]) <-ucp2- (letrec {X#14=T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#11);E#16} in A#12[(\ X#9.S#11)]) ================================================================================ Critical Pair: ( (letrec {X#1=T#7[S#4];X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;X#8= (\ X#9.S#11) ;E#14 in A#12[(\ X#9.S#11)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(\ X#9.S#11)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#14}, E#13 |-> {X#1=T#7[(var X#2)];E#14}, E#3 |-> {X#8=(\ X#9.S#11);E#14}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) <-ucp2- (letrec {X#1=T#7[S#4];X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#11);E#14} in A#12[(var X#8)]) -SR,cp-in1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#11);E#14} in A#12[(\ X#9.S#11)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#12) ;E#11 ;VV#14|X#10,(var X#8)| in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec X#8= (\ X#9.S#12) ;E#11 ;VV#14|X#10,(var X#8)| in A#16[(app A#17[(\ X#9.S#12)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18)]), T#15 |-> A#16[(app A#17[(var X#10)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(var X#10)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#16[(app A#17[(\ X#9.S#12)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;X#8= (\ X#9.S#12) ;E#18 ;VV#14|X#10,(var X#8)| in A#13[(var X#10)] ) , (letrec X#16= T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= (\ X#9.S#12) ;E#18 ;VV#14|X#10,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {T#6} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]), E#11 |-> {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18}, E#17 |-> {X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) <-ucp2- (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#12);E#18;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec {X#10=(\ X#9.S#12);E#11} in A#13[(var X#10)]) , (letrec {X#10=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(\ X#9.S#12)]) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#8),[.]), ((\ X#9.S#12),[.]), ((letrec {X#10=(dummy3 );E#11} in A#13[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), VV#14|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {E#11}, T#7 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#10=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) <-ucp2- (letrec {X#10=(\ X#9.S#12);E#11} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec {X#16=(\ X#9.S#12);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) , (letrec X#16= (var X#8) ;X#8= (\ X#9.S#12) ;E#11 ;VV#17|X#10,(var X#16)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#8),[.]), ((\ X#9.S#12),[.]), ((letrec {X#16=(dummy3 );E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), VV#14|.1,.2| |-> {X#16=[.2];VV#17|[.1],(var X#16)|}, X#1 |-> X#16, E#3 |-> {E#11;VV#17|X#10,(var X#16)|}, T#7 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#16=(var X#8);X#8=(\ X#9.S#12);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) <-ucp2- (letrec {X#16=(\ X#9.S#12);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#8);X#8=(\ X#9.S#12);E#11;VV#17|X#10,(var X#16)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#8);X#8=(\ X#9.S#12);E#11;VV#17|X#10,(var X#16)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#1= T#7[S#4] ;X#8= (\ X#9.S#12) ;E#16 ;VV#14|X#10,(var X#8)| in A#13[(var X#10)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 ;VV#14|X#10,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], E#11 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#16}, E#15 |-> {X#1=T#7[(var X#2)];E#16}, E#3 |-> {X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) <-ucp2- (letrec {X#1=T#7[S#4];X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#12);E#16;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#10= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| in A#13[(var X#10)] ) , (letrec X#10= (var X#16) ;X#16= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#17),[.]), ((letrec {X#10=(dummy3 );X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]),(letrec {X#16=(dummy3 )} in [.])), ((var X#17),(letrec {X#16=(dummy3 )} in [.])), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=(var X#17);[.1]=(var X#16);VV#19|X#17,[.2]|}, X#2 |-> X#16, S#4 |-> (var X#17), VV#18|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|}, T#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#10=(var X#16);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) <-ucp2- (letrec {X#10=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#16);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#16);X#16=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#21= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| ;VV#22|X#10,(var X#21)| in A#13[(var X#10)] ) , (letrec X#16= (var X#17) ;X#21= (var X#16) ;X#8= (\ X#9.S#12) ;E#11 ;VV#19|X#17,(var X#8)| ;VV#22|X#10,(var X#21)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#17),[.]), ((letrec {X#21=(dummy3 );X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]),(letrec {X#16=(dummy3 )} in [.])), ((var X#17),(letrec {X#16=(dummy3 )} in [.])), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=(var X#17);X#21=(var X#16);VV#19|X#17,[.2]|;VV#22|[.1],(var X#21)|}, X#2 |-> X#16, S#4 |-> (var X#17), VV#18|.1,.2| |-> {X#21=[.2];VV#22|[.1],(var X#21)|}, X#1 |-> X#21, E#3 |-> {X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|}, T#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#17);X#21=(var X#16);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]) <-ucp2- (letrec {X#21=(var X#17);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#17);X#21=(var X#16);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#17);X#21=(var X#16);X#8=(\ X#9.S#12);E#11;VV#19|X#17,(var X#8)|;VV#22|X#10,(var X#21)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec {X#10=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) , (letrec X#10= (var X#16) ;X#16= (var X#8) ;X#8= (\ X#9.S#12) ;E#11 in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#8),[.]), ((letrec {X#10=(dummy3 );X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]),(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=(dummy3 )} in [.])), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=[.2];[.1]=(var X#16)}, X#2 |-> X#16, S#4 |-> (var X#8), VV#17|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11}, T#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#10=(var X#16);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) <-ucp2- (letrec {X#10=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) ................................................................................ (letrec {X#10=(var X#16);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#10=(var X#16);X#16=(var X#8);X#8=(\ X#9.S#12);E#11} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#19= (var X#8) ;X#8= (\ X#9.S#12) ;E#11 ;VV#20|X#10,(var X#19)| in A#13[(var X#10)] ) , (letrec X#16= (var X#8) ;X#19= (var X#16) ;X#8= (\ X#9.S#12) ;E#11 ;VV#20|X#10,(var X#19)| in A#13[(\ X#9.S#12)] ) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#16),[.]), ((var X#8),[.]), ((letrec {X#19=(dummy3 );X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]),(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=(dummy3 )} in [.])), ((var X#16),[.]), ((var X#8),[.]), ((var X#10),A#13[[.]]), ((var X#8),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(\ X#9.S#12)]) and constraints: and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;VV#14|X#10,(var X#8)|} in A#13[(var X#10)])} Delta1= {} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#13[[.]]),((var X#8),[.])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#10)], VV#14|.1,.2| |-> {X#16=[.2];X#19=(var X#16);VV#20|[.1],(var X#19)|}, X#2 |-> X#16, S#4 |-> (var X#8), VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#1 |-> X#19, E#3 |-> {X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|}, T#7 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=(var X#8);X#19=(var X#16);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]) <-ucp2- (letrec {X#19=(var X#8);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]) ................................................................................ (letrec {X#16=(var X#8);X#19=(var X#16);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(var X#10)]) -SR,cp-in2-> (letrec {X#16=(var X#8);X#19=(var X#16);X#8=(\ X#9.S#12);E#11;VV#20|X#10,(var X#19)|} in A#13[(\ X#9.S#12)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#12) ;E#11 ;EE#15[X#10,A#13[(var X#8)]] in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec X#8= (\ X#9.S#12) ;E#11 ;EE#15[X#10,A#13[(\ X#9.S#12)]] in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#14,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#17[(app A#18[[.]] T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#10),A#17[(app A#18[[.]] T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19)]), T#16 |-> A#17[(app A#18[(var X#10)] T#19)], A#14 |-> A#17[(app A#18 T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#17[(app A#18[(var X#10)] T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#17= T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;X#8= (\ X#9.S#12) ;E#19 ;EE#15[X#10,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#17= T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= (\ X#9.S#12) ;E#19 ;EE#15[X#10,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#17=T#16;X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]), E#11 |-> {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#19}, E#18 |-> {X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]}} and instantiated rules: (letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#17=T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#12);E#19;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {T#21,A#19,T#16,T#6,A#13,A#20} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#22[(app A#23[[.]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#20[[.2]]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> A#20, T#16 |-> A#20[A#22[(app A#23[(var X#8)] T#24)]], T#21 |-> A#22[(app A#23[(var X#8)] T#24)], A#13 |-> A#22[(app A#23 T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[A#13[(\ X#9.S#12)]] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11}, T#16 |-> A#20[(app A#21[A#13[(var X#8)]] T#22)], A#19 |-> A#20[(app A#21 T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[A#13[(var X#8)]] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(app A#21[A#13[(\ X#9.S#12)]] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(\ X#9.S#12)] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#20[(app A#21[[.]] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#20[(app A#21[(var X#8)] T#22)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=[.2]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> [.], T#16 |-> A#20[(app A#21[(var X#8)] T#22)], A#13 |-> A#20[(app A#21 T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#8)] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(app A#21[(\ X#9.S#12)] T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#20,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#20,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24)];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#21[X#20,[.2]]}, X#17 |-> X#10, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]}, T#16 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#20,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#20= A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26)];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]}, T#16 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#22[X#10,(var X#20)];EE#23[X#21,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[A#24[(app A#25[(\ X#9.S#12)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {T#23,A#19,T#16,T#6,A#13,A#22} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#24[(app A#25[[.]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26)]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, T#16 |-> A#22[A#24[(app A#25[(var X#8)] T#26)]], T#23 |-> A#24[(app A#25[(var X#8)] T#26)], A#13 |-> A#24[(app A#25 T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[A#24[(app A#25[(var X#8)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#22[A#24[(app A#25[(\ X#9.S#12)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[(app A#23[A#13[(\ X#9.S#12)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, T#16 |-> A#22[(app A#23[A#13[(var X#8)]] T#24)], A#19 |-> A#22[(app A#23 T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[(app A#23[A#13[(var X#8)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#22[(app A#23[A#13[(\ X#9.S#12)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#20= A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {T#16,T#6,A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#22[(app A#23[[.]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#20=A#22[(app A#23[(var X#8)] T#24)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]), EE#15[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#17 |-> X#20, E#18 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, A#19 |-> [.], T#16 |-> A#22[(app A#23[(var X#8)] T#24)], A#13 |-> A#22[(app A#23 T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#20=A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#20=A#22[(app A#23[(var X#8)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#20=A#22[(app A#23[(\ X#9.S#12)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#17[A#19[(\ X#9.S#12)]];E#11} in A#14[(var X#10)]) , (letrec X#10= A#17[A#19[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {T#18,A#16,T#7,A#13,A#17,A#19} Delta2 = {} Delta3 = {((var X#8),A#17[A#19[[.]]]), ((\ X#9.S#12),A#17[A#19[[.]]]), ((letrec {X#10=A#17[A#19[(dummy3 )]];E#11} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[A#19[[.]]]), ((var X#8),A#19[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#10, E#3 |-> {E#11}, A#16 |-> A#17, T#7 |-> A#17[A#19[[.]]], A#13 |-> A#19, T#18 |-> A#19[[.]], T#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#10=A#17[A#19[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#17[A#19[(\ X#9.S#12)]];E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#17[A#19[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#17[A#19[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#17[A#19[(\ X#9.S#12)]];E#11} in A#14[(var X#10)]) , (letrec X#10= A#17[A#19[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {T#18,A#16,T#7,A#13,A#17,A#19} Delta2 = {} Delta3 = {((var X#8),A#17[A#19]), ((\ X#9.S#12),A#17[A#19]), ((letrec {X#10=A#17[A#19[(dummy3 )]];E#11} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[A#19[[.]]]), ((var X#8),A#19[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#10, E#3 |-> {E#11}, A#16 |-> A#17, T#7 |-> A#17[A#19], A#13 |-> A#19[[.]], T#18 |-> A#19, A#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#10=A#17[A#19[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#17[A#19[(\ X#9.S#12)]];E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#17[A#19[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#17[A#19[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#17[(\ X#9.S#12)];E#11} in A#14[(var X#10)]) , (letrec {X#10=A#17[(\ X#9.S#12)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ) where Delta1 = {T#7,A#13,A#17} Delta2 = {} Delta3 = {((var X#8),A#17[[.]]), ((\ X#9.S#12),A#17[[.]]), ((letrec {X#10=A#17[(dummy3 )];E#11} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[[.]]), ((var X#8),A#17[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {E#11}, A#16 |-> [.], A#13 |-> A#17, T#7 |-> A#17[[.]], T#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#10=A#17[(var X#8)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#17[(\ X#9.S#12)];E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#17[(var X#8)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#17[(\ X#9.S#12)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#17[(\ X#9.S#12)];E#11} in A#14[(var X#10)]) , (letrec {X#10=A#17[(\ X#9.S#12)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ) where Delta1 = {T#7,A#13,A#17} Delta2 = {} Delta3 = {((var X#8),A#17), ((\ X#9.S#12),A#17), ((letrec {X#10=A#17[(dummy3 )];E#11} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#17[[.]]), ((var X#8),A#17[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {E#11}, A#16 |-> [.], A#13 |-> A#17[[.]], T#7 |-> A#17, A#18 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#10=A#17[(var X#8)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#17[(\ X#9.S#12)];E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#17[(var X#8)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#17[(\ X#9.S#12)];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(\ X#9.S#12)]] ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= A#19[A#21[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {T#20,A#16,T#7,A#13,A#19,A#21} Delta2 = {} Delta3 = {((var X#8),A#19[A#21[[.]]]), ((\ X#9.S#12),A#19[A#21[[.]]]), ((letrec {X#17=A#19[A#21[(dummy3 )]];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#19[A#21[[.]]]), ((var X#8),A#21[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#11;EE#18[X#10,(var X#17)]}, A#16 |-> A#19, T#7 |-> A#19[A#21[[.]]], A#13 |-> A#21, T#20 |-> A#21[[.]], T#22 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#17=A#19[A#21[(var X#8)]];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#17=A#19[A#21[(\ X#9.S#12)]];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#19[A#21[(var X#8)]];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(\ X#9.S#12)]] ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= A#19[A#21[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {T#20,A#16,T#7,A#13,A#19,A#21} Delta2 = {} Delta3 = {((var X#8),A#19[A#21]), ((\ X#9.S#12),A#19[A#21]), ((letrec {X#17=A#19[A#21[(dummy3 )]];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#19[A#21[[.]]]), ((var X#8),A#21[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#11;EE#18[X#10,(var X#17)]}, A#16 |-> A#19, T#7 |-> A#19[A#21], A#13 |-> A#21[[.]], T#20 |-> A#21, A#22 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#17=A#19[A#21[(var X#8)]];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#17=A#19[A#21[(\ X#9.S#12)]];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#19[A#21[(var X#8)]];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(\ X#9.S#12)] ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= A#19[(\ X#9.S#12)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {T#7,A#13,A#19} Delta2 = {} Delta3 = {((var X#8),A#19[[.]]), ((\ X#9.S#12),A#19[[.]]), ((letrec {X#17=A#19[(dummy3 )];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#19[[.]]), ((var X#8),A#19[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#11;EE#18[X#10,(var X#17)]}, A#16 |-> [.], A#13 |-> A#19, T#7 |-> A#19[[.]], T#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#17=A#19[(var X#8)];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#17=A#19[(\ X#9.S#12)];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#19[(var X#8)];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#19[(\ X#9.S#12)];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(\ X#9.S#12)] ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) , (letrec X#17= A#19[(\ X#9.S#12)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#18[X#10,(var X#17)] in A#14[(var X#10)] ) ) where Delta1 = {T#7,A#13,A#19} Delta2 = {} Delta3 = {((var X#8),A#19), ((\ X#9.S#12),A#19), ((letrec {X#17=A#19[(dummy3 )];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),A#19[[.]]), ((var X#8),A#19[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#12), EE#15[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#11;EE#18[X#10,(var X#17)]}, A#16 |-> [.], A#13 |-> A#19[[.]], T#7 |-> A#19, A#20 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#17=A#19[(var X#8)];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#17=A#19[(\ X#9.S#12)];E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#19[(var X#8)];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#19[(\ X#9.S#12)];X#8=(\ X#9.S#12);E#11;EE#18[X#10,(var X#17)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= T#7[S#4] ;X#8= (\ X#9.S#12) ;E#17 ;EE#15[X#10,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#17 ;EE#15[X#10,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#17}, E#16 |-> {X#1=T#7[(var X#2)];E#17}, E#3 |-> {X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#1=T#7[S#4];X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#12);E#17;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[A#20[(app A#21[(var X#8)] T#22[S#4])]] ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[A#20[(app A#21[(\ X#9.S#12)] T#22[(var X#2)])]] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {T#19,A#17,T#7,A#13,A#18} Delta2 = {} Delta3 = {((var X#2),A#18[A#20[(app A#21[(var X#8)] T#22)]]), (S#4,A#18[A#20[(app A#21[(var X#8)] T#22)]]), ((letrec {X#10=A#18[A#20[(app A#21[(var X#8)] T#22[(dummy3 )])]];X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#18[A#20[(app A#21[(var X#8)] T#22[[.]])]]), ((var X#8),A#20[(app A#21[[.]] T#22[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {[.1]=A#18[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#16}, A#17 |-> A#18, T#7 |-> A#18[A#20[(app A#21[(var X#8)] T#22)]], T#19 |-> A#20[(app A#21[(var X#8)] T#22)], A#13 |-> A#20[(app A#21 T#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[A#20[(app A#21[(var X#8)] T#22[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#18[A#20[(app A#21[(var X#8)] T#22[S#4])]];X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[A#20[(app A#21[(var X#8)] T#22[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#18[A#20[(app A#21[(\ X#9.S#12)] T#22[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[(app A#19[A#13[(var X#8)]] T#20[S#4])] ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[(app A#19[A#13[(\ X#9.S#12)]] T#20[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {A#17,T#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#18[(app A#19[A#13[(var X#8)]] T#20)]), (S#4,A#18[(app A#19[A#13[(var X#8)]] T#20)]), ((letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] T#20[(dummy3 )])];X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#18[(app A#19[A#13[(var X#8)]] T#20[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {[.1]=A#18[(app A#19[[.2]] T#20[(var X#2)])]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#16}, T#7 |-> A#18[(app A#19[A#13[(var X#8)]] T#20)], A#17 |-> A#18[(app A#19 T#20[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] T#20[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] T#20[S#4])];X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[(app A#19[A#13[(var X#8)]] T#20[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#18[(app A#19[A#13[(\ X#9.S#12)]] T#20[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[(app A#19[(var X#8)] T#20[S#4])] ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) , (letrec X#10= A#18[(app A#19[(\ X#9.S#12)] T#20[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 in A#14[(var X#10)] ) ) where Delta1 = {T#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#18[(app A#19[(var X#8)] T#20)]), (S#4,A#18[(app A#19[(var X#8)] T#20)]), ((letrec {X#10=A#18[(app A#19[(var X#8)] T#20[(dummy3 )])];X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#18[(app A#19[(var X#8)] T#20[[.]])]), ((var X#8),A#18[(app A#19[[.]] T#20[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#16}, A#17 |-> [.], T#7 |-> A#18[(app A#19[(var X#8)] T#20)], A#13 |-> A#18[(app A#19 T#20[(var X#2)])]} and instantiated rules: (letrec {X#10=A#18[(app A#19[(var X#8)] T#20[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#18[(app A#19[(var X#8)] T#20[S#4])];X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#18[(app A#19[(var X#8)] T#20[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#18[(app A#19[(\ X#9.S#12)] T#20[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#18)] T#22[S#4])] ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#18,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(var X#18)] T#22[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#18,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#17,T#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[(var X#18)] T#22)]), (S#4,A#20[(app A#21[(var X#18)] T#22)]), ((letrec {X#10=A#20[(app A#21[(var X#18)] T#22[(dummy3 )])];X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[(app A#21[(var X#18)] T#22[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {[.1]=A#20[(app A#21[(var X#18)] T#22[(var X#2)])];EE#19[X#18,[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]}, T#7 |-> A#20[(app A#21[(var X#18)] T#22)], A#17 |-> A#20[(app A#21 T#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#18)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(app A#21[(var X#18)] T#22[S#4])];X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#18)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(app A#21[(var X#18)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#18,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#22[(app A#23[(var X#19)] T#24[S#4])] ;X#8= (\ X#9.S#12) ;E#16 ;EE#20[X#10,(var X#18)] ;EE#21[X#19,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#18= A#22[(app A#23[(var X#19)] T#24[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 ;EE#20[X#10,(var X#18)] ;EE#21[X#19,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#17,T#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[(var X#19)] T#24)]), (S#4,A#22[(app A#23[(var X#19)] T#24)]), ((letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(dummy3 )])];X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#22[(app A#23[(var X#19)] T#24[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {X#18=A#22[(app A#23[(var X#19)] T#24[(var X#2)])];EE#20[[.1],(var X#18)];EE#21[X#19,[.2]]}, X#1 |-> X#18, E#3 |-> {X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]}, T#7 |-> A#22[(app A#23[(var X#19)] T#24)], A#17 |-> A#22[(app A#23 T#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[S#4])];X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#22[(app A#23[(var X#19)] T#24[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#20[X#10,(var X#18)];EE#21[X#19,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[A#22[(app A#23[(var X#8)] T#24[S#4])]] ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[A#22[(app A#23[(\ X#9.S#12)] T#24[(var X#2)])]] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {T#21,A#17,T#7,A#13,A#20} Delta2 = {} Delta3 = {((var X#2),A#20[A#22[(app A#23[(var X#8)] T#24)]]), (S#4,A#20[A#22[(app A#23[(var X#8)] T#24)]]), ((letrec {X#18=A#20[A#22[(app A#23[(var X#8)] T#24[(dummy3 )])]];X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[A#22[(app A#23[(var X#8)] T#24[[.]])]]), ((var X#8),A#22[(app A#23[[.]] T#24[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {X#18=A#20[[.2]];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#3 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]}, A#17 |-> A#20, T#7 |-> A#20[A#22[(app A#23[(var X#8)] T#24)]], T#21 |-> A#22[(app A#23[(var X#8)] T#24)], A#13 |-> A#22[(app A#23 T#24[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[A#22[(app A#23[(var X#8)] T#24[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#18=A#20[A#22[(app A#23[(var X#8)] T#24[S#4])]];X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[A#22[(app A#23[(var X#8)] T#24[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#20[A#22[(app A#23[(\ X#9.S#12)] T#24[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[A#13[(var X#8)]] T#22[S#4])] ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[(app A#21[A#13[(\ X#9.S#12)]] T#22[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {A#17,T#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[A#13[(var X#8)]] T#22)]), (S#4,A#20[(app A#21[A#13[(var X#8)]] T#22)]), ((letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] T#22[(dummy3 )])];X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[(app A#21[A#13[(var X#8)]] T#22[[.]])]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {X#18=A#20[(app A#21[[.2]] T#22[(var X#2)])];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#3 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]}, T#7 |-> A#20[(app A#21[A#13[(var X#8)]] T#22)], A#17 |-> A#20[(app A#21 T#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] T#22[S#4])];X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[(app A#21[A#13[(var X#8)]] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[A#13[(\ X#9.S#12)]] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#18= A#20[(app A#21[(var X#8)] T#22[S#4])] ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) , (letrec X#18= A#20[(app A#21[(\ X#9.S#12)] T#22[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#12) ;E#16 ;EE#19[X#10,(var X#18)] in A#14[(var X#10)] ) ) where Delta1 = {T#7,A#13} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[(var X#8)] T#22)]), (S#4,A#20[(app A#21[(var X#8)] T#22)]), ((letrec {X#18=A#20[(app A#21[(var X#8)] T#22[(dummy3 )])];X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[(app A#21[(var X#8)] T#22[[.]])]), ((var X#8),A#20[(app A#21[[.]] T#22[(var X#2)])]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], E#11 |-> {X#2=S#4;E#16}, EE#15[.1,.2] |-> {X#18=[.2];EE#19[[.1],(var X#18)]}, X#1 |-> X#18, E#3 |-> {X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]}, A#17 |-> [.], T#7 |-> A#20[(app A#21[(var X#8)] T#22)], A#13 |-> A#20[(app A#21 T#22[(var X#2)])]} and instantiated rules: (letrec {X#18=A#20[(app A#21[(var X#8)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#18=A#20[(app A#21[(var X#8)] T#22[S#4])];X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#18=A#20[(app A#21[(var X#8)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#18=A#20[(app A#21[(\ X#9.S#12)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#12);E#16;EE#19[X#10,(var X#18)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#16[(var X#18)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(var X#17)] ;X#17= A#16[(var X#18)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22[[.]]), (A#16[(var X#18)],A#22[[.]]), ((letrec {X#10=A#22[(dummy3 )];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[(var X#18)],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#22[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[(var X#18)];[.1]=A#22[(var X#17)];EE#20[X#18,[.2]]}, X#2 |-> X#17, S#4 |-> A#16[(var X#18)], EE#19[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]}, A#21 |-> A#22, T#7 |-> A#22[[.]], T#23 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=A#22[(var X#17)];X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#16[(var X#18)]];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#17)];X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(var X#17)];X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#16[(var X#18)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= A#22[(var X#17)] ;X#17= A#16[(var X#18)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22), (A#16[(var X#18)],A#22), ((letrec {X#10=A#22[(dummy3 )];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[(var X#18)],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#22[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[(var X#18)];[.1]=A#22[(var X#17)];EE#20[X#18,[.2]]}, X#2 |-> X#17, S#4 |-> A#16[(var X#18)], EE#19[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]}, A#21 |-> A#22[[.]], T#7 |-> A#22, A#23 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=A#22[(var X#17)];X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#16[(var X#18)]];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#17)];X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#22[(var X#17)];X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#16[(var X#18)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(var X#8)]] in A#14[(var X#10)] ) , (letrec X#10= (var X#17) ;X#17= A#16[(var X#18)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(\ X#9.S#12)]] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),[.]), (A#16[(var X#18)],[.]), ((letrec {X#10=(dummy3 );X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[(var X#18)],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),[.]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[(var X#18)];[.1]=(var X#17);EE#20[X#18,[.2]]}, X#2 |-> X#17, S#4 |-> A#16[(var X#18)], EE#19[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]}, T#7 |-> [.], A#21 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=(var X#17);X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#17);X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#17);X#17=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#16[(var X#18)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= A#16[(var X#18)] ;X#22= A#24[(var X#17)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#13,A#24} Delta2 = {} Delta3 = {((var X#17),A#24[[.]]), (A#16[(var X#18)],A#24[[.]]), ((letrec {X#22=A#24[(dummy3 )];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[(var X#18)],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#24[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];EE#20[X#18,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, S#4 |-> A#16[(var X#18)], EE#19[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, A#21 |-> A#24, T#7 |-> A#24[[.]], T#25 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#16[(var X#18)]];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#16[(var X#18)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= A#16[(var X#18)] ;X#22= A#24[(var X#17)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#13,A#24} Delta2 = {} Delta3 = {((var X#17),A#24), (A#16[(var X#18)],A#24), ((letrec {X#22=A#24[(dummy3 )];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[(var X#18)],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#24[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];EE#20[X#18,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, S#4 |-> A#16[(var X#18)], EE#19[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, A#21 |-> A#24[[.]], T#7 |-> A#24, A#25 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#16[(var X#18)]];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#16[(var X#18)];X#22=A#24[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#16[(var X#18)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(var X#8)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) , (letrec X#17= A#16[(var X#18)] ;X#22= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;EE#20[X#18,A#13[(\ X#9.S#12)]] ;EE#23[X#10,(var X#22)] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),[.]), (A#16[(var X#18)],[.]), ((letrec {X#22=(dummy3 );X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[(var X#18)],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),[.]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[(var X#18)];X#22=(var X#17);EE#20[X#18,[.2]];EE#23[[.1],(var X#22)]}, X#2 |-> X#17, S#4 |-> A#16[(var X#18)], EE#19[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]}, T#7 |-> [.], A#21 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=A#16[(var X#18)];X#22=(var X#17);X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#22=A#16[(var X#18)];X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#16[(var X#18)];X#22=(var X#17);X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(var X#8)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#16[(var X#18)];X#22=(var X#17);X#8=(\ X#9.S#12);E#11;EE#20[X#18,A#13[(\ X#9.S#12)]];EE#23[X#10,(var X#22)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#16[A#13[(var X#8)]]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[(var X#17)] ;X#17= A#16[A#13[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#13,A#20} Delta2 = {} Delta3 = {((var X#17),A#20[[.]]), (A#16[A#13[(var X#8)]],A#20[[.]]), ((letrec {X#10=A#20[(dummy3 )];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[A#13[(var X#8)]],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#20[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[[.2]];[.1]=A#20[(var X#17)]}, X#2 |-> X#17, S#4 |-> A#16[A#13[(var X#8)]], EE#18[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> A#20, T#7 |-> A#20[[.]], T#21 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=A#20[(var X#17)];X#17=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#20[A#16[A#13[(var X#8)]]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(var X#17)];X#17=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(var X#17)];X#17=A#16[A#13[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#16[A#13[(var X#8)]]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) , (letrec X#10= A#20[(var X#17)] ;X#17= A#16[A#13[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#13,A#20} Delta2 = {} Delta3 = {((var X#17),A#20), (A#16[A#13[(var X#8)]],A#20), ((letrec {X#10=A#20[(dummy3 )];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[A#13[(var X#8)]],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#20[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[[.2]];[.1]=A#20[(var X#17)]}, X#2 |-> X#17, S#4 |-> A#16[A#13[(var X#8)]], EE#18[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11}, A#19 |-> A#20[[.]], T#7 |-> A#20, A#21 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=A#20[(var X#17)];X#17=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#20[A#16[A#13[(var X#8)]]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(var X#17)];X#17=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=A#20[(var X#17)];X#17=A#16[A#13[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) , (letrec X#10= (var X#17) ;X#17= A#16[A#13[(\ X#9.S#12)]] ;X#8= (\ X#9.S#12) ;E#11 in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),[.]), (A#16[A#13[(var X#8)]],[.]), ((letrec {X#10=(dummy3 );X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[A#13[(var X#8)]],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),[.]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[[.2]];[.1]=(var X#17)}, X#2 |-> X#17, S#4 |-> A#16[A#13[(var X#8)]], EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#12);E#11}, T#7 |-> [.], A#19 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#10=(var X#17);X#17=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) <-ucp2- (letrec {X#10=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ................................................................................ (letrec {X#10=(var X#17);X#17=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#10=(var X#17);X#17=A#16[A#13[(\ X#9.S#12)]];X#8=(\ X#9.S#12);E#11} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#16[A#13[(var X#8)]]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#17= A#16[A#13[(\ X#9.S#12)]] ;X#20= A#22[(var X#17)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22[[.]]), (A#16[A#13[(var X#8)]],A#22[[.]]), ((letrec {X#20=A#22[(dummy3 )];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[A#13[(var X#8)]],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#22[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[[.2]];X#20=A#22[(var X#17)];EE#21[[.1],(var X#20)]}, X#2 |-> X#17, S#4 |-> A#16[A#13[(var X#8)]], EE#18[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, T#7 |-> A#22[[.]], T#23 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=A#16[A#13[(var X#8)]];X#20=A#22[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#22[A#16[A#13[(var X#8)]]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#16[A#13[(var X#8)]];X#20=A#22[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#16[A#13[(\ X#9.S#12)]];X#20=A#22[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#16[A#13[(var X#8)]]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#17= A#16[A#13[(\ X#9.S#12)]] ;X#20= A#22[(var X#17)] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#13,A#22} Delta2 = {} Delta3 = {((var X#17),A#22), (A#16[A#13[(var X#8)]],A#22), ((letrec {X#20=A#22[(dummy3 )];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[A#13[(var X#8)]],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),A#22[[.]]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[[.2]];X#20=A#22[(var X#17)];EE#21[[.1],(var X#20)]}, X#2 |-> X#17, S#4 |-> A#16[A#13[(var X#8)]], EE#18[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, A#19 |-> A#22[[.]], T#7 |-> A#22, A#23 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=A#16[A#13[(var X#8)]];X#20=A#22[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#22[A#16[A#13[(var X#8)]]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#16[A#13[(var X#8)]];X#20=A#22[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#16[A#13[(\ X#9.S#12)]];X#20=A#22[(var X#17)];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#16[A#13[(var X#8)]] ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) , (letrec X#17= A#16[A#13[(\ X#9.S#12)]] ;X#20= (var X#17) ;X#8= (\ X#9.S#12) ;E#11 ;EE#21[X#10,(var X#20)] in A#14[(var X#10)] ) ) where Delta1 = {A#13} Delta2 = {} Delta3 = {((var X#17),[.]), (A#16[A#13[(var X#8)]],[.]), ((letrec {X#20=(dummy3 );X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]),(letrec {X#17=(dummy3 )} in [.])), (A#16[A#13[(var X#8)]],(letrec {X#17=(dummy3 )} in [.])), ((var X#17),[.]), ((var X#8),A#13[[.]]), ((var X#10),A#14[[.]]), ((var X#10),A#14[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(\ X#9.S#12)]]} in A#14[(var X#10)]) and constraints: A#13/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#12);E#11;EE#15[X#10,A#13[(var X#8)]]} in A#14[(var X#10)])} Delta1= {A#13} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#10),A#14[[.]]),((var X#10),A#14[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#14[(var X#10)], EE#15[.1,.2] |-> {X#17=A#16[[.2]];X#20=(var X#17);EE#21[[.1],(var X#20)]}, X#2 |-> X#17, S#4 |-> A#16[A#13[(var X#8)]], EE#18[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]}, T#7 |-> [.], A#19 |-> [.], X#17 |-> X#17} and instantiated rules: (letrec {X#17=A#16[A#13[(var X#8)]];X#20=(var X#17);X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) <-ucp2- (letrec {X#20=A#16[A#13[(var X#8)]];X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ................................................................................ (letrec {X#17=A#16[A#13[(var X#8)]];X#20=(var X#17);X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) -SR,cp-e1-> (letrec {X#17=A#16[A#13[(\ X#9.S#12)]];X#20=(var X#17);X#8=(\ X#9.S#12);E#11;EE#21[X#10,(var X#20)]} in A#14[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#15,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#19[(app A#20[[.]] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#19[(app A#20[[.]] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21)]), T#18 |-> A#19[(app A#20[(var X#10)] T#21)], A#15 |-> A#19[(app A#20 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#19[(app A#20[(var X#10)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#19= T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= (\ X#9.S#13) ;E#21 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=T#18;X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), E#12 |-> {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#21}, E#20 |-> {X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}} and instantiated rules: (letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#19=T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(\ X#9.S#13);E#21;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#21,T#18,T#6,A#14,A#22} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> A#22, T#18 |-> A#22[A#24[(app A#25[(var X#11)] T#26)]], T#23 |-> A#24[(app A#25[(var X#11)] T#26)], A#14 |-> A#24[(app A#25 T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[A#14[(\ X#9.S#13)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24)];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[[.2]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, T#18 |-> A#22[(app A#23[A#14[(var X#11)]] T#24)], A#21 |-> A#22[(app A#23 T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[A#14[(var X#11)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[A#14[(\ X#9.S#13)]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(\ X#9.S#13)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#22[(app A#23[(var X#11)] T#24)];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=[.2]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> [.], T#18 |-> A#22[(app A#23[(var X#11)] T#24)], A#14 |-> A#22[(app A#23 T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#11)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(\ X#9.S#13)] T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#22,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#10=A#24[(app A#25[(var X#22)] T#26)];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {[.1]=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#23[X#22,[.2]]}, X#19 |-> X#10, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#18 |-> A#24[(app A#25[(var X#22)] T#26)], A#21 |-> A#24[(app A#25 T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(app A#25[(var X#22)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#22,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#24[X#10,(var X#22)] ;EE#25[X#23,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#26[(app A#27[(var X#23)] T#28)];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#24[[.1],(var X#22)];EE#25[X#23,[.2]]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#18 |-> A#26[(app A#27[(var X#23)] T#28)], A#21 |-> A#26[(app A#27 T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#26[(app A#27[(var X#23)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#24[X#10,(var X#22)];EE#25[X#23,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=T#7[S#4];E#3} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#24[A#26[(app A#27[(\ X#9.S#13)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#25,A#21,T#18,T#6,A#14,A#24} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[(app A#27[[.]] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> A#24, T#18 |-> A#24[A#26[(app A#27[(var X#11)] T#28)]], T#25 |-> A#26[(app A#27[(var X#11)] T#28)], A#14 |-> A#26[(app A#27 T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=T#7[S#4];E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#24[A#26[(app A#27[(var X#11)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#24[A#26[(app A#27[(\ X#9.S#13)] T#28[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#24[(app A#25[A#14[(\ X#9.S#13)]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=A#24[(app A#25[[.2]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#23[[.1],(var X#22)]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, T#18 |-> A#24[(app A#25[A#14[(var X#11)]] T#26)], A#21 |-> A#24[(app A#25 T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#24[(app A#25[A#14[(var X#11)]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#24[(app A#25[A#14[(\ X#9.S#13)]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#22= A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#18,T#6,A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#22=A#24[(app A#25[(var X#11)] T#26)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]), EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#19 |-> X#22, E#20 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> [.], T#18 |-> A#24[(app A#25[(var X#11)] T#26)], A#14 |-> A#24[(app A#25 T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#22=A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#22=A#24[(app A#25[(var X#11)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#22=A#24[(app A#25[(\ X#9.S#13)] T#26[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#8),[.]), ((\ X#9.S#13),[.]), ((letrec {X#11=(dummy3 );E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#13),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#13), VV#17|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#11, E#3 |-> {E#12;EE#16[X#10,A#14[(var X#11)]]}, T#7 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) <-ucp2- (letrec {X#11=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#19= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#20|X#11,(var X#19)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#8),[.]), ((\ X#9.S#13),[.]), ((letrec {X#19=(dummy3 );E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]),(letrec {X#8=(dummy3 )} in [.])), ((\ X#9.S#13),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], X#2 |-> X#8, S#4 |-> (\ X#9.S#13), VV#17|.1,.2| |-> {X#19=[.2];VV#20|[.1],(var X#19)|}, X#1 |-> X#19, E#3 |-> {E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|}, T#7 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#19=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#20|X#11,(var X#19)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#1= T#7[S#4] ;X#8= (\ X#9.S#13) ;E#19 ;EE#16[X#10,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;X#8= (\ X#9.S#13) ;E#19 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#19}, E#18 |-> {X#1=T#7[(var X#2)];E#19}, E#3 |-> {X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#1=T#7[S#4];X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(\ X#9.S#13);E#19;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[A#22[(app A#23[(var X#11)] T#24[S#4])]] ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#20[A#22[(app A#23[(\ X#9.S#13)] T#24[(var X#2)])]] ;X#2= S#4 ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#21,A#19,T#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#2),A#20[A#22[(app A#23[(var X#11)] T#24)]]), (S#4,A#20[A#22[(app A#23[(var X#11)] T#24)]]), ((letrec {X#10=A#20[A#22[(app A#23[(var X#11)] T#24[(dummy3 )])]];X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[A#22[(app A#23[(var X#11)] T#24[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] T#24[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|}, A#19 |-> A#20, T#7 |-> A#20[A#22[(app A#23[(var X#11)] T#24)]], T#21 |-> A#22[(app A#23[(var X#11)] T#24)], A#14 |-> A#22[(app A#23 T#24[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] T#24[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] T#24[S#4])]];X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(app A#23[(var X#11)] T#24[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(app A#23[(\ X#9.S#13)] T#24[(var X#2)])]];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[A#14[(var X#11)]] T#22[S#4])] ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#20[(app A#21[A#14[(\ X#9.S#13)]] T#22[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[A#14[(var X#11)]] T#22)]), (S#4,A#20[(app A#21[A#14[(var X#11)]] T#22)]), ((letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] T#22[(dummy3 )])];X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[(app A#21[A#14[(var X#11)]] T#22[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {[.1]=A#20[(app A#21[[.2]] T#22[(var X#2)])]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|}, T#7 |-> A#20[(app A#21[A#14[(var X#11)]] T#22)], A#19 |-> A#20[(app A#21 T#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] T#22[S#4])];X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[A#14[(var X#11)]] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(app A#21[A#14[(\ X#9.S#13)]] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#20[(app A#21[(var X#11)] T#22[S#4])] ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#20[(app A#21[(\ X#9.S#13)] T#22[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#13) ;E#18 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#20[(app A#21[(var X#11)] T#22)]), (S#4,A#20[(app A#21[(var X#11)] T#22)]), ((letrec {X#10=A#20[(app A#21[(var X#11)] T#22[(dummy3 )])];X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#20[(app A#21[(var X#11)] T#22[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[(app A#21[[.]] T#22[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|}, A#19 |-> [.], T#7 |-> A#20[(app A#21[(var X#11)] T#22)], A#14 |-> A#20[(app A#21 T#22[(var X#2)])]} and instantiated rules: (letrec {X#10=A#20[(app A#21[(var X#11)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(app A#21[(var X#11)] T#22[S#4])];X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(app A#21[(var X#11)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(app A#21[(\ X#9.S#13)] T#22[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(app A#23[(var X#20)] T#24[S#4])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#20,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(app A#23[(var X#20)] T#24[(var X#2)])] ;X#2= S#4 ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#20,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[(var X#20)] T#24)]), (S#4,A#22[(app A#23[(var X#20)] T#24)]), ((letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(dummy3 )])];X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#22[(app A#23[(var X#20)] T#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {[.1]=A#22[(app A#23[(var X#20)] T#24[(var X#2)])];EE#21[X#20,[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#7 |-> A#22[(app A#23[(var X#20)] T#24)], A#19 |-> A#22[(app A#23 T#24[(var X#2)])]} and instantiated rules: (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[S#4])];X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(app A#23[(var X#20)] T#24[(var X#2)])];X#2=S#4;X#8=(\ X#9.S#13);E#18;EE#21[X#20,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#24[(app A#25[(var X#21)] T#26[S#4])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= S#4 ;X#20= A#24[(app A#25[(var X#21)] T#26[(var X#2)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#22[X#10,(var X#20)] ;EE#23[X#21,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#24[(app A#25[(var X#21)] T#26)]), (S#4,A#24[(app A#25[(var X#21)] T#26)]), ((letrec {X#20=A#24[(app A#25[(var X#21)] T#26[(dummy3 )])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#24[(app A#25[(var X#21)] T#26[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {X#20=A#24[(app A#25[(var X#21)] T#26[(var X#2)])];EE#22[[.1],(var X#20)];EE#23[X#21,[.2]]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#7 |-> A#24[(app A#25[(var X#21)] T#26)], A#19 |-> A#24[(app A#25 T#26[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#20=A#24[(app A#25[(var X#21)] T#26[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#24[(app A#25[(var X#21)] T#26[S#4])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=S#4;X#20=A#24[(app A#25[(var X#21)] T#26[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=S#4;X#20=A#24[(app A#25[(var X#21)] T#26[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#22[X#10,(var X#20)];EE#23[X#21,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(app A#25[(var X#11)] T#26[S#4])]] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= S#4 ;X#20= A#22[A#24[(app A#25[(\ X#9.S#13)] T#26[(var X#2)])]] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#19,T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#2),A#22[A#24[(app A#25[(var X#11)] T#26)]]), (S#4,A#22[A#24[(app A#25[(var X#11)] T#26)]]), ((letrec {X#20=A#22[A#24[(app A#25[(var X#11)] T#26[(dummy3 )])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#22[A#24[(app A#25[(var X#11)] T#26[[.]])]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[(app A#25[[.]] T#26[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|}, A#19 |-> A#22, T#7 |-> A#22[A#24[(app A#25[(var X#11)] T#26)]], T#23 |-> A#24[(app A#25[(var X#11)] T#26)], A#14 |-> A#24[(app A#25 T#26[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#20=A#22[A#24[(app A#25[(var X#11)] T#26[(var X#2)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[A#24[(app A#25[(var X#11)] T#26[S#4])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=S#4;X#20=A#22[A#24[(app A#25[(var X#11)] T#26[(var X#2)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=S#4;X#20=A#22[A#24[(app A#25[(\ X#9.S#13)] T#26[(var X#2)])]];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[A#14[(var X#11)]] T#24[S#4])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= S#4 ;X#20= A#22[(app A#23[A#14[(\ X#9.S#13)]] T#24[(var X#2)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#19,T#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[A#14[(var X#11)]] T#24)]), (S#4,A#22[(app A#23[A#14[(var X#11)]] T#24)]), ((letrec {X#20=A#22[(app A#23[A#14[(var X#11)]] T#24[(dummy3 )])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#22[(app A#23[A#14[(var X#11)]] T#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {X#20=A#22[(app A#23[[.2]] T#24[(var X#2)])];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|}, T#7 |-> A#22[(app A#23[A#14[(var X#11)]] T#24)], A#19 |-> A#22[(app A#23 T#24[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#20=A#22[(app A#23[A#14[(var X#11)]] T#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[(app A#23[A#14[(var X#11)]] T#24[S#4])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=S#4;X#20=A#22[(app A#23[A#14[(var X#11)]] T#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=S#4;X#20=A#22[(app A#23[A#14[(\ X#9.S#13)]] T#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(app A#23[(var X#11)] T#24[S#4])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#2= S#4 ;X#20= A#22[(app A#23[(\ X#9.S#13)] T#24[(var X#2)])] ;X#8= (\ X#9.S#13) ;E#18 ;EE#21[X#10,(var X#20)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14} Delta2 = {} Delta3 = {((var X#2),A#22[(app A#23[(var X#11)] T#24)]), (S#4,A#22[(app A#23[(var X#11)] T#24)]), ((letrec {X#20=A#22[(app A#23[(var X#11)] T#24[(dummy3 )])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#2),A#22[(app A#23[(var X#11)] T#24[[.]])]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[(app A#23[[.]] T#24[(var X#2)])]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], E#12 |-> {X#2=S#4;E#18}, EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|}, A#19 |-> [.], T#7 |-> A#22[(app A#23[(var X#11)] T#24)], A#14 |-> A#22[(app A#23 T#24[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#20=A#22[(app A#23[(var X#11)] T#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[(app A#23[(var X#11)] T#24[S#4])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#2=S#4;X#20=A#22[(app A#23[(var X#11)] T#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#2=S#4;X#20=A#22[(app A#23[(\ X#9.S#13)] T#24[(var X#2)])];X#8=(\ X#9.S#13);E#18;EE#21[X#10,(var X#20)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#20[A#22[(var X#8)]];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) , (letrec X#10= A#20[A#22[(\ X#9.S#13)]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {T#21,A#19,T#7,A#14,A#20,A#22} Delta2 = {} Delta3 = {((var X#11),A#20[A#22[[.]]]), ((var X#8),A#20[A#22[[.]]]), ((letrec {X#10=A#20[A#22[(dummy3 )]];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#20[A#22[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> A#20, T#7 |-> A#20[A#22[[.]]], A#14 |-> A#22, T#21 |-> A#22[[.]], T#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[A#22[(var X#8)]];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(\ X#9.S#13)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#20[A#22[(var X#8)]];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) , (letrec X#10= A#20[A#22[(\ X#9.S#13)]] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {T#21,A#19,T#7,A#14,A#20,A#22} Delta2 = {} Delta3 = {((var X#11),A#20[A#22]), ((var X#8),A#20[A#22]), ((letrec {X#10=A#20[A#22[(dummy3 )]];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#20[A#22[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {[.1]=A#20[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> A#20, T#7 |-> A#20[A#22], A#14 |-> A#22[[.]], T#21 |-> A#22, A#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[A#22[(var X#8)]];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[A#22[(var X#11)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[A#22[(\ X#9.S#13)]];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#20[(var X#8)];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) , (letrec X#10= A#20[(\ X#9.S#13)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#11),A#20[[.]]), ((var X#8),A#20[[.]]), ((letrec {X#10=A#20[(dummy3 )];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> [.], A#14 |-> A#20, T#7 |-> A#20[[.]], T#21 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(var X#8)];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(\ X#9.S#13)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {X#10=A#20[(var X#8)];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) , (letrec X#10= A#20[(\ X#9.S#13)] ;X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#20} Delta2 = {} Delta3 = {((var X#11),A#20), ((var X#8),A#20), ((letrec {X#10=A#20[(dummy3 )];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#20[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12}, A#19 |-> [.], A#14 |-> A#20[[.]], T#7 |-> A#20, A#21 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#20[(var X#8)];X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#20[(var X#11)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#20[(\ X#9.S#13)];X#11=(var X#8);X#8=(\ X#9.S#13);E#12} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(var X#8)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[A#24[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#19,T#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24[[.]]]), ((var X#8),A#22[A#24[[.]]]), ((letrec {X#20=A#22[A#24[(dummy3 )]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, T#7 |-> A#22[A#24[[.]]], A#14 |-> A#24, T#23 |-> A#24[[.]], T#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[A#24[(var X#8)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[A#24[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[A#24[(var X#8)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[A#24[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#19,T#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24]), ((var X#8),A#22[A#24]), ((letrec {X#20=A#22[A#24[(dummy3 )]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {X#20=A#22[[.2]];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> A#22, T#7 |-> A#22[A#24], A#14 |-> A#24[[.]], T#23 |-> A#24, A#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[A#24[(var X#8)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[A#24[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[A#24[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(var X#8)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22[[.]]), ((var X#8),A#22[[.]]), ((letrec {X#20=A#22[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> [.], A#14 |-> A#22, T#7 |-> A#22[[.]], T#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[(var X#8)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#20= A#22[(var X#8)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) , (letrec X#11= (var X#8) ;X#20= A#22[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#21[X#10,(var X#20)] in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22), ((var X#8),A#22), ((letrec {X#20=A#22[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#8),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=[.2]}, X#2 |-> X#11, S#4 |-> (var X#8), EE#16[.1,.2] |-> {X#20=[.2];EE#21[[.1],(var X#20)]}, X#1 |-> X#20, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]}, A#19 |-> [.], A#14 |-> A#22[[.]], T#7 |-> A#22, A#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) <-ucp2- (letrec {X#20=A#22[(var X#8)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#8);X#20=A#22[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#8);X#20=A#22[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#21[X#10,(var X#20)]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(var X#19)]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(\ X#9.S#13)]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#21,T#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24[[.]]]), ((var X#19),A#22[A#24[[.]]]), ((letrec {X#10=A#22[A#24[(dummy3 )]];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> A#22, T#7 |-> A#22[A#24[[.]]], A#14 |-> A#24, T#23 |-> A#24[[.]], T#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#24[(var X#19)]];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(\ X#9.S#13)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#24[(var X#19)]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[A#24[(\ X#9.S#13)]] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#23,A#21,T#7,A#14,A#22,A#24} Delta2 = {} Delta3 = {((var X#11),A#22[A#24]), ((var X#19),A#22[A#24]), ((letrec {X#10=A#22[A#24[(dummy3 )]];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[A#24[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> A#22, T#7 |-> A#22[A#24], A#14 |-> A#24[[.]], T#23 |-> A#24, A#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#24[(var X#19)]];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[A#24[(var X#11)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[A#24[(\ X#9.S#13)]];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(\ X#9.S#13)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22[[.]]), ((var X#19),A#22[[.]]), ((letrec {X#10=A#22[(dummy3 )];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#22, T#7 |-> A#22[[.]], T#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[(var X#19)];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(\ X#9.S#13)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(\ X#9.S#13)] ;X#11= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#11),A#22), ((var X#19),A#22), ((letrec {X#10=A#22[(dummy3 )];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#22[[.]], T#7 |-> A#22, A#23 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[(var X#19)];X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#11)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(\ X#9.S#13)];X#11=(var X#19);X#8=(\ X#9.S#13);E#12;VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#26[(var X#19)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[A#26[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#25,A#21,T#7,A#14,A#24,A#26} Delta2 = {} Delta3 = {((var X#11),A#24[A#26[[.]]]), ((var X#19),A#24[A#26[[.]]]), ((letrec {X#22=A#24[A#26[(dummy3 )]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#24[A#26[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> A#24, T#7 |-> A#24[A#26[[.]]], A#14 |-> A#26, T#25 |-> A#26[[.]], T#27 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#26[(var X#19)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[A#26[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#26[(var X#19)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[A#26[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#25,A#21,T#7,A#14,A#24,A#26} Delta2 = {} Delta3 = {((var X#11),A#24[A#26]), ((var X#19),A#24[A#26]), ((letrec {X#22=A#24[A#26[(dummy3 )]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#24[A#26[[.]]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> A#24, T#7 |-> A#24[A#26], A#14 |-> A#26[[.]], T#25 |-> A#26, A#27 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#26[(var X#19)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[A#26[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[A#26[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#11),A#24[[.]]), ((var X#19),A#24[[.]]), ((letrec {X#22=A#24[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#24, T#7 |-> A#24[[.]], T#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#22= A#24[(\ X#9.S#13)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#20|X#19,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {T#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#11),A#24), ((var X#19),A#24), ((letrec {X#22=A#24[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]),(letrec {X#11=(dummy3 )} in [.])), ((var X#19),(letrec {X#11=(dummy3 )} in [.])), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {[.1]=(var X#19);VV#20|X#19,[.2]|}, X#2 |-> X#11, S#4 |-> (var X#19), EE#16[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|}, A#21 |-> [.], A#14 |-> A#24[[.]], T#7 |-> A#24, A#25 |-> [.], X#11 |-> X#11} and instantiated rules: (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#22=A#24[(var X#11)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#22=A#24[(\ X#9.S#13)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#20|X#19,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#19= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#22|X#20,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#20),[.]), ((letrec {X#11=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), ((var X#20),(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);[.1]=(var X#19);VV#22|X#20,[.2]|}, X#2 |-> X#19, S#4 |-> (var X#20), VV#21|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#11, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|}, T#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#11=(var X#19);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#11=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#19=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#22|X#20,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#24= (var X#20) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#22|X#20,(var X#8)| ;VV#25|X#11,(var X#24)| in A#15[(var X#10)] ) , (letrec X#19= (var X#20) ;X#24= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#22|X#20,(var X#8)| ;VV#25|X#11,(var X#24)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#20),[.]), ((letrec {X#24=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), ((var X#20),(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=(var X#20);X#24=(var X#19);VV#22|X#20,[.2]|;VV#25|[.1],(var X#24)|}, X#2 |-> X#19, S#4 |-> (var X#20), VV#21|.1,.2| |-> {X#24=[.2];VV#25|[.1],(var X#24)|}, X#1 |-> X#24, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|}, T#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=(var X#20);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#24=(var X#20);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#20);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#20);X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#22|X#20,(var X#8)|;VV#25|X#11,(var X#24)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#11= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] in A#15[(var X#10)] ) , (letrec X#11= (var X#19) ;X#19= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#8),[.]), ((letrec {X#11=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), ((var X#8),(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];[.1]=(var X#19)}, X#2 |-> X#19, S#4 |-> (var X#8), VV#20|.1,.2| |-> {[.1]=[.2]}, X#1 |-> X#11, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]}, T#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#11=(var X#19);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) <-ucp2- (letrec {X#11=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) ................................................................................ (letrec {X#11=(var X#19);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]]} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#11=(var X#19);X#19=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]]} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= (var X#8) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(var X#11)]] ;VV#23|X#11,(var X#22)| in A#15[(var X#10)] ) , (letrec X#19= (var X#8) ;X#22= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#16[X#10,A#14[(\ X#9.S#13)]] ;VV#23|X#11,(var X#22)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), ((var X#8),[.]), ((letrec {X#22=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), ((var X#8),(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], VV#17|.1,.2| |-> {X#19=[.2];X#22=(var X#19);VV#23|[.1],(var X#22)|}, X#2 |-> X#19, S#4 |-> (var X#8), VV#20|.1,.2| |-> {X#22=[.2];VV#23|[.1],(var X#22)|}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|}, T#7 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=(var X#8);X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=(var X#8);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=(var X#8);X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=(var X#8);X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#23|X#11,(var X#22)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[A#18[(var X#20)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(var X#19)] ;X#19= A#18[(var X#20)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,T#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24[[.]]), (A#18[(var X#20)],A#24[[.]]), ((letrec {X#10=A#24[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[(var X#20)],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[(var X#20)];[.1]=A#24[(var X#19)];EE#22[X#20,[.2]]}, X#2 |-> X#19, S#4 |-> A#18[(var X#20)], EE#21[.1,.2] |-> {[.1]=A#24[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, A#23 |-> A#24, T#7 |-> A#24[[.]], T#25 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=A#24[(var X#19)];X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#24[A#18[(var X#20)]];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(var X#19)];X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(var X#19)];X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#24[A#18[(var X#20)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#24[(var X#19)] ;X#19= A#18[(var X#20)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,T#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24), (A#18[(var X#20)],A#24), ((letrec {X#10=A#24[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[(var X#20)],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[(var X#20)];[.1]=A#24[(var X#19)];EE#22[X#20,[.2]]}, X#2 |-> X#19, S#4 |-> A#18[(var X#20)], EE#21[.1,.2] |-> {[.1]=A#24[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, A#23 |-> A#24[[.]], T#7 |-> A#24, A#25 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=A#24[(var X#19)];X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#24[A#18[(var X#20)]];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#24[(var X#19)];X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#24[(var X#19)];X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[(var X#20)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(var X#11)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#19) ;X#19= A#18[(var X#20)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(\ X#9.S#13)]] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), (A#18[(var X#20)],[.]), ((letrec {X#10=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[(var X#20)],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[(var X#20)];[.1]=(var X#19);EE#22[X#20,[.2]]}, X#2 |-> X#19, S#4 |-> A#18[(var X#20)], EE#21[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|}, T#7 |-> [.], A#23 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=(var X#19);X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#19);X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#19);X#19=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#24= A#26[A#18[(var X#20)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= A#18[(var X#20)] ;X#24= A#26[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,T#7,A#14,A#26} Delta2 = {} Delta3 = {((var X#19),A#26[[.]]), (A#18[(var X#20)],A#26[[.]]), ((letrec {X#24=A#26[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[(var X#20)],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];EE#22[X#20,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, S#4 |-> A#18[(var X#20)], EE#21[.1,.2] |-> {X#24=A#26[[.2]];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, A#23 |-> A#26, T#7 |-> A#26[[.]], T#27 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#24=A#26[A#18[(var X#20)]];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#24= A#26[A#18[(var X#20)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= A#18[(var X#20)] ;X#24= A#26[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#23,T#7,A#14,A#26} Delta2 = {} Delta3 = {((var X#19),A#26), (A#18[(var X#20)],A#26), ((letrec {X#24=A#26[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[(var X#20)],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#26[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];EE#22[X#20,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, S#4 |-> A#18[(var X#20)], EE#21[.1,.2] |-> {X#24=A#26[[.2]];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, A#23 |-> A#26[[.]], T#7 |-> A#26, A#27 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#24=A#26[A#18[(var X#20)]];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=A#18[(var X#20)];X#24=A#26[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#24= A#18[(var X#20)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(var X#11)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= A#18[(var X#20)] ;X#24= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#22[X#20,A#14[(\ X#9.S#13)]] ;EE#25[X#10,(var X#24)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), (A#18[(var X#20)],[.]), ((letrec {X#24=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[(var X#20)],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[(var X#20)];X#24=(var X#19);EE#22[X#20,[.2]];EE#25[[.1],(var X#24)]}, X#2 |-> X#19, S#4 |-> A#18[(var X#20)], EE#21[.1,.2] |-> {X#24=[.2];EE#25[[.1],(var X#24)]}, X#1 |-> X#24, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|}, T#7 |-> [.], A#23 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=A#18[(var X#20)];X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#24=A#18[(var X#20)];X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=A#18[(var X#20)];X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(var X#11)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=A#18[(var X#20)];X#24=(var X#19);X#8=(\ X#9.S#13);E#12;EE#22[X#20,A#14[(\ X#9.S#13)]];EE#25[X#10,(var X#24)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#18[A#14[(var X#11)]]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(var X#19)] ;X#19= A#18[A#14[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#19),A#22[[.]]), (A#18[A#14[(var X#11)]],A#22[[.]]), ((letrec {X#10=A#22[(dummy3 )];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[A#14[(var X#11)]],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[[.2]];[.1]=A#22[(var X#19)]}, X#2 |-> X#19, S#4 |-> A#18[A#14[(var X#11)]], EE#20[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> A#22, T#7 |-> A#22[[.]], T#23 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=A#22[(var X#19)];X#19=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#18[A#14[(var X#11)]]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#19)];X#19=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(var X#19)];X#19=A#18[A#14[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#22[A#18[A#14[(var X#11)]]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= A#22[(var X#19)] ;X#19= A#18[A#14[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#14,A#22} Delta2 = {} Delta3 = {((var X#19),A#22), (A#18[A#14[(var X#11)]],A#22), ((letrec {X#10=A#22[(dummy3 )];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[A#14[(var X#11)]],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#22[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[[.2]];[.1]=A#22[(var X#19)]}, X#2 |-> X#19, S#4 |-> A#18[A#14[(var X#11)]], EE#20[.1,.2] |-> {[.1]=A#22[[.2]]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, A#21 |-> A#22[[.]], T#7 |-> A#22, A#23 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=A#22[(var X#19)];X#19=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#22[A#18[A#14[(var X#11)]]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=A#22[(var X#19)];X#19=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=A#22[(var X#19)];X#19=A#18[A#14[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#10= A#18[A#14[(var X#11)]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#10= (var X#19) ;X#19= A#18[A#14[(\ X#9.S#13)]] ;X#8= (\ X#9.S#13) ;E#12 ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), (A#18[A#14[(var X#11)]],[.]), ((letrec {X#10=(dummy3 );X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[A#14[(var X#11)]],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[[.2]];[.1]=(var X#19)}, X#2 |-> X#19, S#4 |-> A#18[A#14[(var X#11)]], EE#20[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#10, E#3 |-> {X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|}, T#7 |-> [.], A#21 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#10=(var X#19);X#19=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#10=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#10=(var X#19);X#19=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#10=(var X#19);X#19=A#18[A#14[(\ X#9.S#13)]];X#8=(\ X#9.S#13);E#12;VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#18[A#14[(var X#11)]]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= A#18[A#14[(\ X#9.S#13)]] ;X#22= A#24[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24[[.]]), (A#18[A#14[(var X#11)]],A#24[[.]]), ((letrec {X#22=A#24[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[A#14[(var X#11)]],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[[.2]];X#22=A#24[(var X#19)];EE#23[[.1],(var X#22)]}, X#2 |-> X#19, S#4 |-> A#18[A#14[(var X#11)]], EE#20[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> A#24, T#7 |-> A#24[[.]], T#25 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=A#18[A#14[(var X#11)]];X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#18[A#14[(var X#11)]]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=A#18[A#14[(var X#11)]];X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=A#18[A#14[(\ X#9.S#13)]];X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#24[A#18[A#14[(var X#11)]]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= A#18[A#14[(\ X#9.S#13)]] ;X#22= A#24[(var X#19)] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#21,T#7,A#14,A#24} Delta2 = {} Delta3 = {((var X#19),A#24), (A#18[A#14[(var X#11)]],A#24), ((letrec {X#22=A#24[(dummy3 )];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[A#14[(var X#11)]],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),A#24[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[[.2]];X#22=A#24[(var X#19)];EE#23[[.1],(var X#22)]}, X#2 |-> X#19, S#4 |-> A#18[A#14[(var X#11)]], EE#20[.1,.2] |-> {X#22=A#24[[.2]];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, A#21 |-> A#24[[.]], T#7 |-> A#24, A#25 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=A#18[A#14[(var X#11)]];X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#24[A#18[A#14[(var X#11)]]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=A#18[A#14[(var X#11)]];X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=A#18[A#14[(\ X#9.S#13)]];X#22=A#24[(var X#19)];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec X#22= A#18[A#14[(var X#11)]] ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) , (letrec X#19= A#18[A#14[(\ X#9.S#13)]] ;X#22= (var X#19) ;X#8= (\ X#9.S#13) ;E#12 ;EE#23[X#10,(var X#22)] ;VV#17|X#11,(var X#8)| in A#15[(var X#10)] ) ) where Delta1 = {A#14} Delta2 = {} Delta3 = {((var X#19),[.]), (A#18[A#14[(var X#11)]],[.]), ((letrec {X#22=(dummy3 );X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]),(letrec {X#19=(dummy3 )} in [.])), (A#18[A#14[(var X#11)]],(letrec {X#19=(dummy3 )} in [.])), ((var X#19),[.]), ((var X#8),[.]), ((var X#10),A#15[[.]]), ((var X#11),A#14[[.]]), ((var X#8),[.]), ((var X#10),A#15[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(\ X#9.S#13)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) and constraints: A#14/= [.] and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(\ X#9.S#13);E#12;EE#16[X#10,A#14[(var X#11)]];VV#17|X#11,(var X#8)|} in A#15[(var X#10)])} Delta1= {A#14} Delta2= {} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#2),T#7[[.]]),((var X#8),[.]),((var X#10),A#15[[.]]),((var X#11),A#14[[.]]),((var X#8),[.]),((var X#10),A#15[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#15[(var X#10)], EE#16[.1,.2] |-> {X#19=A#18[[.2]];X#22=(var X#19);EE#23[[.1],(var X#22)]}, X#2 |-> X#19, S#4 |-> A#18[A#14[(var X#11)]], EE#20[.1,.2] |-> {X#22=[.2];EE#23[[.1],(var X#22)]}, X#1 |-> X#22, E#3 |-> {X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|}, T#7 |-> [.], A#21 |-> [.], X#19 |-> X#19} and instantiated rules: (letrec {X#19=A#18[A#14[(var X#11)]];X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) <-ucp2- (letrec {X#22=A#18[A#14[(var X#11)]];X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ................................................................................ (letrec {X#19=A#18[A#14[(var X#11)]];X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) -SR,cp-e2-> (letrec {X#19=A#18[A#14[(\ X#9.S#13)]];X#22=(var X#19);X#8=(\ X#9.S#13);E#12;EE#23[X#10,(var X#22)];VV#17|X#11,(var X#8)|} in A#15[(var X#10)]) ================================================================================ Critical Pair: ( (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)])) , (letrec {E#8;E#9} in T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) ) where Delta1 = {T#11,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), [{E#8},(letrec {E#9} in [.])], ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),[{E#8},(letrec {E#9} in [.])],((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (letrec {E#9} in T#12)), T#11 |-> (letrec {E#9} in T#12), S#10 |-> T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) <-ucp2- (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)])) ................................................................................ (letrec {E#8} in (letrec {E#9} in T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) -SR,llet-in1-> (letrec {E#8;E#9} in T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) ================================================================================ Critical Pair: ( (letrec E#8 in (letrec {X#13=T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#15} in S#10) ) , (letrec X#13= T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#15 ;E#8 in S#10 ) ) where Delta1 = {T#11,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), [{E#8},(letrec {X#13=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#15} in [.])], ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),[{E#8},(letrec {E#9} in [.])],((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (letrec {X#13=T#12;E#15} in S#10)), T#11 |-> (letrec {X#13=T#12;E#15} in S#10), E#9 |-> {X#13=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#8} in (letrec {X#13=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#15} in S#10)) <-ucp2- (letrec {E#8} in (letrec {X#13=T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#15} in S#10)) ................................................................................ (letrec {E#8} in (letrec {X#13=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#15} in S#10)) -SR,llet-in1-> (letrec {X#13=T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#15;E#8} in S#10) ================================================================================ Critical Pair: ( (letrec {E#8} in (letrec {X#1=T#7[S#4];E#13} in S#10)) , (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#13;E#8} in S#10) ) where Delta1 = {T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#13} in S#10),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), [{E#8},(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#13} in [.])], ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),[{E#8},(letrec {E#9} in [.])],((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in [.]), T#11 |-> [.], S#5 |-> S#10, E#9 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#13}, E#12 |-> {X#1=T#7[(var X#2)];E#13}, E#3 |-> {E#13}} and instantiated rules: (letrec {E#8} in (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#13} in S#10)) <-ucp2- (letrec {E#8} in (letrec {X#1=T#7[S#4];E#13} in S#10)) ................................................................................ (letrec {E#8} in (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#13} in S#10)) -SR,llet-in1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#13;E#8} in S#10) ================================================================================ Critical Pair: ( (letrec X#12= T#11[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;E#14 in (letrec {E#9} in S#10) ) , (letrec X#12= T#11[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#14 ;E#9 in S#10 ) ) where Delta1 = {T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), [{X#12=T#11[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#14},(letrec {E#9} in [.])], ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),[{E#8},(letrec {E#9} in [.])],((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#12=T#11;E#14} in (letrec {E#9} in S#10)), E#8 |-> {X#12=T#11[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#14}, E#13 |-> {E#14}} and instantiated rules: (letrec {X#12=T#11[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#14} in (letrec {E#9} in S#10)) <-ucp2- (letrec {X#12=T#11[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#14} in (letrec {E#9} in S#10)) ................................................................................ (letrec {X#12=T#11[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#14} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {X#12=T#11[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#14;E#9} in S#10) ================================================================================ Critical Pair: ( (letrec {X#1=T#7[S#4];E#12} in (letrec {E#9} in S#10)) , (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#12;E#9} in S#10) ) where Delta1 = {} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#12} in (letrec {E#9} in S#10)),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), [{X#1=T#7[(var X#2)];X#2=S#4;E#12},(letrec {E#9} in [.])], ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {E#8;E#9} in S#10) and constraints: E#8/= {}, E#9/= {}, ({E#8},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in (letrec {E#9} in S#10))} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),[{E#8},(letrec {E#9} in [.])],((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> (letrec {E#9} in S#10), E#8 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#12}, E#11 |-> {X#1=T#7[(var X#2)];E#12}, E#3 |-> {E#12}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#12} in (letrec {E#9} in S#10)) <-ucp2- (letrec {X#1=T#7[S#4];E#12} in (letrec {E#9} in S#10)) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#12} in (letrec {E#9} in S#10)) -SR,llet-in1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#12;E#9} in S#10) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#9} in S#11) ;E#10 in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec X#8= S#11 ;E#10 ;E#9 in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])],(letrec {E#9} in [.])), [{E#10},(letrec {E#9} in [.])], ((var X#2),T#7[[.]]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),A#14[(app A#15[[.]] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16)]), T#13 |-> A#14[(app A#15[(var X#8)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#14[(app A#15[(var X#8)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#9} in T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ;E#10 in A#12[(var X#8)] ) , (letrec X#8= T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#10 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{E#10},(letrec {E#9} in [.])], ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#9} in T#16);E#10} in A#12[(var X#8)]), X#14 |-> X#8, E#15 |-> {E#10}, T#13 |-> (letrec {E#9} in T#16), S#11 |-> T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=(letrec {E#9} in T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#10} in A#12[(var X#8)]) <-ucp2- (letrec {X#8=(letrec {E#9} in T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)]);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#8=(letrec {E#9} in T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#10;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#17=T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#19} in S#11) ;E#10 in A#12[(var X#8)] ) , (letrec X#17= T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= S#11 ;E#10 ;E#19 in A#12[(var X#8)] ) ) where Delta1 = {T#13,T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#19} in [.])), [{E#10},(letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#19} in [.])], ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {X#17=T#16;E#19} in S#11);E#10} in A#12[(var X#8)]), X#14 |-> X#8, E#15 |-> {E#10}, T#13 |-> (letrec {X#17=T#16;E#19} in S#11), E#9 |-> {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#8=(letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#19} in S#11);E#10} in A#12[(var X#8)]) <-ucp2- (letrec {X#8=(letrec {X#17=T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#19} in S#11);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#8=(letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#19} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#17=T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=S#11;E#10;E#19} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=(letrec {X#1=T#7[S#4];E#17} in S#11);E#10} in A#12[(var X#8)]) , (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=S#11;E#10;E#17} in A#12[(var X#8)]) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#17} in S#11),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#17} in [.])), [{E#10},(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#17} in [.])], ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=[.];E#10} in A#12[(var X#8)]), X#14 |-> X#8, E#15 |-> {E#10}, T#13 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#17}, E#16 |-> {X#1=T#7[(var X#2)];E#17}, E#3 |-> {E#17}} and instantiated rules: (letrec {X#8=(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#17} in S#11);E#10} in A#12[(var X#8)]) <-ucp2- (letrec {X#8=(letrec {X#1=T#7[S#4];E#17} in S#11);E#10} in A#12[(var X#8)]) ................................................................................ (letrec {X#8=(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#17} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=S#11;E#10;E#17} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;X#8= (letrec {E#9} in S#11) ;E#16 in A#12[(var X#8)] ) , (letrec X#14= T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= S#11 ;E#16 ;E#9 in A#12[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16},(letrec {E#9} in [.])], ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]), E#10 |-> {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16}, E#15 |-> {X#8=(letrec {E#9} in S#11);E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]) <-ucp2- (letrec {X#14=T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)];X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(letrec {E#9} in S#11);E#16} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=S#11;E#16;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=(letrec {E#9} in T#14[S#4]);E#13} in A#12[(var X#8)]) , (letrec {X#2=S#4;X#8=T#14[(var X#2)];E#13;E#9} in A#12[(var X#8)]) ) where Delta1 = {T#7} Delta2 = {E#9} Delta3 = {((var X#2),(letrec {E#9} in T#14)), (S#4,(letrec {E#9} in T#14)), ((letrec {X#8=(letrec {E#9} in T#14[(dummy3 )]);E#13} in A#12[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#2=S#4;E#13},(letrec {E#9} in [.])], ((var X#2),(letrec {E#9} in T#14[[.]])), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=S#4;E#13}, X#1 |-> X#8, E#3 |-> {E#13}, T#7 |-> (letrec {E#9} in T#14), S#11 |-> T#14[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=(letrec {E#9} in T#14[(var X#2)]);E#13} in A#12[(var X#8)]) <-ucp2- (letrec {X#8=(letrec {E#9} in T#14[S#4]);E#13} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=(letrec {E#9} in T#14[(var X#2)]);E#13} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#2=S#4;X#8=T#14[(var X#2)];E#13;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=(letrec {X#15=T#14[S#4];E#17} in S#11);E#13} in A#12[(var X#8)]) , (letrec {X#15=T#14[(var X#2)];X#2=S#4;X#8=S#11;E#13;E#17} in A#12[(var X#8)]) ) where Delta1 = {T#7} Delta2 = {E#9} Delta3 = {((var X#2),(letrec {X#15=T#14;E#17} in S#11)), (S#4,(letrec {X#15=T#14;E#17} in S#11)), ((letrec {X#8=(letrec {X#15=T#14[(dummy3 )];E#17} in S#11);E#13} in A#12[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {X#15=T#14[(var X#2)];E#17} in [.])), [{X#2=S#4;E#13},(letrec {X#15=T#14[(var X#2)];E#17} in [.])], ((var X#2),(letrec {X#15=T#14[[.]];E#17} in S#11)), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#2=S#4;E#13}, X#1 |-> X#8, E#3 |-> {E#13}, T#7 |-> (letrec {X#15=T#14;E#17} in S#11), E#9 |-> {X#15=T#14[(var X#2)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#2=S#4;X#8=(letrec {X#15=T#14[(var X#2)];E#17} in S#11);E#13} in A#12[(var X#8)]) <-ucp2- (letrec {X#8=(letrec {X#15=T#14[S#4];E#17} in S#11);E#13} in A#12[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=(letrec {X#15=T#14[(var X#2)];E#17} in S#11);E#13} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#15=T#14[(var X#2)];X#2=S#4;X#8=S#11;E#13;E#17} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#1=T#7[S#4];X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) , (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=S#11;E#14;E#9} in A#12[(var X#8)]) ) where Delta1 = {} Delta2 = {E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (A#12[(var X#8)],(letrec {E#9} in [.])), [{X#1=T#7[(var X#2)];X#2=S#4;E#14},(letrec {E#9} in [.])], ((var X#2),T#7[[.]]), ((var X#8),A#12[[.]]), ((var X#8),A#12[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#8=S#11;E#10;E#9} in A#12[(var X#8)]) and constraints: E#9/= {}, (A#12[(var X#8)],(letrec {E#9} in [.])), ({E#10},(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#9} in S#11);E#10} in A#12[(var X#8)])} Delta1= {} Delta2= {E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(A#12[(var X#8)],(letrec {E#9} in [.])),[{E#10},(letrec {E#9} in [.])],((var X#2),T#7[[.]]),((var X#8),A#12[[.]]),((var X#8),A#12[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(var X#8)], E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#14}, E#13 |-> {X#1=T#7[(var X#2)];E#14}, E#3 |-> {X#8=(letrec {E#9} in S#11);E#14}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) <-ucp2- (letrec {X#1=T#7[S#4];X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(letrec {E#9} in S#11);E#14} in A#12[(var X#8)]) -SR,llet-e1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=S#11;E#14;E#9} in A#12[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;E#11 ;EE#14[X#9,(var X#8)] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec X#8= S#12 ;E#10 ;E#11 ;EE#14[X#9,(var X#8)] in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])],(letrec {E#10} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),[.]), ((var X#9),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18)]), T#15 |-> A#16[(app A#17[(var X#9)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#16[(app A#17[(var X#9)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#8= T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#10 ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in T#18);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), X#16 |-> X#8, E#17 |-> {E#11;EE#14[X#9,(var X#8)]}, T#15 |-> (letrec {E#10} in T#18), S#12 |-> T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=(letrec {E#10} in T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)]);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#19=T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#21} in S#12) ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#19= T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= S#12 ;E#11 ;E#21 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#11;E#21;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#21} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#21} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {X#19=T#18;E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), X#16 |-> X#8, E#17 |-> {E#11;EE#14[X#9,(var X#8)]}, T#15 |-> (letrec {X#19=T#18;E#21} in S#12), E#10 |-> {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#8=(letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {X#19=T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#21} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=S#12;E#11;E#21;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#1=T#7[S#4];E#19} in S#12) ;E#11 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;X#8= S#12 ;E#11 ;E#19 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#19} in S#12),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#11;E#19;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#19} in [.])), [{E#11;EE#14[X#9,(var X#8)]},(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#19} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=[.];E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), X#16 |-> X#8, E#17 |-> {E#11;EE#14[X#9,(var X#8)]}, T#15 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#19}, E#18 |-> {X#1=T#7[(var X#2)];E#19}, E#3 |-> {E#19}} and instantiated rules: (letrec {X#8=(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#19} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {X#1=T#7[S#4];E#19} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#19} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=S#12;E#11;E#19;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;X#8= (letrec {E#10} in S#12) ;E#18 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;X#8= S#12 ;E#10 ;E#18 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#10;E#18;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]), E#11 |-> {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18}, E#17 |-> {X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=(letrec {E#10} in S#12);E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];X#8=S#12;E#10;E#18;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#11 in A#13[(var X#9)] ) , (letrec X#8= S#12 ;X#9= A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21)];E#11} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]}, X#16 |-> X#9, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11}, T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#11 ;EE#20[X#19,(var X#8)] in A#13[(var X#9)] ) , (letrec X#8= S#12 ;X#9= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#10 ;E#11 ;EE#20[X#19,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;E#11;EE#20[X#19,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11;EE#20[X#19,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23)];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#9, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#19,(var X#8)]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;E#11;EE#20[X#19,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,(var X#8)] in A#13[(var X#9)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#21[X#9,(var X#19)] ;EE#22[X#20,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=S#12;E#10;E#11;EE#21[X#9,(var X#19)];EE#22[X#20,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#19= A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;X#8= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];X#8=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec {X#9=A#16[(letrec {E#10} in S#12)];E#11} in A#13[(var X#9)]) , (letrec {X#8=S#12;X#9=A#16[(var X#8)];E#10;E#11} in A#13[(var X#9)]) ) where Delta1 = {A#15,T#7,A#16} Delta2 = {E#10} Delta3 = {((var X#8),A#16[[.]]), ((letrec {E#10} in S#12),A#16[[.]]), ((letrec {X#9=A#16[(dummy3 )];E#11} in A#13[(var X#9)]),(letrec {X#8=(dummy3 )} in [.])), ((letrec {E#10} in S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),(letrec {X#9=A#16[(var X#8)];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=A#16[(var X#8)];E#11},(letrec {E#10} in [.])], ((var X#8),A#16[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], X#2 |-> X#8, S#4 |-> (letrec {E#10} in S#12), EE#14[.1,.2] |-> {[.1]=A#16[[.2]]}, X#1 |-> X#9, E#3 |-> {E#11}, A#15 |-> A#16, T#7 |-> A#16[[.]], T#17 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=A#16[(var X#8)];E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#9=A#16[(letrec {E#10} in S#12)];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=A#16[(var X#8)];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=A#16[(var X#8)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec {X#9=A#16[(letrec {E#10} in S#12)];E#11} in A#13[(var X#9)]) , (letrec {X#8=S#12;X#9=A#16[(var X#8)];E#10;E#11} in A#13[(var X#9)]) ) where Delta1 = {A#15,T#7,A#16} Delta2 = {E#10} Delta3 = {((var X#8),A#16), ((letrec {E#10} in S#12),A#16), ((letrec {X#9=A#16[(dummy3 )];E#11} in A#13[(var X#9)]),(letrec {X#8=(dummy3 )} in [.])), ((letrec {E#10} in S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),(letrec {X#9=A#16[(var X#8)];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=A#16[(var X#8)];E#11},(letrec {E#10} in [.])], ((var X#8),A#16[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], X#2 |-> X#8, S#4 |-> (letrec {E#10} in S#12), EE#14[.1,.2] |-> {[.1]=A#16[[.2]]}, X#1 |-> X#9, E#3 |-> {E#11}, A#15 |-> A#16[[.]], T#7 |-> A#16, A#17 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=A#16[(var X#8)];E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#9=A#16[(letrec {E#10} in S#12)];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=A#16[(var X#8)];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=A#16[(var X#8)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) , (letrec {X#8=S#12;X#9=(var X#8);E#10;E#11} in A#13[(var X#9)]) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#8),[.]), ((letrec {E#10} in S#12),[.]), ((letrec {X#9=(dummy3 );E#11} in A#13[(var X#9)]),(letrec {X#8=(dummy3 )} in [.])), ((letrec {E#10} in S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),(letrec {X#9=(var X#8);E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#9=(var X#8);E#11},(letrec {E#10} in [.])], ((var X#8),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], X#2 |-> X#8, S#4 |-> (letrec {E#10} in S#12), EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#3 |-> {E#11}, T#7 |-> [.], A#15 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#8=(letrec {E#10} in S#12);X#9=(var X#8);E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#9=(letrec {E#10} in S#12);E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);X#9=(var X#8);E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;X#9=(var X#8);E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(letrec {E#10} in S#12)] ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= A#18[(var X#8)] ;X#8= S#12 ;E#10 ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#15,T#7,A#18} Delta2 = {E#10} Delta3 = {((var X#8),A#18[[.]]), ((letrec {E#10} in S#12),A#18[[.]]), ((letrec {X#16=A#18[(dummy3 )];E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]),(letrec {X#8=(dummy3 )} in [.])), ((letrec {E#10} in S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#18[(var X#8)];E#10;E#11;EE#17[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#18[(var X#8)];E#11;EE#17[X#9,(var X#16)]},(letrec {E#10} in [.])], ((var X#8),A#18[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], X#2 |-> X#8, S#4 |-> (letrec {E#10} in S#12), EE#14[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#1 |-> X#16, E#3 |-> {E#11;EE#17[X#9,(var X#16)]}, A#15 |-> A#18, T#7 |-> A#18[[.]], T#19 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#16=A#18[(var X#8)];X#8=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#16=A#18[(letrec {E#10} in S#12)];E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#18[(var X#8)];X#8=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#18[(var X#8)];X#8=S#12;E#10;E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(letrec {E#10} in S#12)] ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= A#18[(var X#8)] ;X#8= S#12 ;E#10 ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {A#15,T#7,A#18} Delta2 = {E#10} Delta3 = {((var X#8),A#18), ((letrec {E#10} in S#12),A#18), ((letrec {X#16=A#18[(dummy3 )];E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]),(letrec {X#8=(dummy3 )} in [.])), ((letrec {E#10} in S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#18[(var X#8)];E#10;E#11;EE#17[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#18[(var X#8)];E#11;EE#17[X#9,(var X#16)]},(letrec {E#10} in [.])], ((var X#8),A#18[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], X#2 |-> X#8, S#4 |-> (letrec {E#10} in S#12), EE#14[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#1 |-> X#16, E#3 |-> {E#11;EE#17[X#9,(var X#16)]}, A#15 |-> A#18[[.]], T#7 |-> A#18, A#19 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#16=A#18[(var X#8)];X#8=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#16=A#18[(letrec {E#10} in S#12)];E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#18[(var X#8)];X#8=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#18[(var X#8)];X#8=S#12;E#10;E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#16= (letrec {E#10} in S#12) ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) , (letrec X#16= (var X#8) ;X#8= S#12 ;E#10 ;E#11 ;EE#17[X#9,(var X#16)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#8),[.]), ((letrec {E#10} in S#12),[.]), ((letrec {X#16=(dummy3 );E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]),(letrec {X#8=(dummy3 )} in [.])), ((letrec {E#10} in S#12),(letrec {X#8=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=(var X#8);E#10;E#11;EE#17[X#9,(var X#16)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=(var X#8);E#11;EE#17[X#9,(var X#16)]},(letrec {E#10} in [.])], ((var X#8),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], X#2 |-> X#8, S#4 |-> (letrec {E#10} in S#12), EE#14[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#1 |-> X#16, E#3 |-> {E#11;EE#17[X#9,(var X#16)]}, T#7 |-> [.], A#15 |-> [.], X#8 |-> X#8} and instantiated rules: (letrec {X#16=(var X#8);X#8=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#16=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=(var X#8);X#8=(letrec {E#10} in S#12);E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=(var X#8);X#8=S#12;E#10;E#11;EE#17[X#9,(var X#16)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in T#16[S#4]) ;E#15 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#2= S#4 ;X#8= T#16[(var X#2)] ;E#10 ;E#15 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((var X#2),(letrec {E#10} in T#16)), (S#4,(letrec {E#10} in T#16)), ((letrec {X#8=(letrec {E#10} in T#16[(dummy3 )]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#2=S#4;E#10;E#15;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=S#4;E#15;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),(letrec {E#10} in T#16[[.]])), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=S#4;E#15}, X#1 |-> X#8, E#3 |-> {E#15;EE#14[X#9,(var X#8)]}, T#7 |-> (letrec {E#10} in T#16), S#12 |-> T#16[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=(letrec {E#10} in T#16[(var X#2)]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in T#16[S#4]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=S#4;X#8=(letrec {E#10} in T#16[(var X#2)]);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#2=S#4;X#8=T#16[(var X#2)];E#10;E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {X#17=T#16[S#4];E#19} in S#12) ;E#15 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#17= T#16[(var X#2)] ;X#2= S#4 ;X#8= S#12 ;E#15 ;E#19 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((var X#2),(letrec {X#17=T#16;E#19} in S#12)), (S#4,(letrec {X#17=T#16;E#19} in S#12)), ((letrec {X#8=(letrec {X#17=T#16[(dummy3 )];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#17=T#16[(var X#2)];X#2=S#4;E#15;E#19;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {X#17=T#16[(var X#2)];E#19} in [.])), [{X#2=S#4;E#15;EE#14[X#9,(var X#8)]},(letrec {X#17=T#16[(var X#2)];E#19} in [.])], ((var X#2),(letrec {X#17=T#16[[.]];E#19} in S#12)), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=S#4;E#15}, X#1 |-> X#8, E#3 |-> {E#15;EE#14[X#9,(var X#8)]}, T#7 |-> (letrec {X#17=T#16;E#19} in S#12), E#10 |-> {X#17=T#16[(var X#2)];E#19}, E#18 |-> {E#19}} and instantiated rules: (letrec {X#2=S#4;X#8=(letrec {X#17=T#16[(var X#2)];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {X#17=T#16[S#4];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=S#4;X#8=(letrec {X#17=T#16[(var X#2)];E#19} in S#12);E#15;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=T#16[(var X#2)];X#2=S#4;X#8=S#12;E#15;E#19;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#1= T#7[S#4] ;X#8= (letrec {E#10} in S#12) ;E#16 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;X#8= S#12 ;E#10 ;E#16 ;EE#14[X#9,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#10;E#16;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),T#7[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#16}, E#15 |-> {X#1=T#7[(var X#2)];E#16}, E#3 |-> {X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#1=T#7[S#4];X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=(letrec {E#10} in S#12);E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;X#8=S#12;E#10;E#16;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#17[(app A#18[(var X#8)] T#19[S#4])] ;E#15 in A#13[(var X#9)] ) , (letrec X#2= S#4 ;X#8= S#12 ;X#9= A#17[(app A#18[(var X#8)] T#19[(var X#2)])] ;E#10 ;E#15 in A#13[(var X#9)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app A#18[(var X#8)] T#19)]), (S#4,A#17[(app A#18[(var X#8)] T#19)]), ((letrec {X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] T#19[(dummy3 )])];E#15} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#2=S#4;X#9=A#17[(app A#18[(var X#8)] T#19[(var X#2)])];E#10;E#15} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=S#4;X#9=A#17[(app A#18[(var X#8)] T#19[(var X#2)])];E#15},(letrec {E#10} in [.])], ((var X#2),A#17[(app A#18[(var X#8)] T#19[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(var X#2)])]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#15}, T#7 |-> A#17[(app A#18[(var X#8)] T#19)], A#16 |-> A#17[(app A#18 T#19[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] T#19[(var X#2)])];E#15} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] T#19[S#4])];E#15} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=S#4;X#8=(letrec {E#10} in S#12);X#9=A#17[(app A#18[(var X#8)] T#19[(var X#2)])];E#15} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#2=S#4;X#8=S#12;X#9=A#17[(app A#18[(var X#8)] T#19[(var X#2)])];E#10;E#15} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#19[(app A#20[(var X#17)] T#21[S#4])] ;E#15 ;EE#18[X#17,(var X#8)] in A#13[(var X#9)] ) , (letrec X#2= S#4 ;X#8= S#12 ;X#9= A#19[(app A#20[(var X#17)] T#21[(var X#2)])] ;E#10 ;E#15 ;EE#18[X#17,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(var X#17)] T#21)]), (S#4,A#19[(app A#20[(var X#17)] T#21)]), ((letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] T#21[(dummy3 )])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#2=S#4;X#9=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#10;E#15;EE#18[X#17,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#2=S#4;X#9=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),A#19[(app A#20[(var X#17)] T#21[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];EE#18[X#17,[.2]]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#15;EE#18[X#17,(var X#8)]}, T#7 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] T#21[S#4])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#2=S#4;X#8=(letrec {E#10} in S#12);X#9=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#2=S#4;X#8=S#12;X#9=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#10;E#15;EE#18[X#17,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[S#4])] ;X#8= (letrec {E#10} in S#12) ;E#15 ;EE#19[X#9,(var X#17)] ;EE#20[X#18,(var X#8)] in A#13[(var X#9)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(var X#2)])] ;X#2= S#4 ;X#8= S#12 ;E#10 ;E#15 ;EE#19[X#9,(var X#17)] ;EE#20[X#18,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#21[(app A#22[(var X#18)] T#23)]), (S#4,A#21[(app A#22[(var X#18)] T#23)]), ((letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(dummy3 )])];X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#10;E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]},(letrec {E#10} in [.])], ((var X#2),A#21[(app A#22[(var X#18)] T#23[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, E#3 |-> {X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]}, T#7 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(var X#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[S#4])];X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;X#8=(letrec {E#10} in S#12);E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;X#8=S#12;E#10;E#15;EE#19[X#9,(var X#17)];EE#20[X#18,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#8)] T#21[S#4])] ;X#8= (letrec {E#10} in S#12) ;E#15 ;EE#18[X#9,(var X#17)] in A#13[(var X#9)] ) , (letrec X#17= A#19[(app A#20[(var X#8)] T#21[(var X#2)])] ;X#2= S#4 ;X#8= S#12 ;E#10 ;E#15 ;EE#18[X#9,(var X#17)] in A#13[(var X#9)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(var X#8)] T#21)]), (S#4,A#19[(app A#20[(var X#8)] T#21)]), ((letrec {X#17=A#19[(app A#20[(var X#8)] T#21[(dummy3 )])];X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), ((var X#8),(letrec {X#17=A#19[(app A#20[(var X#8)] T#21[(var X#2)])];X#2=S#4;E#10;E#15;EE#18[X#9,(var X#17)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#17=A#19[(app A#20[(var X#8)] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#9,(var X#17)]},(letrec {E#10} in [.])], ((var X#2),A#19[(app A#20[(var X#8)] T#21[[.]])]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], E#11 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(var X#2)])];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]}, T#7 |-> A#19[(app A#20[(var X#8)] T#21)], A#16 |-> A#19[(app A#20 T#21[(var X#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#8)] T#21[(var X#2)])];X#2=S#4;X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#17=A#19[(app A#20[(var X#8)] T#21[S#4])];X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#8)] T#21[(var X#2)])];X#2=S#4;X#8=(letrec {E#10} in S#12);E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#17=A#19[(app A#20[(var X#8)] T#21[(var X#2)])];X#2=S#4;X#8=S#12;E#10;E#15;EE#18[X#9,(var X#17)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#21[A#15[(var X#17)]] ;E#11 ;EE#19[X#17,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= S#12 ;X#9= A#21[(var X#16)] ;E#10 ;E#11 ;EE#19[X#17,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), (A#15[(var X#17)],A#21[[.]]), ((letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(dummy3 )];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#17)];X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#17,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#17)];X#9=A#21[(var X#16)];E#11;EE#19[X#17,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=A#21[(var X#16)];EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)]}, A#20 |-> A#21, T#7 |-> A#21[[.]], T#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[A#15[(var X#17)]];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#8=S#12;X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#21[A#15[(var X#17)]] ;E#11 ;EE#19[X#17,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= S#12 ;X#9= A#21[(var X#16)] ;E#10 ;E#11 ;EE#19[X#17,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), (A#15[(var X#17)],A#21), ((letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[(dummy3 )];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#17)];X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#17,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#17)];X#9=A#21[(var X#16)];E#11;EE#19[X#17,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=A#21[(var X#16)];EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)]}, A#20 |-> A#21[[.]], T#7 |-> A#21, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#21[A#15[(var X#17)]];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);X#9=A#21[(var X#16)];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#8=S#12;X#9=A#21[(var X#16)];E#10;E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#15[(var X#17)] ;E#11 ;EE#19[X#17,(var X#8)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= S#12 ;X#9= (var X#16) ;E#10 ;E#11 ;EE#19[X#17,(var X#8)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(var X#17)],[.]), ((letrec {X#8=(letrec {E#10} in S#12);X#9=(dummy3 );E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#17)];X#9=(var X#16);E#10;E#11;EE#19[X#17,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#17)];X#9=(var X#16);E#11;EE#19[X#17,(var X#8)]},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=(var X#16);EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)]}, T#7 |-> [.], A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);X#9=(var X#16);E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#15[(var X#17)];E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);X#9=(var X#16);E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#8=S#12;X#9=(var X#16);E#10;E#11;EE#19[X#17,(var X#8)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#15[(var X#17)]] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#17,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= A#23[(var X#16)] ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#17,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,T#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[[.]]), (A#15[(var X#17)],A#23[[.]]), ((letrec {X#21=A#23[(dummy3 )];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),A#23[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]}, A#20 |-> A#23, T#7 |-> A#23[[.]], T#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#21=A#23[A#15[(var X#17)]];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];X#8=S#12;E#10;E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#15[(var X#17)]] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#17,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= A#23[(var X#16)] ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#17,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {A#20,T#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23), (A#15[(var X#17)],A#23), ((letrec {X#21=A#23[(dummy3 )];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#10;E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),A#23[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]}, A#20 |-> A#23[[.]], T#7 |-> A#23, A#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#21=A#23[A#15[(var X#17)]];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];X#8=S#12;E#10;E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#21= A#15[(var X#17)] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#19[X#17,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= (var X#16) ;X#8= S#12 ;E#10 ;E#11 ;EE#19[X#17,(var X#8)] ;EE#22[X#9,(var X#21)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(var X#17)],[.]), ((letrec {X#21=(dummy3 );X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#10;E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#17)];X#21=(var X#16);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=(var X#16);EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]}, T#7 |-> [.], A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#21=A#15[(var X#17)];X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);X#8=(letrec {E#10} in S#12);E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);X#8=S#12;E#10;E#11;EE#19[X#17,(var X#8)];EE#22[X#9,(var X#21)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#19[A#15[(var X#8)]] ;E#11 in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#8)] ;X#8= S#12 ;X#9= A#19[(var X#16)] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#16),A#19[[.]]), (A#15[(var X#8)],A#19[[.]]), ((letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(dummy3 )];E#11} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#8)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#8)];X#9=A#19[(var X#16)];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#8)];X#9=A#19[(var X#16)];E#11},(letrec {E#10} in [.])], ((var X#16),A#19[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#8)], EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11}, A#18 |-> A#19, T#7 |-> A#19[[.]], T#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[A#15[(var X#8)]];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#8)];X#8=S#12;X#9=A#19[(var X#16)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#19[A#15[(var X#8)]] ;E#11 in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#8)] ;X#8= S#12 ;X#9= A#19[(var X#16)] ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#16),A#19), (A#15[(var X#8)],A#19), ((letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[(dummy3 )];E#11} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#8)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#8)];X#9=A#19[(var X#16)];E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#8)];X#9=A#19[(var X#16)];E#11},(letrec {E#10} in [.])], ((var X#16),A#19[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#8)], EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11}, A#18 |-> A#19[[.]], T#7 |-> A#19, A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#19[A#15[(var X#8)]];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);X#9=A#19[(var X#16)];E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#8)];X#8=S#12;X#9=A#19[(var X#16)];E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#8= (letrec {E#10} in S#12) ;X#9= A#15[(var X#8)] ;E#11 in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#8)] ;X#8= S#12 ;X#9= (var X#16) ;E#10 ;E#11 in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(var X#8)],[.]), ((letrec {X#8=(letrec {E#10} in S#12);X#9=(dummy3 );E#11} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#8)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#8)];X#9=(var X#16);E#10;E#11} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#8)];X#9=(var X#16);E#11},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=(var X#16)}, X#2 |-> X#16, S#4 |-> A#15[(var X#8)], EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#9, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11}, T#7 |-> [.], A#18 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);X#9=(var X#16);E#11} in A#13[(var X#9)]) <-ucp2- (letrec {X#8=(letrec {E#10} in S#12);X#9=A#15[(var X#8)];E#11} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);X#9=(var X#16);E#11} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#8)];X#8=S#12;X#9=(var X#16);E#10;E#11} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#15[(var X#8)]] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#8)] ;X#19= A#21[(var X#16)] ;X#8= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), (A#15[(var X#8)],A#21[[.]]), ((letrec {X#19=A#21[(dummy3 )];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#8)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#8)], EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, A#18 |-> A#21, T#7 |-> A#21[[.]], T#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#19=A#21[A#15[(var X#8)]];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];X#8=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#15[(var X#8)]] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#8)] ;X#19= A#21[(var X#16)] ;X#8= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {A#18,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), (A#15[(var X#8)],A#21), ((letrec {X#19=A#21[(dummy3 )];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#8)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),A#21[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#8)], EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, A#18 |-> A#21[[.]], T#7 |-> A#21, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#19=A#21[A#15[(var X#8)]];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#8)];X#19=A#21[(var X#16)];X#8=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( (letrec X#19= A#15[(var X#8)] ;X#8= (letrec {E#10} in S#12) ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) , (letrec X#16= A#15[(var X#8)] ;X#19= (var X#16) ;X#8= S#12 ;E#10 ;E#11 ;EE#20[X#9,(var X#19)] in A#13[(var X#9)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(var X#8)],[.]), ((letrec {X#19=(dummy3 );X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#8)],(letrec {X#16=(dummy3 )} in [.])), ((var X#8),(letrec {X#16=A#15[(var X#8)];X#19=(var X#16);E#10;E#11;EE#20[X#9,(var X#19)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), [{X#16=A#15[(var X#8)];X#19=(var X#16);E#11;EE#20[X#9,(var X#19)]},(letrec {E#10} in [.])], ((var X#16),[.]), ((var X#8),[.]), ((var X#9),A#13[[.]]), ((var X#8),[.]), ((var X#9),A#13[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#8=S#12;E#10;E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)]) and constraints: E#10/= {}, ((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])), (A#13[(var X#9)],(letrec {E#10} in [.])), ({E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {X#8=(letrec {E#10} in S#12);E#11;EE#14[X#9,(var X#8)]} in A#13[(var X#9)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),((var X#8),(letrec {E#10;E#11;EE#14[X#9,(var X#8)]} in [.])),(A#13[(var X#9)],(letrec {E#10} in [.])),[{E#11;EE#14[X#9,(var X#8)]},(letrec {E#10} in [.])],((var X#2),T#7[[.]]),((var X#8),[.]),((var X#9),A#13[[.]]),((var X#8),[.]),((var X#9),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#9)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=(var X#16);EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#8)], EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]}, T#7 |-> [.], A#18 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#8)];X#19=(var X#16);X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) <-ucp2- (letrec {X#19=A#15[(var X#8)];X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ................................................................................ (letrec {X#16=A#15[(var X#8)];X#19=(var X#16);X#8=(letrec {E#10} in S#12);E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) -SR,llet-e2-> (letrec {X#16=A#15[(var X#8)];X#19=(var X#16);X#8=S#12;E#10;E#11;EE#20[X#9,(var X#19)]} in A#13[(var X#9)]) ================================================================================ Critical Pair: ( A#12[(app (letrec {E#8} in T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#9)] , A#12[(letrec E#8 in (app T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#9) )] ) where Delta1 = {T#14,T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (letrec {E#8} in T#15) S#9)], T#13 |-> (app (letrec {E#8} in T#15) S#9), T#14 |-> (letrec {E#8} in T#15), S#10 |-> T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: A#12[(app (letrec {E#8} in T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#9)] <-ucp2- A#12[(app (letrec {E#8} in T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#9)] ................................................................................ A#12[(app (letrec {E#8} in T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#9)] -SR,lapp1-> A#12[(letrec {E#8} in (app T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#9))] ================================================================================ Critical Pair: ( A#12[(app (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#18} in S#10) S#9)] , A#12[(letrec X#16= T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#18 in (app S#10 S#9) )] ) where Delta1 = {T#14,T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (letrec {X#16=T#15;E#18} in S#10) S#9)], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#10) S#9), T#14 |-> (letrec {X#16=T#15;E#18} in S#10), E#8 |-> {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18}, E#17 |-> {E#18}} and instantiated rules: A#12[(app (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in S#10) S#9)] <-ucp2- A#12[(app (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#18} in S#10) S#9)] ................................................................................ A#12[(app (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in S#10) S#9)] -SR,lapp1-> A#12[(letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in (app S#10 S#9))] ================================================================================ Critical Pair: ( A#12[(app (letrec {X#1=T#7[S#4];E#16} in S#10) S#9)] , A#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in (app S#10 S#9))] ) where Delta1 = {T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#16} in S#10),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app [.] S#9)], T#13 |-> (app [.] S#9), T#14 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#16}, E#15 |-> {X#1=T#7[(var X#2)];E#16}, E#3 |-> {E#16}} and instantiated rules: A#12[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in S#10) S#9)] <-ucp2- A#12[(app (letrec {X#1=T#7[S#4];E#16} in S#10) S#9)] ................................................................................ A#12[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in S#10) S#9)] -SR,lapp1-> A#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in (app S#10 S#9))] ================================================================================ Critical Pair: ( A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] , A#12[(letrec E#8 in (app S#10 T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) )] ) where Delta1 = {T#13,A#11,T#6,A#12} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#8} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> A#12, T#6 |-> A#12[(app (letrec {E#8} in S#10) T#14)], T#13 |-> (app (letrec {E#8} in S#10) T#14), S#9 |-> T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] <-ucp2- A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ................................................................................ A#12[(app (letrec {E#8} in S#10) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] -SR,lapp1-> A#12[(letrec {E#8} in (app S#10 T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]))] ================================================================================ Critical Pair: ( A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] , A#12[(app A#13[(letrec {E#8} in (app S#10 S#9))] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) where Delta1 = {A#11,T#6} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14)], A#11 |-> A#12[(app A#13 T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] <-ucp2- A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ................................................................................ A#12[(app A#13[(app (letrec {E#8} in S#10) S#9)] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] -SR,lapp1-> A#12[(app A#13[(letrec {E#8} in (app S#10 S#9))] T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ================================================================================ Critical Pair: ( (app (letrec {E#8} in T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#9) , (letrec E#8 in (app T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#9) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {E#8} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (letrec {E#8} in T#13) S#9), T#12 |-> (letrec {E#8} in T#13), S#10 |-> T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (app (letrec {E#8} in T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#9) <-ucp2- (app (letrec {E#8} in T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#9) ................................................................................ (app (letrec {E#8} in T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#9) -SR,lapp1-> (letrec {E#8} in (app T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#9)) ================================================================================ Critical Pair: ( (app (letrec {X#14=T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#16} in S#10) S#9) , (letrec X#14= T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#16 in (app S#10 S#9) ) ) where Delta1 = {T#12,T#6} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (letrec {X#14=T#13;E#16} in S#10) S#9), T#12 |-> (letrec {X#14=T#13;E#16} in S#10), E#8 |-> {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16}, E#15 |-> {E#16}} and instantiated rules: (app (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in S#10) S#9) <-ucp2- (app (letrec {X#14=T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#16} in S#10) S#9) ................................................................................ (app (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in S#10) S#9) -SR,lapp1-> (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in (app S#10 S#9)) ================================================================================ Critical Pair: ( (app (letrec {X#1=T#7[S#4];E#14} in S#10) S#9) , (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in (app S#10 S#9)) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#14} in S#10),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#9,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app [.] S#9), T#12 |-> [.], S#5 |-> S#10, E#8 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#14}, E#13 |-> {X#1=T#7[(var X#2)];E#14}, E#3 |-> {E#14}} and instantiated rules: (app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in S#10) S#9) <-ucp2- (app (letrec {X#1=T#7[S#4];E#14} in S#10) S#9) ................................................................................ (app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in S#10) S#9) -SR,lapp1-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in (app S#10 S#9)) ================================================================================ Critical Pair: ( (app (letrec {E#8} in S#10) T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)]) , (letrec E#8 in (app S#10 T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) ) ) where Delta1 = {T#6} Delta2 = {E#8} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#8} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ A#11[(app (letrec {E#8} in S#10) S#9)] -SR,lapp1-> A#11[(letrec {E#8} in (app S#10 S#9))] and constraints: E#8/= {}, (S#9,(letrec {E#8} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= A#11[(app (letrec {E#8} in S#10) S#9)]} Delta1= {} Delta2= {E#8} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#9,(letrec {E#8} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {A#11 |-> [.], T#6 |-> (app (letrec {E#8} in S#10) T#12), S#9 |-> T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (app (letrec {E#8} in S#10) T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) <-ucp2- (app (letrec {E#8} in S#10) T#12[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ................................................................................ (app (letrec {E#8} in S#10) T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) -SR,lapp1-> (letrec {E#8} in (app S#10 T#12[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#10)] ) , (letrec E#8 in A#14[(letrec E#9 in (app T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#10) )] ) ) where Delta1 = {T#16,T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app (letrec {E#9} in T#17) S#10)]), A#12 |-> A#14, T#13 |-> A#14[(app (letrec {E#9} in T#17) S#10)], T#15 |-> (app (letrec {E#9} in T#17) S#10), T#16 |-> (letrec {E#9} in T#17), S#11 |-> T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#10)]) <-ucp2- (letrec {E#8} in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#10)]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {E#9} in T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#10)]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {E#9} in (app T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#10))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec {X#18=T#17[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#20} in S#11) S#10)] ) , (letrec E#8 in A#14[(letrec X#18= T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#20 in (app S#11 S#10) )] ) ) where Delta1 = {T#16,T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {X#18=T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#20} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app (letrec {X#18=T#17;E#20} in S#11) S#10)]), A#12 |-> A#14, T#13 |-> A#14[(app (letrec {X#18=T#17;E#20} in S#11) S#10)], T#15 |-> (app (letrec {X#18=T#17;E#20} in S#11) S#10), T#16 |-> (letrec {X#18=T#17;E#20} in S#11), E#9 |-> {X#18=T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {X#18=T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#20} in S#11) S#10)]) <-ucp2- (letrec {E#8} in A#14[(app (letrec {X#18=T#17[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#20} in S#11) S#10)]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {X#18=T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#20} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {X#18=T#17[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#20} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec {E#8} in A#14[(app (letrec {X#1=T#7[S#4];E#18} in S#11) S#10)]) , (letrec E#8 in A#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#18} in (app S#11 S#10))] ) ) where Delta1 = {T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#18} in S#11),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#18} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app [.] S#10)]), A#12 |-> A#14, T#13 |-> A#14[(app [.] S#10)], T#15 |-> (app [.] S#10), T#16 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#18}, E#17 |-> {X#1=T#7[(var X#2)];E#18}, E#3 |-> {E#18}} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#18} in S#11) S#10)]) <-ucp2- (letrec {E#8} in A#14[(app (letrec {X#1=T#7[S#4];E#18} in S#11) S#10)]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#18} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#18} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec E#8 in A#14[(letrec E#9 in (app S#11 T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) )] ) ) where Delta1 = {T#15,A#12,T#13,T#6,A#14} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16)]), A#12 |-> A#14, T#13 |-> A#14[(app (letrec {E#9} in S#11) T#16)], T#15 |-> (app (letrec {E#9} in S#11) T#16), S#10 |-> T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {E#8} in A#14[(app (letrec {E#9} in S#11) T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,lapp2-> (letrec {E#8} in A#14[(letrec {E#9} in (app S#11 T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]))]) ================================================================================ Critical Pair: ( (letrec E#8 in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec E#8 in A#14[(app A#15[(letrec {E#9} in (app S#11 S#10))] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#12,T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16)]), T#13 |-> A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16)], A#12 |-> A#14[(app A#15 T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {E#8} in A#14[(app A#15[(app (letrec {E#9} in S#11) S#10)] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,lapp2-> (letrec {E#8} in A#14[(app A#15[(letrec {E#9} in (app S#11 S#10))] T#16[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec {E#9} in T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#10) ) , (letrec E#8 in (letrec E#9 in (app T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#10) ) ) ) where Delta1 = {T#14,T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (letrec {E#9} in T#15) S#10)), A#12 |-> [.], T#13 |-> (app (letrec {E#9} in T#15) S#10), T#14 |-> (letrec {E#9} in T#15), S#11 |-> T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#8} in (app (letrec {E#9} in T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#10)) <-ucp2- (letrec {E#8} in (app (letrec {E#9} in T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#10)) ................................................................................ (letrec {E#8} in (app (letrec {E#9} in T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#10)) -SR,lapp2-> (letrec {E#8} in (letrec {E#9} in (app T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#10))) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#18} in S#11) S#10) ) , (letrec E#8 in (letrec X#16= T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#18 in (app S#11 S#10) ) ) ) where Delta1 = {T#14,T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (letrec {X#16=T#15;E#18} in S#11) S#10)), A#12 |-> [.], T#13 |-> (app (letrec {X#16=T#15;E#18} in S#11) S#10), T#14 |-> (letrec {X#16=T#15;E#18} in S#11), E#9 |-> {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {E#8} in (app (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in S#11) S#10)) <-ucp2- (letrec {E#8} in (app (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#18} in S#11) S#10)) ................................................................................ (letrec {E#8} in (app (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in S#11) S#10)) -SR,lapp2-> (letrec {E#8} in (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18} in (app S#11 S#10))) ================================================================================ Critical Pair: ( (letrec {E#8} in (app (letrec {X#1=T#7[S#4];E#16} in S#11) S#10)) , (letrec {E#8} in (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in (app S#11 S#10))) ) where Delta1 = {T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#16} in S#11),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app [.] S#10)), A#12 |-> [.], T#13 |-> (app [.] S#10), T#14 |-> [.], S#5 |-> S#11, E#9 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#16}, E#15 |-> {X#1=T#7[(var X#2)];E#16}, E#3 |-> {E#16}} and instantiated rules: (letrec {E#8} in (app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in S#11) S#10)) <-ucp2- (letrec {E#8} in (app (letrec {X#1=T#7[S#4];E#16} in S#11) S#10)) ................................................................................ (letrec {E#8} in (app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in S#11) S#10)) -SR,lapp2-> (letrec {E#8} in (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16} in (app S#11 S#10))) ================================================================================ Critical Pair: ( (letrec E#8 in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ) , (letrec E#8 in (letrec E#9 in (app S#11 T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) ) ) ) where Delta1 = {T#13,T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#8} in (app (letrec {E#9} in S#11) T#14)), A#12 |-> [.], T#13 |-> (app (letrec {E#9} in S#11) T#14), S#10 |-> T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {E#8} in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) <-ucp2- (letrec {E#8} in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=T#7[S#4];E#3} in S#5)])) ................................................................................ (letrec {E#8} in (app (letrec {E#9} in S#11) T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])) -SR,lapp2-> (letrec {E#8} in (letrec {E#9} in (app S#11 T#14[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]))) ================================================================================ Critical Pair: ( (letrec X#14= T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;E#16 in A#12[(app (letrec {E#9} in S#11) S#10)] ) , (letrec X#14= T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#16 in A#12[(letrec {E#9} in (app S#11 S#10))] ) ) where Delta1 = {T#6} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#14=T#13;E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]), E#8 |-> {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]) <-ucp2- (letrec {X#14=T#13[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {X#14=T#13[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#16} in A#12[(letrec {E#9} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec {X#1=T#7[S#4];E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;E#14 in A#12[(letrec {E#9} in (app S#11 S#10))] ) ) where Delta1 = {} Delta2 = {E#8,E#9} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#10,(letrec {E#9} in [.])), ((var X#2),T#7[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {E#8} in A#12[(letrec {E#9} in (app S#11 S#10))]) and constraints: E#8/= {}, E#9/= {}, (S#10,(letrec {E#9} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#8} in A#12[(app (letrec {E#9} in S#11) S#10)])} Delta1= {} Delta2= {E#8,E#9} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#10,(letrec {E#9} in [.])),((var X#2),T#7[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#12[(app (letrec {E#9} in S#11) S#10)], E#8 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#14}, E#13 |-> {X#1=T#7[(var X#2)];E#14}, E#3 |-> {E#14}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) <-ucp2- (letrec {X#1=T#7[S#4];E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(app (letrec {E#9} in S#11) S#10)]) -SR,lapp2-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#14} in A#12[(letrec {E#9} in (app S#11 S#10))]) ================================================================================ Critical Pair: ( (letrec E#9 ;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ) , (letrec E#9 ;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))] in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ) ) where Delta1 = {A#13,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]), ((var X#8),A#16[(app A#17[[.]] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18)]), T#15 |-> A#16[(app A#17[(var X#8)] T#18)], A#13 |-> A#16[(app A#17 T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) <-ucp2- (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[S#4];E#3} in S#5)])]) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#16[(app A#17[(var X#8)] T#18[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)] ;E#18 ;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#18 ;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#16=T#15;E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]), E#9 |-> {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18}, E#17 |-> {E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#16=T#15[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=T#15[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#18;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {E#10} in T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11)] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec E#10 in (app T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11) )] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (letrec {E#10} in T#22) S#11)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app (letrec {E#10} in T#22) S#11)], T#20 |-> (app (letrec {E#10} in T#22) S#11), T#21 |-> (letrec {E#10} in T#22), S#12 |-> T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=A#19[(app (letrec {E#10} in T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11)];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app (letrec {E#10} in T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {E#10} in T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {E#10} in (app T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {X#23=T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#25} in S#12) S#11)] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec X#23= T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#25 in (app S#12 S#11) )] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)], T#20 |-> (app (letrec {X#23=T#22;E#25} in S#12) S#11), T#21 |-> (letrec {X#23=T#22;E#25} in S#12), E#10 |-> {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#8=A#19[(app (letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app (letrec {X#23=T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in S#12) S#11)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in (app S#12 S#11))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {X#1=T#7[S#4];E#23} in S#12) S#11)] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in (app S#12 S#11))] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#23} in S#12),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app [.] S#11)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app [.] S#11)], T#20 |-> (app [.] S#11), T#21 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#23}, E#22 |-> {X#1=T#7[(var X#2)];E#23}, E#3 |-> {E#23}} and instantiated rules: (letrec {X#8=A#19[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in S#12) S#11)];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app (letrec {X#1=T#7[S#4];E#23} in S#12) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in S#12) S#11)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in (app S#12 S#11))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(letrec E#10 in (app S#12 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) )] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#18,T#15,T#6,A#19} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> A#19, T#15 |-> A#19[(app (letrec {E#10} in S#12) T#21)], T#20 |-> (app (letrec {E#10} in S#12) T#21), S#11 |-> T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(letrec {E#10} in (app S#12 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]))];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#9 in A#13[(var X#8)] ) , (letrec X#8= A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)];E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]}, X#16 |-> X#8, E#17 |-> {E#9}, T#15 |-> A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {E#10} in T#20[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec E#10 in (app T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11) ) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (letrec {E#10} in T#20) S#11);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in T#20) S#11), T#19 |-> (letrec {E#10} in T#20), S#12 |-> T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=(app (letrec {E#10} in T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11);E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {E#10} in T#20[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {E#10} in T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {E#10} in (app T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {X#21=T#20[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#23} in S#12) S#11) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec X#21= T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#23 in (app S#12 S#11) ) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#21=T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#23} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (letrec {X#21=T#20;E#23} in S#12) S#11);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app (letrec {X#21=T#20;E#23} in S#12) S#11), T#19 |-> (letrec {X#21=T#20;E#23} in S#12), E#10 |-> {X#21=T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#8=(app (letrec {X#21=T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#23} in S#12) S#11);E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {X#21=T#20[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#23} in S#12) S#11);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {X#21=T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#23} in S#12) S#11);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {X#21=T#20[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#23} in (app S#12 S#11));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {X#1=T#7[S#4];E#21} in S#12) S#11) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#21} in (app S#12 S#11)) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#21} in S#12),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#21} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app [.] S#11);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app [.] S#11), T#19 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#21}, E#20 |-> {X#1=T#7[(var X#2)];E#21}, E#3 |-> {E#21}} and instantiated rules: (letrec {X#8=(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#21} in S#12) S#11);E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {X#1=T#7[S#4];E#21} in S#12) S#11);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#21} in S#12) S#11);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#21} in (app S#12 S#11));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {E#10} in S#12) T#19[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ;E#9 in A#13[(var X#8)] ) , (letrec X#8= (letrec E#10 in (app S#12 T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) ) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=(app (letrec {E#10} in S#12) T#19);E#9} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#8, E#17 |-> {E#9}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in S#12) T#19), S#11 |-> T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#8=(app (letrec {E#10} in S#12) T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {E#10} in S#12) T#19[(letrec {X#1=T#7[S#4];E#3} in S#5)]);E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=(app (letrec {E#10} in S#12) T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=(letrec {E#10} in (app S#12 T#19[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]));E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#9 ;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#8= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#20[X#19,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#20[X#19,[.2]]}, X#16 |-> X#8, E#17 |-> {E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#19,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#8=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#19,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#9 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#21[X#8,(var X#19)] ;EE#22[X#20,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#21[X#8,(var X#19)];EE#22[X#20,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {E#10} in T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec E#10 in (app T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11) )] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#23,T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (letrec {E#10} in T#24) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (letrec {E#10} in T#24) S#11)], T#22 |-> (app (letrec {E#10} in T#24) S#11), T#23 |-> (letrec {E#10} in T#24), S#12 |-> T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#19=A#21[(app (letrec {E#10} in T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app (letrec {E#10} in T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {E#10} in T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {E#10} in (app T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {X#25=T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#27} in S#12) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec X#25= T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#27 in (app S#12 S#11) )] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#23,T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#25=T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#27} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (letrec {X#25=T#24;E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (letrec {X#25=T#24;E#27} in S#12) S#11)], T#22 |-> (app (letrec {X#25=T#24;E#27} in S#12) S#11), T#23 |-> (letrec {X#25=T#24;E#27} in S#12), E#10 |-> {X#25=T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#27}, E#26 |-> {E#27}} and instantiated rules: (letrec {X#19=A#21[(app (letrec {X#25=T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app (letrec {X#25=T#24[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {X#25=T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#27} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {X#25=T#24[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#27} in (app S#12 S#11))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {X#1=T#7[S#4];E#25} in S#12) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#25} in (app S#12 S#11))] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#25} in S#12),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#25} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app [.] S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app [.] S#11)], T#22 |-> (app [.] S#11), T#23 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#25}, E#24 |-> {X#1=T#7[(var X#2)];E#25}, E#3 |-> {E#25}} and instantiated rules: (letrec {X#19=A#21[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#25} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app (letrec {X#1=T#7[S#4];E#25} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#25} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#25} in (app S#12 S#11))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(letrec E#10 in (app S#12 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) )] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#22,A#18,T#15,T#6,A#21} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#15 |-> A#21[(app (letrec {E#10} in S#12) T#23)], T#22 |-> (app (letrec {E#10} in S#12) T#23), S#11 |-> T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app (letrec {E#10} in S#12) T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(letrec {E#10} in (app S#12 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]))];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, T#15 |-> A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=T#7[S#4];E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(app (letrec {E#10} in S#12) S#11)] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=A#21[(app A#22[(letrec {E#10} in (app S#12 S#11))] T#23[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)])];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {E#10} in T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec E#10 in (app T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11) ) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (letrec {E#10} in T#22) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in T#22) S#11), T#21 |-> (letrec {E#10} in T#22), S#12 |-> T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#19=(app (letrec {E#10} in T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=(app (letrec {E#10} in T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)]) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {E#10} in T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {E#10} in (app T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] S#11));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {X#23=T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#25} in S#12) S#11) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec X#23= T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] ;E#25 in (app S#12 S#11) ) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (letrec {X#23=T#22;E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (letrec {X#23=T#22;E#25} in S#12) S#11), T#21 |-> (letrec {X#23=T#22;E#25} in S#12), E#10 |-> {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#19=(app (letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=(app (letrec {X#23=T#22[(letrec {X#1=T#7[S#4];E#3} in S#5)];E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {X#23=T#22[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)];E#25} in (app S#12 S#11));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {X#1=T#7[S#4];E#23} in S#12) S#11) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in (app S#12 S#11)) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#23} in S#12),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app [.] S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app [.] S#11), T#21 |-> [.], S#5 |-> S#12, E#10 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#23}, E#22 |-> {X#1=T#7[(var X#2)];E#23}, E#3 |-> {E#23}} and instantiated rules: (letrec {X#19=(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=(app (letrec {X#1=T#7[S#4];E#23} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in S#12) S#11);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#23} in (app S#12 S#11));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= (app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)]) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#19= (letrec E#10 in (app S#12 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]) ) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {T#15,T#6} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)],(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> (letrec {X#19=(app (letrec {E#10} in S#12) T#21);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]), EE#14[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> [.], T#15 |-> (app (letrec {E#10} in S#12) T#21), S#11 |-> T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]} and instantiated rules: (letrec {X#19=(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[S#4];E#3} in S#5)]);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#19=(app (letrec {E#10} in S#12) T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#19=(letrec {E#10} in (app S#12 T#21[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)]));E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#1= T#7[S#4] ;E#16 ;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#1= T#7[(var X#2)] ;X#2= S#4 ;E#16 ;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),T#7[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#1=T#7[(var X#2)];X#2=S#4;E#16}, E#15 |-> {X#1=T#7[(var X#2)];E#16}, E#3 |-> {E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]}} and instantiated rules: (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#1=T#7[S#4];E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#1=T#7[(var X#2)];X#2=S#4;E#16;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#17[(app (letrec {E#10} in T#20[S#4]) S#11)] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#17[(letrec {E#10} in (app T#20[(var X#2)] S#11))] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#18,A#16,T#7,A#17} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app (letrec {E#10} in T#20) S#11)]), (S#4,A#17[(app (letrec {E#10} in T#20) S#11)]), ((letrec {X#8=A#17[(app (letrec {E#10} in T#20[(dummy3 )]) S#11)];E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),A#17[(app (letrec {E#10} in T#20[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> A#17, T#7 |-> A#17[(app (letrec {E#10} in T#20) S#11)], T#18 |-> (app (letrec {E#10} in T#20) S#11), T#19 |-> (letrec {E#10} in T#20), S#12 |-> T#20[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=A#17[(app (letrec {E#10} in T#20[(var X#2)]) S#11)];E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#17[(app (letrec {E#10} in T#20[S#4]) S#11)];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#17[(app (letrec {E#10} in T#20[(var X#2)]) S#11)];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=A#17[(letrec {E#10} in (app T#20[(var X#2)] S#11))];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#17[(app (letrec {X#21=T#20[S#4];E#23} in S#12) S#11)] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#17[(letrec {X#21=T#20[(var X#2)];E#23} in (app S#12 S#11))] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#18,A#16,T#7,A#17} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app (letrec {X#21=T#20;E#23} in S#12) S#11)]), (S#4,A#17[(app (letrec {X#21=T#20;E#23} in S#12) S#11)]), ((letrec {X#8=A#17[(app (letrec {X#21=T#20[(dummy3 )];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#21=T#20[(var X#2)];E#23} in [.])), ((var X#2),A#17[(app (letrec {X#21=T#20[[.]];E#23} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> A#17, T#7 |-> A#17[(app (letrec {X#21=T#20;E#23} in S#12) S#11)], T#18 |-> (app (letrec {X#21=T#20;E#23} in S#12) S#11), T#19 |-> (letrec {X#21=T#20;E#23} in S#12), E#10 |-> {X#21=T#20[(var X#2)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#2=S#4;X#8=A#17[(app (letrec {X#21=T#20[(var X#2)];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#17[(app (letrec {X#21=T#20[S#4];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#17[(app (letrec {X#21=T#20[(var X#2)];E#23} in S#12) S#11)];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=A#17[(letrec {X#21=T#20[(var X#2)];E#23} in (app S#12 S#11))];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#17[(app (letrec {E#10} in S#12) T#19[S#4])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#17[(letrec {E#10} in (app S#12 T#19[(var X#2)]))] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#18,A#16,T#7,A#17} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app (letrec {E#10} in S#12) T#19)]), (S#4,A#17[(app (letrec {E#10} in S#12) T#19)]), ((letrec {X#8=A#17[(app (letrec {E#10} in S#12) T#19[(dummy3 )])];E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#19[(var X#2)],(letrec {E#10} in [.])), ((var X#2),A#17[(app (letrec {E#10} in S#12) T#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[[.2]]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> A#17, T#7 |-> A#17[(app (letrec {E#10} in S#12) T#19)], T#18 |-> (app (letrec {E#10} in S#12) T#19), S#11 |-> T#19[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=A#17[(app (letrec {E#10} in S#12) T#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#17[(app (letrec {E#10} in S#12) T#19[S#4])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#17[(app (letrec {E#10} in S#12) T#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=A#17[(letrec {E#10} in (app S#12 T#19[(var X#2)]))];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19[S#4])] ;E#15 in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#17[(app A#18[(letrec {E#10} in (app S#12 S#11))] T#19[(var X#2)])] ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19)]), (S#4,A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19)]), ((letrec {X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19[(dummy3 )])];E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(var X#2)])]}, X#1 |-> X#8, E#3 |-> {E#15}, T#7 |-> A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19)], A#16 |-> A#17[(app A#18 T#19[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19[(var X#2)])];E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19[S#4])];E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#17[(app A#18[(app (letrec {E#10} in S#12) S#11)] T#19[(var X#2)])];E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=A#17[(app A#18[(letrec {E#10} in (app S#12 S#11))] T#19[(var X#2)])];E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=(app (letrec {E#10} in T#18[S#4]) S#11);E#15} in A#13[(var X#8)]) , (letrec X#2= S#4 ;X#8= (letrec {E#10} in (app T#18[(var X#2)] S#11)) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#17,T#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in T#18) S#11)), (S#4,(app (letrec {E#10} in T#18) S#11)), ((letrec {X#8=(app (letrec {E#10} in T#18[(dummy3 )]) S#11);E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in T#18[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> [.], T#7 |-> (app (letrec {E#10} in T#18) S#11), T#17 |-> (letrec {E#10} in T#18), S#12 |-> T#18[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=(app (letrec {E#10} in T#18[(var X#2)]) S#11);E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {E#10} in T#18[S#4]) S#11);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=(app (letrec {E#10} in T#18[(var X#2)]) S#11);E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=(letrec {E#10} in (app T#18[(var X#2)] S#11));E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= (app (letrec {X#19=T#18[S#4];E#21} in S#12) S#11) ;E#15 in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= (letrec {X#19=T#18[(var X#2)];E#21} in (app S#12 S#11)) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#17,T#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {X#19=T#18;E#21} in S#12) S#11)), (S#4,(app (letrec {X#19=T#18;E#21} in S#12) S#11)), ((letrec {X#8=(app (letrec {X#19=T#18[(dummy3 )];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#19=T#18[(var X#2)];E#21} in [.])), ((var X#2),(app (letrec {X#19=T#18[[.]];E#21} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> [.], T#7 |-> (app (letrec {X#19=T#18;E#21} in S#12) S#11), T#17 |-> (letrec {X#19=T#18;E#21} in S#12), E#10 |-> {X#19=T#18[(var X#2)];E#21}, E#20 |-> {E#21}} and instantiated rules: (letrec {X#2=S#4;X#8=(app (letrec {X#19=T#18[(var X#2)];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {X#19=T#18[S#4];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=(app (letrec {X#19=T#18[(var X#2)];E#21} in S#12) S#11);E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=(letrec {X#19=T#18[(var X#2)];E#21} in (app S#12 S#11));E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=(app (letrec {E#10} in S#12) T#17[S#4]);E#15} in A#13[(var X#8)]) , (letrec X#2= S#4 ;X#8= (letrec {E#10} in (app S#12 T#17[(var X#2)])) ;E#15 in A#13[(var X#8)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in S#12) T#17)), (S#4,(app (letrec {E#10} in S#12) T#17)), ((letrec {X#8=(app (letrec {E#10} in S#12) T#17[(dummy3 )]);E#15} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#17[(var X#2)],(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in S#12) T#17[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#15}, A#16 |-> [.], T#7 |-> (app (letrec {E#10} in S#12) T#17), S#11 |-> T#17[(var X#2)]} and instantiated rules: (letrec {X#2=S#4;X#8=(app (letrec {E#10} in S#12) T#17[(var X#2)]);E#15} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=(app (letrec {E#10} in S#12) T#17[S#4]);E#15} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=(app (letrec {E#10} in S#12) T#17[(var X#2)]);E#15} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=(letrec {E#10} in (app S#12 T#17[(var X#2)]));E#15} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[(app A#20[(var X#17)] T#21[S#4])] ;E#15 ;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#2= S#4 ;X#8= A#19[(app A#20[(var X#17)] T#21[(var X#2)])] ;E#15 ;EE#18[X#17,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(var X#17)] T#21)]), (S#4,A#19[(app A#20[(var X#17)] T#21)]), ((letrec {X#8=A#19[(app A#20[(var X#17)] T#21[(dummy3 )])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),A#19[(app A#20[(var X#17)] T#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];EE#18[X#17,[.2]]}, X#1 |-> X#8, E#3 |-> {E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]}, T#7 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(var X#2)])]} and instantiated rules: (letrec {X#2=S#4;X#8=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[(app A#20[(var X#17)] T#21[S#4])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#2=S#4;X#8=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#2=S#4;X#8=A#19[(app A#20[(var X#17)] T#21[(var X#2)])];E#15;EE#18[X#17,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[S#4])] ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(var X#2)])] ;X#2= S#4 ;E#15 ;EE#19[X#8,(var X#17)] ;EE#20[X#18,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#21[(app A#22[(var X#18)] T#23)]), (S#4,A#21[(app A#22[(var X#18)] T#23)]), ((letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(dummy3 )])];E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),A#21[(app A#22[(var X#18)] T#23[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#1 |-> X#17, E#3 |-> {E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]}, T#7 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(var X#2)])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[S#4])];E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(var X#2)])];X#2=S#4;E#15;EE#19[X#8,(var X#17)];EE#20[X#18,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#10} in T#22[S#4]) S#11)] ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {E#10} in (app T#22[(var X#2)] S#11))] ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#20,A#16,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app (letrec {E#10} in T#22) S#11)]), (S#4,A#19[(app (letrec {E#10} in T#22) S#11)]), ((letrec {X#17=A#19[(app (letrec {E#10} in T#22[(dummy3 )]) S#11)];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),A#19[(app (letrec {E#10} in T#22[[.]]) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, T#7 |-> A#19[(app (letrec {E#10} in T#22) S#11)], T#20 |-> (app (letrec {E#10} in T#22) S#11), T#21 |-> (letrec {E#10} in T#22), S#12 |-> T#22[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#10} in T#22[(var X#2)]) S#11)];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#19[(app (letrec {E#10} in T#22[S#4]) S#11)];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#10} in T#22[(var X#2)]) S#11)];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#10} in (app T#22[(var X#2)] S#11))];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {X#23=T#22[S#4];E#25} in S#12) S#11)] ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {X#23=T#22[(var X#2)];E#25} in (app S#12 S#11))] ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#21,T#20,A#16,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)]), (S#4,A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)]), ((letrec {X#17=A#19[(app (letrec {X#23=T#22[(dummy3 )];E#25} in S#12) S#11)];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#23=T#22[(var X#2)];E#25} in [.])), ((var X#2),A#19[(app (letrec {X#23=T#22[[.]];E#25} in S#12) S#11)]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, T#7 |-> A#19[(app (letrec {X#23=T#22;E#25} in S#12) S#11)], T#20 |-> (app (letrec {X#23=T#22;E#25} in S#12) S#11), T#21 |-> (letrec {X#23=T#22;E#25} in S#12), E#10 |-> {X#23=T#22[(var X#2)];E#25}, E#24 |-> {E#25}} and instantiated rules: (letrec {X#17=A#19[(app (letrec {X#23=T#22[(var X#2)];E#25} in S#12) S#11)];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#19[(app (letrec {X#23=T#22[S#4];E#25} in S#12) S#11)];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {X#23=T#22[(var X#2)];E#25} in S#12) S#11)];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {X#23=T#22[(var X#2)];E#25} in (app S#12 S#11))];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app (letrec {E#10} in S#12) T#21[S#4])] ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(letrec {E#10} in (app S#12 T#21[(var X#2)]))] ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#20,A#16,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app (letrec {E#10} in S#12) T#21)]), (S#4,A#19[(app (letrec {E#10} in S#12) T#21)]), ((letrec {X#17=A#19[(app (letrec {E#10} in S#12) T#21[(dummy3 )])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#21[(var X#2)],(letrec {E#10} in [.])), ((var X#2),A#19[(app (letrec {E#10} in S#12) T#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> A#19, T#7 |-> A#19[(app (letrec {E#10} in S#12) T#21)], T#20 |-> (app (letrec {E#10} in S#12) T#21), S#11 |-> T#21[(var X#2)]} and instantiated rules: (letrec {X#17=A#19[(app (letrec {E#10} in S#12) T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#19[(app (letrec {E#10} in S#12) T#21[S#4])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app (letrec {E#10} in S#12) T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(letrec {E#10} in (app S#12 T#21[(var X#2)]))];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[S#4])] ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] T#21[(var X#2)])] ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {A#16,T#7} Delta2 = {E#10} Delta3 = {((var X#2),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)]), (S#4,A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)]), ((letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(dummy3 )])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[[.]])]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(var X#2)])];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, T#7 |-> A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21)], A#16 |-> A#19[(app A#20 T#21[(var X#2)])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[S#4])];E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(app (letrec {E#10} in S#12) S#11)] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=A#19[(app A#20[(letrec {E#10} in (app S#12 S#11))] T#21[(var X#2)])];X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#10} in T#20[S#4]) S#11) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {E#10} in (app T#20[(var X#2)] S#11)) ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in T#20) S#11)), (S#4,(app (letrec {E#10} in T#20) S#11)), ((letrec {X#17=(app (letrec {E#10} in T#20[(dummy3 )]) S#11);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in T#20[[.]]) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], T#7 |-> (app (letrec {E#10} in T#20) S#11), T#19 |-> (letrec {E#10} in T#20), S#12 |-> T#20[(var X#2)]} and instantiated rules: (letrec {X#17=(app (letrec {E#10} in T#20[(var X#2)]) S#11);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=(app (letrec {E#10} in T#20[S#4]) S#11);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (letrec {E#10} in T#20[(var X#2)]) S#11);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=(letrec {E#10} in (app T#20[(var X#2)] S#11));X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {X#21=T#20[S#4];E#23} in S#12) S#11) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {X#21=T#20[(var X#2)];E#23} in (app S#12 S#11)) ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#19,T#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {X#21=T#20;E#23} in S#12) S#11)), (S#4,(app (letrec {X#21=T#20;E#23} in S#12) S#11)), ((letrec {X#17=(app (letrec {X#21=T#20[(dummy3 )];E#23} in S#12) S#11);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (S#11,(letrec {X#21=T#20[(var X#2)];E#23} in [.])), ((var X#2),(app (letrec {X#21=T#20[[.]];E#23} in S#12) S#11)), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], T#7 |-> (app (letrec {X#21=T#20;E#23} in S#12) S#11), T#19 |-> (letrec {X#21=T#20;E#23} in S#12), E#10 |-> {X#21=T#20[(var X#2)];E#23}, E#22 |-> {E#23}} and instantiated rules: (letrec {X#17=(app (letrec {X#21=T#20[(var X#2)];E#23} in S#12) S#11);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=(app (letrec {X#21=T#20[S#4];E#23} in S#12) S#11);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (letrec {X#21=T#20[(var X#2)];E#23} in S#12) S#11);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=(letrec {X#21=T#20[(var X#2)];E#23} in (app S#12 S#11));X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#17= (app (letrec {E#10} in S#12) T#19[S#4]) ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) , (letrec X#17= (letrec {E#10} in (app S#12 T#19[(var X#2)])) ;X#2= S#4 ;E#15 ;EE#18[X#8,(var X#17)] in A#13[(var X#8)] ) ) where Delta1 = {T#7} Delta2 = {E#10} Delta3 = {((var X#2),(app (letrec {E#10} in S#12) T#19)), (S#4,(app (letrec {E#10} in S#12) T#19)), ((letrec {X#17=(app (letrec {E#10} in S#12) T#19[(dummy3 )]);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])), (T#19[(var X#2)],(letrec {E#10} in [.])), ((var X#2),(app (letrec {E#10} in S#12) T#19[[.]])), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], E#9 |-> {X#2=S#4;E#15}, EE#14[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#1 |-> X#17, E#3 |-> {E#15;EE#18[X#8,(var X#17)]}, A#16 |-> [.], T#7 |-> (app (letrec {E#10} in S#12) T#19), S#11 |-> T#19[(var X#2)]} and instantiated rules: (letrec {X#17=(app (letrec {E#10} in S#12) T#19[(var X#2)]);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#17=(app (letrec {E#10} in S#12) T#19[S#4]);E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#17=(app (letrec {E#10} in S#12) T#19[(var X#2)]);X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#17=(letrec {E#10} in (app S#12 T#19[(var X#2)]));X#2=S#4;E#15;EE#18[X#8,(var X#17)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[A#15[(var X#17)]] ;E#9 ;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= A#21[(var X#16)] ;E#9 ;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), (A#15[(var X#17)],A#21[[.]]), ((letrec {X#8=A#21[(dummy3 )];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=A#21[(var X#16)];EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#3 |-> {E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]}, A#20 |-> A#21, T#7 |-> A#21[[.]], T#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#21[A#15[(var X#17)]];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#9;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#21[A#15[(var X#17)]] ;E#9 ;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= A#21[(var X#16)] ;E#9 ;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), (A#15[(var X#17)],A#21), ((letrec {X#8=A#21[(dummy3 )];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=A#21[(var X#16)];EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=A#21[[.2]]}, X#1 |-> X#8, E#3 |-> {E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]}, A#20 |-> A#21[[.]], T#7 |-> A#21, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#21[A#15[(var X#17)]];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#8=A#21[(var X#16)];E#9;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#15[(var X#17)] ;E#9 ;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#8= (var X#16) ;E#9 ;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(var X#17)],[.]), ((letrec {X#8=(dummy3 );E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];[.1]=(var X#16);EE#19[X#17,[.2]]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]}, T#7 |-> [.], A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#8=(var X#16);E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#15[(var X#17)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#8=(var X#16);E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#8=(var X#16);E#9;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#15[(var X#17)]] ;E#9 ;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= A#23[(var X#16)] ;E#9 ;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23[[.]]), (A#15[(var X#17)],A#23[[.]]), ((letrec {X#21=A#23[(dummy3 )];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23, T#7 |-> A#23[[.]], T#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#21=A#23[A#15[(var X#17)]];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#9;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#21= A#23[A#15[(var X#17)]] ;E#9 ;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= A#23[(var X#16)] ;E#9 ;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {A#20,T#7,A#23} Delta2 = {E#10} Delta3 = {((var X#16),A#23), (A#15[(var X#17)],A#23), ((letrec {X#21=A#23[(dummy3 )];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#23[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=A#23[[.2]];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, A#20 |-> A#23[[.]], T#7 |-> A#23, A#24 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#21=A#23[A#15[(var X#17)]];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#21=A#23[(var X#16)];E#9;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#21= A#15[(var X#17)] ;E#9 ;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(var X#17)] ;X#21= (var X#16) ;E#9 ;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))] ;EE#22[X#8,(var X#21)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(var X#17)],[.]), ((letrec {X#21=(dummy3 );E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(var X#17)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[(var X#17)];X#21=(var X#16);EE#19[X#17,[.2]];EE#22[[.1],(var X#21)]}, X#2 |-> X#16, S#4 |-> A#15[(var X#17)], EE#18[.1,.2] |-> {X#21=[.2];EE#22[[.1],(var X#21)]}, X#1 |-> X#21, E#3 |-> {E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]}, T#7 |-> [.], A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#21=A#15[(var X#17)];E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#9;EE#19[X#17,(app (letrec {E#10} in S#12) S#11)];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(var X#17)];X#21=(var X#16);E#9;EE#19[X#17,(letrec {E#10} in (app S#12 S#11))];EE#22[X#8,(var X#21)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[A#15[(app (letrec {E#10} in S#12) S#11)]] ;E#9 in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {E#10} in (app S#12 S#11))] ;X#8= A#19[(var X#16)] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#16),A#19[[.]]), (A#15[(app (letrec {E#10} in S#12) S#11)],A#19[[.]]), ((letrec {X#8=A#19[(dummy3 )];E#9} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (letrec {E#10} in S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#19[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, S#4 |-> A#15[(app (letrec {E#10} in S#12) S#11)], EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#8, E#3 |-> {E#9}, A#18 |-> A#19, T#7 |-> A#19[[.]], T#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#8=A#19[(var X#16)];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[A#15[(app (letrec {E#10} in S#12) S#11)]];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#8=A#19[(var X#16)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#10} in (app S#12 S#11))];X#8=A#19[(var X#16)];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#8= A#19[A#15[(app (letrec {E#10} in S#12) S#11)]] ;E#9 in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {E#10} in (app S#12 S#11))] ;X#8= A#19[(var X#16)] ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#19} Delta2 = {E#10} Delta3 = {((var X#16),A#19), (A#15[(app (letrec {E#10} in S#12) S#11)],A#19), ((letrec {X#8=A#19[(dummy3 )];E#9} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (letrec {E#10} in S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#19[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=A#19[(var X#16)]}, X#2 |-> X#16, S#4 |-> A#15[(app (letrec {E#10} in S#12) S#11)], EE#17[.1,.2] |-> {[.1]=A#19[[.2]]}, X#1 |-> X#8, E#3 |-> {E#9}, A#18 |-> A#19[[.]], T#7 |-> A#19, A#20 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#8=A#19[(var X#16)];E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#19[A#15[(app (letrec {E#10} in S#12) S#11)]];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#8=A#19[(var X#16)];E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#10} in (app S#12 S#11))];X#8=A#19[(var X#16)];E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec {X#8=A#15[(app (letrec {E#10} in S#12) S#11)];E#9} in A#13[(var X#8)]) , (letrec X#16= A#15[(letrec {E#10} in (app S#12 S#11))] ;X#8= (var X#16) ;E#9 in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(app (letrec {E#10} in S#12) S#11)],[.]), ((letrec {X#8=(dummy3 );E#9} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (letrec {E#10} in S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];[.1]=(var X#16)}, X#2 |-> X#16, S#4 |-> A#15[(app (letrec {E#10} in S#12) S#11)], EE#17[.1,.2] |-> {[.1]=[.2]}, X#1 |-> X#8, E#3 |-> {E#9}, T#7 |-> [.], A#18 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#8=(var X#16);E#9} in A#13[(var X#8)]) <-ucp2- (letrec {X#8=A#15[(app (letrec {E#10} in S#12) S#11)];E#9} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#8=(var X#16);E#9} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#10} in (app S#12 S#11))];X#8=(var X#16);E#9} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#15[(app (letrec {E#10} in S#12) S#11)]] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {E#10} in (app S#12 S#11))] ;X#19= A#21[(var X#16)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21[[.]]), (A#15[(app (letrec {E#10} in S#12) S#11)],A#21[[.]]), ((letrec {X#19=A#21[(dummy3 )];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (letrec {E#10} in S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(app (letrec {E#10} in S#12) S#11)], EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21, T#7 |-> A#21[[.]], T#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#19=A#21[(var X#16)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[A#15[(app (letrec {E#10} in S#12) S#11)]];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#19=A#21[(var X#16)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#10} in (app S#12 S#11))];X#19=A#21[(var X#16)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#15[(app (letrec {E#10} in S#12) S#11)]] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {E#10} in (app S#12 S#11))] ;X#19= A#21[(var X#16)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {A#18,T#7,A#21} Delta2 = {E#10} Delta3 = {((var X#16),A#21), (A#15[(app (letrec {E#10} in S#12) S#11)],A#21), ((letrec {X#19=A#21[(dummy3 )];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (letrec {E#10} in S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),A#21[[.]]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=A#21[(var X#16)];EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(app (letrec {E#10} in S#12) S#11)], EE#17[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {E#9;EE#20[X#8,(var X#19)]}, A#18 |-> A#21[[.]], T#7 |-> A#21, A#22 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#19=A#21[(var X#16)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#21[A#15[(app (letrec {E#10} in S#12) S#11)]];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#19=A#21[(var X#16)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#10} in (app S#12 S#11))];X#19=A#21[(var X#16)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( (letrec X#19= A#15[(app (letrec {E#10} in S#12) S#11)] ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) , (letrec X#16= A#15[(letrec {E#10} in (app S#12 S#11))] ;X#19= (var X#16) ;E#9 ;EE#20[X#8,(var X#19)] in A#13[(var X#8)] ) ) where Delta1 = {} Delta2 = {E#10} Delta3 = {((var X#16),[.]), (A#15[(app (letrec {E#10} in S#12) S#11)],[.]), ((letrec {X#19=(dummy3 );E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]),(letrec {X#16=(dummy3 )} in [.])), (A#15[(app (letrec {E#10} in S#12) S#11)],(letrec {X#16=(dummy3 )} in [.])), (S#11,(letrec {E#10} in [.])), ((var X#16),[.]), ((var X#8),A#13[[.]]), ((var X#8),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp2-> with input rules: T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] <-ucp2- T#6[(letrec {X#1=T#7[S#4];E#3} in S#5)] and constraints: ((var X#2),T#7), (S#4,T#7), ((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])), (S#4,(letrec {X#2=(dummy3 )} in [.])) ................................................................................ (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {E#9;EE#14[X#8,(letrec {E#10} in (app S#12 S#11))]} in A#13[(var X#8)]) and constraints: E#10/= {}, (S#11,(letrec {E#10} in [.])) and letrec unification problem: Gamma ={ T#6[(letrec {X#1=T#7[(var X#2)];X#2=S#4;E#3} in S#5)] =?= (letrec {E#9;EE#14[X#8,(app (letrec {E#10} in S#12) S#11)]} in A#13[(var X#8)])} Delta1= {} Delta2= {E#10} Delta3= {((var X#2),T#7),(S#4,T#7),((letrec {X#1=T#7[(dummy3 )];E#3} in S#5),(letrec {X#2=(dummy3 )} in [.])),(S#4,(letrec {X#2=(dummy3 )} in [.])),(S#11,(letrec {E#10} in [.])),((var X#2),T#7[[.]]),((var X#8),A#13[[.]]),((var X#8),A#13[[.]])} and found solution: Sol = {T#6 |-> [.], S#5 |-> A#13[(var X#8)], EE#14[.1,.2] |-> {X#16=A#15[[.2]];X#19=(var X#16);EE#20[[.1],(var X#19)]}, X#2 |-> X#16, S#4 |-> A#15[(app (letrec {E#10} in S#12) S#11)], EE#17[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#1 |-> X#19, E#3 |-> {E#9;EE#20[X#8,(var X#19)]}, T#7 |-> [.], A#18 |-> [.], X#16 |-> X#16} and instantiated rules: (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#19=(var X#16);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) <-ucp2- (letrec {X#19=A#15[(app (letrec {E#10} in S#12) S#11)];E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ................................................................................ (letrec {X#16=A#15[(app (letrec {E#10} in S#12) S#11)];X#19=(var X#16);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) -SR,lapp3-> (letrec {X#16=A#15[(letrec {E#10} in (app S#12 S#11))];X#19=(var X#16);E#9;EE#20[X#8,(var X#19)]} in A#13[(var X#8)]) ================================================================================ Critical Pair: ( A#9[(app (\ X#5.S#7) T#11[T#4[S#2]])] , A#9[(letrec {X#5=T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#7)] ) where Delta1 = {T#10,A#8,T#3,A#9} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#11[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#5.[.])), (T#11[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#5=[.]} in S#7)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7)),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> A#9, T#3 |-> A#9[(app (\ X#5.S#7) T#11)], T#10 |-> (app (\ X#5.S#7) T#11), S#6 |-> T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: A#9[(app (\ X#5.S#7) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] <-ucp3- A#9[(app (\ X#5.S#7) T#11[T#4[S#2]])] ................................................................................ A#9[(app (\ X#5.S#7) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] -SR,lbeta1-> A#9[(letrec {X#5=T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#7)] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[T#4[S#2]])] , A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) where Delta1 = {A#8,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] <-ucp3- A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[T#4[S#2]])] ................................................................................ A#9[(app A#10[(app (\ X#5.S#7) S#6)] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] -SR,lbeta1-> A#9[(app A#10[(letrec {X#5=S#6} in S#7)] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] ================================================================================ Critical Pair: ( (app (\ X#5.S#7) T#9[T#4[S#2]]) , (letrec {X#5=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#7) ) where Delta1 = {T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#9[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#5.[.])), (T#9[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#5=[.]} in S#7)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (\ X#5.S#7) S#6)] -SR,lbeta1-> A#8[(letrec {X#5=S#6} in S#7)] and constraints: (S#6,(\ X#5.[.])), (S#6,(letrec {X#5=[.]} in S#7)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (\ X#5.S#7) S#6)]} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(\ X#5.[.])),(S#6,(letrec {X#5=[.]} in S#7)),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> [.], T#3 |-> (app (\ X#5.S#7) T#9), S#6 |-> T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (app (\ X#5.S#7) T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]) <-ucp3- (app (\ X#5.S#7) T#9[T#4[S#2]]) ................................................................................ (app (\ X#5.S#7) T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]) -SR,lbeta1-> (letrec {X#5=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#7) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[T#4[S#2]])]) , (letrec E#6 in A#11[(letrec {X#5=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#8)] ) ) where Delta1 = {T#12,A#9,T#10,T#3,A#11} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#13[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#5.[.])), (T#13[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#5=[.]} in S#8)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (\ X#5.S#8) T#13)], T#12 |-> (app (\ X#5.S#8) T#13), S#7 |-> T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[T#4[S#2]])]) ................................................................................ (letrec {E#6} in A#11[(app (\ X#5.S#8) T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,lbeta2-> (letrec {E#6} in A#11[(letrec {X#5=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#8)]) ================================================================================ Critical Pair: ( (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[T#4[S#2]])]) , (letrec E#6 in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#9,T#10,T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[T#4[S#2]])]) ................................................................................ (letrec {E#6} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,lbeta2-> (letrec {E#6} in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec {E#6} in (app (\ X#5.S#8) T#11[T#4[S#2]])) , (letrec E#6 in (letrec {X#5=T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#8) ) ) where Delta1 = {T#10,T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#11[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#5.[.])), (T#11[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#5=[.]} in S#8)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#6} in (app (\ X#5.S#8) T#11)), A#9 |-> [.], T#10 |-> (app (\ X#5.S#8) T#11), S#7 |-> T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])) <-ucp3- (letrec {E#6} in (app (\ X#5.S#8) T#11[T#4[S#2]])) ................................................................................ (letrec {E#6} in (app (\ X#5.S#8) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])) -SR,lbeta2-> (letrec {E#6} in (letrec {X#5=T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#8)) ================================================================================ Critical Pair: ( (letrec {X#11=T#10[T#4[S#2]];E#13} in A#9[(app (\ X#5.S#8) S#7)]) , (letrec X#11= T#10[(letrec {X#1=S#2} in T#4[(var X#1)])] ;E#13 in A#9[(letrec {X#5=S#7} in S#8)] ) ) where Delta1 = {T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#11=T#10;E#13} in A#9[(app (\ X#5.S#8) S#7)]), E#6 |-> {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in A#9[(app (\ X#5.S#8) S#7)]) <-ucp3- (letrec {X#11=T#10[T#4[S#2]];E#13} in A#9[(app (\ X#5.S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in A#9[(letrec {X#5=S#7} in S#8)]) ================================================================================ Critical Pair: ( A#11[(app (\ X#5.S#8) T#13[S#2])] , (letrec {X#1=S#2} in A#11[(letrec {X#5=T#13[(var X#1)]} in S#8)]) ) where Delta1 = {T#12,T#4,A#9,A#11} Delta2 = {E#6} Delta3 = {((var X#1),A#11[(app (\ X#5.S#8) T#13)]), (S#2,A#11[(app (\ X#5.S#8) T#13)]), (A#11[(app (\ X#5.S#8) T#13[(dummy3 )])],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#13[(var X#1)],(\ X#5.[.])), (T#13[(var X#1)],(letrec {X#5=[.]} in S#8)), ((var X#1),A#11[(app (\ X#5.S#8) T#13[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#6 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> A#11, T#4 |-> A#11[(app (\ X#5.S#8) T#13)], T#12 |-> (app (\ X#5.S#8) T#13), S#7 |-> T#13[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in A#11[(app (\ X#5.S#8) T#13[(var X#1)])]) <-ucp3- A#11[(app (\ X#5.S#8) T#13[S#2])] ................................................................................ (letrec {X#1=S#2} in A#11[(app (\ X#5.S#8) T#13[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=S#2} in A#11[(letrec {X#5=T#13[(var X#1)]} in S#8)]) ================================================================================ Critical Pair: ( A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[S#2])] , (letrec X#1= S#2 in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(var X#1)])] ) ) where Delta1 = {T#4,A#9} Delta2 = {E#6} Delta3 = {((var X#1),A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), (S#2,A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)]), (A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(dummy3 )])],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)), ((var X#1),A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[[.]])])} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#6 |-> {X#1=S#2}, E#10 |-> {}, T#4 |-> A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(var X#1)])]} and instantiated rules: (letrec {X#1=S#2} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(var X#1)])]) <-ucp3- A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[S#2])] ................................................................................ (letrec {X#1=S#2} in A#11[(app A#12[(app (\ X#5.S#8) S#7)] T#13[(var X#1)])]) -SR,lbeta2-> (letrec {X#1=S#2} in A#11[(app A#12[(letrec {X#5=S#7} in S#8)] T#13[(var X#1)])]) ================================================================================ Critical Pair: ( (app (\ X#5.S#8) T#11[S#2]) , (letrec {X#1=S#2} in (letrec {X#5=T#11[(var X#1)]} in S#8)) ) where Delta1 = {T#4} Delta2 = {E#6} Delta3 = {((var X#1),(app (\ X#5.S#8) T#11)), (S#2,(app (\ X#5.S#8) T#11)), ((app (\ X#5.S#8) T#11[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#11[(var X#1)],(\ X#5.[.])), (T#11[(var X#1)],(letrec {X#5=[.]} in S#8)), ((var X#1),(app (\ X#5.S#8) T#11[[.]]))} Delta4= {} from overlapping <-SR,lbeta2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)]) -SR,lbeta2-> (letrec {E#6} in A#9[(letrec {X#5=S#7} in S#8)]) and constraints: E#6/= {}, (S#7,(\ X#5.[.])), (S#7,(letrec {X#5=[.]} in S#8)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6} in A#9[(app (\ X#5.S#8) S#7)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(\ X#5.[.])),(S#7,(letrec {X#5=[.]} in S#8)),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#6 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> [.], T#4 |-> (app (\ X#5.S#8) T#11), S#7 |-> T#11[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in (app (\ X#5.S#8) T#11[(var X#1)])) <-ucp3- (app (\ X#5.S#8) T#11[S#2]) ................................................................................ (letrec {X#1=S#2} in (app (\ X#5.S#8) T#11[(var X#1)])) -SR,lbeta2-> (letrec {X#1=S#2} in (letrec {X#5=T#11[(var X#1)]} in S#8)) ================================================================================ Critical Pair: ( (letrec E#7 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[T#4[S#2]])] ) , (letrec E#7 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#10,T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[T#4[S#2]])]) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[T#4[S#2]] ;E#15 ;EE#11[X#5,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] ;E#15 ;EE#11[X#5,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), E#7 |-> {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#13=T#12[T#4[S#2]];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[T#4[S#2]])];E#7} in A#10[(var X#5)]) , (letrec X#5= A#16[(letrec {X#6=T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9)] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#3,A#16} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#18[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#6.[.])), (T#18[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app (\ X#6.S#9) T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> A#16, T#12 |-> A#16[(app (\ X#6.S#9) T#18)], T#17 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[T#4[S#2]])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(letrec {X#6=T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9)];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[T#4[S#2]])] ;E#7 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)];E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]}, X#13 |-> X#5, E#14 |-> {E#7}, T#12 |-> A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[T#4[S#2]])];E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (\ X#6.S#9) S#8)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#16[(app A#17[(letrec {X#6=S#8} in S#9)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(app (\ X#6.S#9) T#16[T#4[S#2]]);E#7} in A#10[(var X#5)]) , (letrec X#5= (letrec {X#6=T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9) ;E#7 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#16[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#6.[.])), (T#16[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(app (\ X#6.S#9) T#16);E#7} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#7}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#16), S#8 |-> T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#7} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=(app (\ X#6.S#9) T#16[T#4[S#2]]);E#7} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (\ X#6.S#9) T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#7} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=(letrec {X#6=T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9);E#7} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[T#4[S#2]])] ;E#7 ;EE#17[X#16,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#7 ;EE#17[X#16,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[T#4[S#2]])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#16,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#16,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[T#4[S#2]])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (\ X#6.S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#7 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {X#6=S#8} in S#9)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[T#4[S#2]])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (\ X#6.S#9) T#20[T#4[S#2]])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#6=T#20[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9)] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#3,A#18} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#20[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#6.[.])), (T#20[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app (\ X#6.S#9) T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (\ X#6.S#9) T#20)], T#19 |-> (app (\ X#6.S#9) T#20), S#8 |-> T#20[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[T#4[S#2]])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (\ X#6.S#9) T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(letrec {X#6=T#20[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[T#4[S#2]])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[T#4[S#2]])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (\ X#6.S#9) S#8)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=A#18[(app A#19[(letrec {X#6=S#8} in S#9)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (\ X#6.S#9) T#18[T#4[S#2]]) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#6=T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9) ;E#7 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#18[(letrec {X#1=S#2} in T#4[(var X#1)])],(\ X#6.[.])), (T#18[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {X#6=[.]} in S#9)), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=(app (\ X#6.S#9) T#18);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#7;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (\ X#6.S#9) T#18), S#8 |-> T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=(app (\ X#6.S#9) T#18[T#4[S#2]]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (\ X#6.S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {X#16=(letrec {X#6=T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} in S#9);E#7;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( A#13[A#12[(app (\ X#6.S#9) S#8)]] , (letrec {X#5=A#12[(letrec {X#6=S#8} in S#9)]} in A#13[(var X#5)]) ) where Delta1 = {T#4,A#10,A#13} Delta2 = {} Delta3 = {((var X#5),A#13[[.]]), (A#12[(app (\ X#6.S#9) S#8)],A#13[[.]]), (A#13[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), (A#12[(app (\ X#6.S#9) S#8)],(letrec {X#5=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> [.], EE#11[.1,.2] |-> {[.1]=A#12[[.2]]}, X#1 |-> X#5, S#2 |-> A#12[(app (\ X#6.S#9) S#8)], E#7 |-> {}, A#10 |-> A#13, T#4 |-> A#13[[.]], T#14 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=A#12[(app (\ X#6.S#9) S#8)]} in A#13[(var X#5)]) <-ucp3- A#13[A#12[(app (\ X#6.S#9) S#8)]] ................................................................................ (letrec {X#5=A#12[(app (\ X#6.S#9) S#8)]} in A#13[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#12[(letrec {X#6=S#8} in S#9)]} in A#13[(var X#5)]) ================================================================================ Critical Pair: ( A#13[A#12[(app (\ X#6.S#9) S#8)]] , (letrec {X#5=A#12[(letrec {X#6=S#8} in S#9)]} in A#13[(var X#5)]) ) where Delta1 = {T#4,A#10,A#13} Delta2 = {} Delta3 = {((var X#5),A#13), (A#12[(app (\ X#6.S#9) S#8)],A#13), (A#13[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), (A#12[(app (\ X#6.S#9) S#8)],(letrec {X#5=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> [.], EE#11[.1,.2] |-> {[.1]=A#12[[.2]]}, X#1 |-> X#5, S#2 |-> A#12[(app (\ X#6.S#9) S#8)], E#7 |-> {}, A#10 |-> A#13[[.]], T#4 |-> A#13, A#14 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=A#12[(app (\ X#6.S#9) S#8)]} in A#13[(var X#5)]) <-ucp3- A#13[A#12[(app (\ X#6.S#9) S#8)]] ................................................................................ (letrec {X#5=A#12[(app (\ X#6.S#9) S#8)]} in A#13[(var X#5)]) -SR,lbeta3-> (letrec {X#5=A#12[(letrec {X#6=S#8} in S#9)]} in A#13[(var X#5)]) ================================================================================ Critical Pair: ( A#12[(app (\ X#6.S#9) S#8)] , (letrec {X#5=A#12[(letrec {X#6=S#8} in S#9)]} in (var X#5)) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#5),[.]), (A#12[(app (\ X#6.S#9) S#8)],[.]), ((dummy3 ),(letrec {X#5=(dummy3 )} in [.])), (A#12[(app (\ X#6.S#9) S#8)],(letrec {X#5=(dummy3 )} in [.])), (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)), ((var X#5),[.]), ((var X#5),[.]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,lbeta3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)]) -SR,lbeta3-> (letrec {E#7;EE#11[X#5,(letrec {X#6=S#8} in S#9)]} in A#10[(var X#5)]) and constraints: (S#8,(\ X#6.[.])), (S#8,(letrec {X#6=[.]} in S#9)) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#7;EE#11[X#5,(app (\ X#6.S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(\ X#6.[.])),(S#8,(letrec {X#6=[.]} in S#9)),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> [.], EE#11[.1,.2] |-> {[.1]=A#12[[.2]]}, X#1 |-> X#5, S#2 |-> A#12[(app (\ X#6.S#9) S#8)], E#7 |-> {}, A#10 |-> [.], T#4 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=A#12[(app (\ X#6.S#9) S#8)]} in (var X#5)) <-ucp3- A#12[(app (\ X#6.S#9) S#8)] ................................................................................ (letrec {X#5=A#12[(app (\ X#6.S#9) S#8)]} in (var X#5)) -SR,lbeta3-> (letrec {X#5=A#12[(letrec {X#6=S#8} in S#9)]} in (var X#5)) ================================================================================ Critical Pair: ( (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[T#4[S#2]])]) , (letrec X#5= (\ X#6.S#8) ;E#7 in A#11[(app A#12[(\ X#6.S#8)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#9,T#10,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[T#4[S#2]])]) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#11[(app A#12[(\ X#6.S#8)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec {X#11=T#10[T#4[S#2]];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) , (letrec X#11= T#10[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= (\ X#6.S#8) ;E#13 in A#9[(\ X#6.S#8)] ) ) where Delta1 = {T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#11=T#10;X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13}, E#12 |-> {X#5=(\ X#6.S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) <-ucp3- (letrec {X#11=T#10[T#4[S#2]];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#8);E#13} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#8);E#13} in A#9[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( A#10[(\ X#6.S#8)] , (letrec {X#5=(\ X#6.S#8)} in A#10[(\ X#6.S#8)]) ) where Delta1 = {T#4,A#9,A#10} Delta2 = {} Delta3 = {((var X#5),A#10[[.]]), ((\ X#6.S#8),A#10[[.]]), (A#10[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), ((\ X#6.S#8),(letrec {X#5=(dummy3 )} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> [.], X#1 |-> X#5, S#2 |-> (\ X#6.S#8), E#7 |-> {}, A#9 |-> A#10, T#4 |-> A#10[[.]], T#11 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=(\ X#6.S#8)} in A#10[(var X#5)]) <-ucp3- A#10[(\ X#6.S#8)] ................................................................................ (letrec {X#5=(\ X#6.S#8)} in A#10[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8)} in A#10[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( A#10[(\ X#6.S#8)] , (letrec {X#5=(\ X#6.S#8)} in A#10[(\ X#6.S#8)]) ) where Delta1 = {T#4,A#9,A#10} Delta2 = {} Delta3 = {((var X#5),A#10), ((\ X#6.S#8),A#10), (A#10[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), ((\ X#6.S#8),(letrec {X#5=(dummy3 )} in [.])), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> [.], X#1 |-> X#5, S#2 |-> (\ X#6.S#8), E#7 |-> {}, A#9 |-> A#10[[.]], T#4 |-> A#10, A#11 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=(\ X#6.S#8)} in A#10[(var X#5)]) <-ucp3- A#10[(\ X#6.S#8)] ................................................................................ (letrec {X#5=(\ X#6.S#8)} in A#10[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8)} in A#10[(\ X#6.S#8)]) ================================================================================ Critical Pair: ( (\ X#6.S#8) , (letrec {X#5=(\ X#6.S#8)} in (\ X#6.S#8)) ) where Delta1 = {} Delta2 = {} Delta3 = {((var X#5),[.]), ((\ X#6.S#8),[.]), ((dummy3 ),(letrec {X#5=(dummy3 )} in [.])), ((\ X#6.S#8),(letrec {X#5=(dummy3 )} in [.])), ((var X#5),[.]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)]) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(\ X#6.S#8)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> [.], X#1 |-> X#5, S#2 |-> (\ X#6.S#8), E#7 |-> {}, A#9 |-> [.], T#4 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=(\ X#6.S#8)} in (var X#5)) <-ucp3- (\ X#6.S#8) ................................................................................ (letrec {X#5=(\ X#6.S#8)} in (var X#5)) -SR,cp-in1-> (letrec {X#5=(\ X#6.S#8)} in (\ X#6.S#8)) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(var X#7)] T#15[T#4[S#2]])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;VV#11|X#7,(var X#5)| in A#13[(app A#14[(\ X#6.S#9)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#10,T#12,T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15)]), T#12 |-> A#13[(app A#14[(var X#7)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[T#4[S#2]])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(var X#7)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#13[(app A#14[(\ X#6.S#9)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[T#4[S#2]] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(var X#7)] ) , (letrec X#13= T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= (\ X#6.S#9) ;E#15 ;VV#11|X#7,(var X#5)| in A#10[(\ X#6.S#9)] ) ) where Delta1 = {T#3} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#10[[.]]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,cp-in2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) and constraints: and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;VV#11|X#7,(var X#5)|} in A#10[(var X#7)])} Delta1= {} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#10[[.]]),((var X#5),[.])} and found solution: Sol = {T#3 |-> (letrec {X#13=T#12;X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]), E#8 |-> {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15}, E#14 |-> {X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) <-ucp3- (letrec {X#13=T#12[T#4[S#2]];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(var X#7)]) -SR,cp-in2-> (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#9);E#15;VV#11|X#7,(var X#5)|} in A#10[(\ X#6.S#9)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(var X#5)]] in A#14[(app A#15[(var X#7)] T#16[T#4[S#2]])] ) , (letrec X#5= (\ X#6.S#9) ;E#8 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#11,T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#7),A#14[(app A#15[[.]] T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16)]), T#13 |-> A#14[(app A#15[(var X#7)] T#16)], A#11 |-> A#14[(app A#15 T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[T#4[S#2]])]) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#14[(app A#15[(var X#7)] T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#14= T#13[T#4[S#2]] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#14= T#13[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= (\ X#6.S#9) ;E#16 ;EE#12[X#7,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#14=T#13;X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]), E#8 |-> {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#16}, E#15 |-> {X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]}} and instantiated rules: (letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) <-ucp3- (letrec {X#14=T#13[T#4[S#2]];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#9);E#16;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(var X#5)] T#21[T#4[S#2]])]] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#18,A#16,T#13,T#3,A#10,A#17} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#19[(app A#20[[.]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21)]];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> A#17, T#13 |-> A#17[A#19[(app A#20[(var X#5)] T#21)]], T#18 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]];E#8} in A#11[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[T#4[S#2]])]];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(var X#5)]] T#19[T#4[S#2]])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#17[(app A#18[[.2]] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, T#13 |-> A#17[(app A#18[A#10[(var X#5)]] T#19)], A#16 |-> A#17[(app A#18 T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#11[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[T#4[S#2]])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(var X#5)]] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[A#10[(\ X#6.S#9)]] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(var X#5)] T#19[T#4[S#2]])] ;E#8 in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#17[(app A#18[(\ X#6.S#9)] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#8 in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#17[(app A#18[[.]] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19)];E#8} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=[.2]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8}, A#16 |-> [.], T#13 |-> A#17[(app A#18[(var X#5)] T#19)], A#10 |-> A#17[(app A#18 T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#11[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[T#4[S#2]])];E#8} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(var X#5)] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#17[(app A#18[(\ X#6.S#9)] T#19[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[T#4[S#2]])] ;E#8 ;EE#18[X#17,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#5= (\ X#6.S#9) ;X#7= A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#8 ;EE#18[X#17,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21)];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {[.1]=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#18[X#17,[.2]]}, X#14 |-> X#7, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#17,A#10[(var X#5)]]}, T#13 |-> A#19[(app A#20[(var X#17)] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[T#4[S#2]])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#18[X#17,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);X#7=A#19[(app A#20[(var X#17)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#18[X#17,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#21[(app A#22[(var X#18)] T#23[T#4[S#2]])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(var X#5)]] in A#11[(var X#7)] ) , (letrec X#17= A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#19[X#7,(var X#17)] ;EE#20[X#18,A#10[(\ X#6.S#9)]] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23)];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#19[[.1],(var X#17)];EE#20[X#18,[.2]]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]}, T#13 |-> A#21[(app A#22[(var X#18)] T#23)], A#16 |-> A#21[(app A#22 T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) <-ucp3- (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[T#4[S#2]])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#21[(app A#22[(var X#18)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#19[X#7,(var X#17)];EE#20[X#18,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[A#21[(app A#22[(var X#5)] T#23[T#4[S#2]])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#20,A#16,T#13,T#3,A#10,A#19} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#21[(app A#22[[.]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23)]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[[.2]];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> A#19, T#13 |-> A#19[A#21[(app A#22[(var X#5)] T#23)]], T#20 |-> A#21[(app A#22[(var X#5)] T#23)], A#10 |-> A#21[(app A#22 T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-ucp3- (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[T#4[S#2]])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[A#21[(app A#22[(var X#5)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[A#21[(app A#22[(\ X#6.S#9)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[A#10[(var X#5)]] T#21[T#4[S#2]])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {A#16,T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=A#19[(app A#20[[.2]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, T#13 |-> A#19[(app A#20[A#10[(var X#5)]] T#21)], A#16 |-> A#19[(app A#20 T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-ucp3- (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[T#4[S#2]])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[A#10[(var X#5)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[A#10[(\ X#6.S#9)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#17= A#19[(app A#20[(var X#5)] T#21[T#4[S#2]])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) , (letrec X#17= A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= (\ X#6.S#9) ;E#8 ;EE#18[X#7,(var X#17)] in A#11[(var X#7)] ) ) where Delta1 = {T#13,T#3,A#10} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#19[(app A#20[[.]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#7),A#11[[.]]), ((var X#7),A#11[[.]])} Delta4= {} from overlapping <-SR,cp-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(\ X#6.S#9)]]} in A#11[(var X#7)]) and constraints: A#10/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#9);E#8;EE#12[X#7,A#10[(var X#5)]]} in A#11[(var X#7)])} Delta1= {A#10} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#7),A#11[[.]]),((var X#7),A#11[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#17=A#19[(app A#20[(var X#5)] T#21)];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]), EE#12[.1,.2] |-> {X#17=[.2];EE#18[[.1],(var X#17)]}, X#14 |-> X#17, E#15 |-> {X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]}, A#16 |-> [.], T#13 |-> A#19[(app A#20[(var X#5)] T#21)], A#10 |-> A#19[(app A#20 T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) <-ucp3- (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[T#4[S#2]])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ................................................................................ (letrec {X#17=A#19[(app A#20[(var X#5)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) -SR,cp-e1-> (letrec {X#17=A#19[(app A#20[(\ X#6.S#9)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#9);E#8;EE#18[X#7,(var X#17)]} in A#11[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[T#4[S#2]])] ) , (letrec X#5= (\ X#6.S#10) ;E#9 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#16[(app A#17[(var X#7)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#12,T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#16[(app A#17[[.]] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18)]), T#15 |-> A#16[(app A#17[(var X#7)] T#18)], A#12 |-> A#16[(app A#17 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[T#4[S#2]])]) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#16[(app A#17[(var X#7)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#16= T#15[T#4[S#2]] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#16= T#15[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= (\ X#6.S#10) ;E#18 ;EE#13[X#7,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=T#15;X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), E#9 |-> {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18}, E#17 |-> {X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}} and instantiated rules: (letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#16=T#15[T#4[S#2]];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(\ X#6.S#10);E#18;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(var X#8)] T#23[T#4[S#2]])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#20,A#18,T#15,T#3,A#11,A#19} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23)]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> A#19, T#15 |-> A#19[A#21[(app A#22[(var X#8)] T#23)]], T#20 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[T#4[S#2]])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(var X#8)]] T#21[T#4[S#2]])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#19[(app A#20[[.2]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, T#15 |-> A#19[(app A#20[A#11[(var X#8)]] T#21)], A#18 |-> A#19[(app A#20 T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[T#4[S#2]])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(var X#8)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[A#11[(\ X#6.S#10)]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(var X#8)] T#21[T#4[S#2]])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#19[(app A#20[(\ X#6.S#10)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#9 ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#19[(app A#20[[.]] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21)];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=[.2]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#19[(app A#20[(var X#8)] T#21)], A#11 |-> A#19[(app A#20 T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[T#4[S#2]])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(var X#8)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#19[(app A#20[(\ X#6.S#10)] T#21[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[T#4[S#2]])] ;E#9 ;EE#20[X#19,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#5= (\ X#6.S#10) ;X#7= A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#9 ;EE#20[X#19,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23)];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {[.1]=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#20[X#19,[.2]]}, X#16 |-> X#7, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[(var X#19)] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[T#4[S#2]])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;EE#20[X#19,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);X#7=A#21[(app A#22[(var X#19)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#9;EE#20[X#19,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#23[(app A#24[(var X#20)] T#25[T#4[S#2]])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(var X#8)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#21[X#7,(var X#19)] ;EE#22[X#20,A#11[(\ X#6.S#10)]] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25)];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#21[[.1],(var X#19)];EE#22[X#20,[.2]]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|}, T#15 |-> A#23[(app A#24[(var X#20)] T#25)], A#18 |-> A#23[(app A#24 T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[T#4[S#2]])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#23[(app A#24[(var X#20)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#21[X#7,(var X#19)];EE#22[X#20,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[A#23[(app A#24[(var X#8)] T#25[T#4[S#2]])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#22,A#18,T#15,T#3,A#11,A#21} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#23[(app A#24[[.]] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25)]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[[.2]];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> A#21, T#15 |-> A#21[A#23[(app A#24[(var X#8)] T#25)]], T#22 |-> A#23[(app A#24[(var X#8)] T#25)], A#11 |-> A#23[(app A#24 T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[T#4[S#2]])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[A#23[(app A#24[(var X#8)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[A#23[(app A#24[(\ X#6.S#10)] T#25[(letrec {X#1=S#2} in T#4[(var X#1)])])]];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[A#11[(var X#8)]] T#23[T#4[S#2]])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {A#18,T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#11[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=A#21[(app A#22[[.2]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, T#15 |-> A#21[(app A#22[A#11[(var X#8)]] T#23)], A#18 |-> A#21[(app A#22 T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[T#4[S#2]])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[A#11[(var X#8)]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[A#11[(\ X#6.S#10)]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec X#19= A#21[(app A#22[(var X#8)] T#23[T#4[S#2]])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) , (letrec X#19= A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= (\ X#6.S#10) ;E#9 ;EE#20[X#7,(var X#19)] ;VV#14|X#8,(var X#5)| in A#12[(var X#7)] ) ) where Delta1 = {T#15,T#3,A#11} Delta2 = {} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#7),A#12[[.]]), ((var X#8),A#21[(app A#22[[.]] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),[.]), ((var X#7),A#12[[.]])} Delta4= {} from overlapping <-SR,cp-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(\ X#6.S#10)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) and constraints: A#11/= [.] and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(\ X#6.S#10);E#9;EE#13[X#7,A#11[(var X#8)]];VV#14|X#8,(var X#5)|} in A#12[(var X#7)])} Delta1= {A#11} Delta2= {} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#1),T#4[[.]]),((var X#5),[.]),((var X#7),A#12[[.]]),((var X#8),A#11[[.]]),((var X#5),[.]),((var X#7),A#12[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#19=A#21[(app A#22[(var X#8)] T#23)];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]), EE#13[.1,.2] |-> {X#19=[.2];EE#20[[.1],(var X#19)]}, X#16 |-> X#19, E#17 |-> {X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|}, A#18 |-> [.], T#15 |-> A#21[(app A#22[(var X#8)] T#23)], A#11 |-> A#21[(app A#22 T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) <-ucp3- (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[T#4[S#2]])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ................................................................................ (letrec {X#19=A#21[(app A#22[(var X#8)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) -SR,cp-e2-> (letrec {X#19=A#21[(app A#22[(\ X#6.S#10)] T#23[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(\ X#6.S#10);E#9;EE#20[X#7,(var X#19)];VV#14|X#8,(var X#5)|} in A#12[(var X#7)]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {E#6} in T#9[T#4[S#2]])) , (letrec {E#5;E#6} in T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]) ) where Delta1 = {T#8,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), [{E#5},(letrec {E#6} in [.])], ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),[{E#5},(letrec {E#6} in [.])],((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in (letrec {E#6} in T#9)), T#8 |-> (letrec {E#6} in T#9), S#7 |-> T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#5} in (letrec {E#6} in T#9[(letrec {X#1=S#2} in T#4[(var X#1)])])) <-ucp3- (letrec {E#5} in (letrec {E#6} in T#9[T#4[S#2]])) ................................................................................ (letrec {E#5} in (letrec {E#6} in T#9[(letrec {X#1=S#2} in T#4[(var X#1)])])) -SR,llet-in1-> (letrec {E#5;E#6} in T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]) ================================================================================ Critical Pair: ( (letrec {E#5} in (letrec {X#10=T#9[T#4[S#2]];E#12} in S#7)) , (letrec {X#10=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])];E#12;E#5} in S#7) ) where Delta1 = {T#8,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), [{E#5},(letrec {X#10=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])];E#12} in [.])], ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),[{E#5},(letrec {E#6} in [.])],((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in (letrec {X#10=T#9;E#12} in S#7)), T#8 |-> (letrec {X#10=T#9;E#12} in S#7), E#6 |-> {X#10=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {E#5} in (letrec {X#10=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])];E#12} in S#7)) <-ucp3- (letrec {E#5} in (letrec {X#10=T#9[T#4[S#2]];E#12} in S#7)) ................................................................................ (letrec {E#5} in (letrec {X#10=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])];E#12} in S#7)) -SR,llet-in1-> (letrec {X#10=T#9[(letrec {X#1=S#2} in T#4[(var X#1)])];E#12;E#5} in S#7) ================================================================================ Critical Pair: ( (letrec {E#5} in T#4[S#2]) , (letrec {X#1=S#2;E#5} in T#4[(var X#1)]) ) where Delta1 = {T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), [{E#5},(letrec {X#1=S#2} in [.])], ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),[{E#5},(letrec {E#6} in [.])],((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in [.]), T#8 |-> [.], S#7 |-> T#4[(var X#1)], E#6 |-> {X#1=S#2}} and instantiated rules: (letrec {E#5} in (letrec {X#1=S#2} in T#4[(var X#1)])) <-ucp3- (letrec {E#5} in T#4[S#2]) ................................................................................ (letrec {E#5} in (letrec {X#1=S#2} in T#4[(var X#1)])) -SR,llet-in1-> (letrec {X#1=S#2;E#5} in T#4[(var X#1)]) ================================================================================ Critical Pair: ( (letrec {X#9=T#8[T#4[S#2]];E#11} in (letrec {E#6} in S#7)) , (letrec {X#9=T#8[(letrec {X#1=S#2} in T#4[(var X#1)])];E#11;E#6} in S#7) ) where Delta1 = {T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), [{X#9=T#8[(letrec {X#1=S#2} in T#4[(var X#1)])];E#11},(letrec {E#6} in [.])], ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,llet-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),[{E#5},(letrec {E#6} in [.])],((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#9=T#8;E#11} in (letrec {E#6} in S#7)), E#5 |-> {X#9=T#8[(letrec {X#1=S#2} in T#4[(var X#1)])];E#11}, E#10 |-> {E#11}} and instantiated rules: (letrec {X#9=T#8[(letrec {X#1=S#2} in T#4[(var X#1)])];E#11} in (letrec {E#6} in S#7)) <-ucp3- (letrec {X#9=T#8[T#4[S#2]];E#11} in (letrec {E#6} in S#7)) ................................................................................ (letrec {X#9=T#8[(letrec {X#1=S#2} in T#4[(var X#1)])];E#11} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {X#9=T#8[(letrec {X#1=S#2} in T#4[(var X#1)])];E#11;E#6} in S#7) ================================================================================ Critical Pair: ( (letrec {E#6} in T#9[S#2]) , (letrec {X#1=S#2;E#6} in T#9[(var X#1)]) ) where Delta1 = {T#4} Delta2 = {E#5,E#6} Delta3 = {((var X#1),(letrec {E#6} in T#9)), (S#2,(letrec {E#6} in T#9)), ((letrec {E#6} in T#9[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), [{X#1=S#2},(letrec {E#6} in [.])], ((var X#1),(letrec {E#6} in T#9[[.]]))} Delta4= {} from overlapping <-SR,llet-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),[{E#5},(letrec {E#6} in [.])],((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#8 |-> {}, T#4 |-> (letrec {E#6} in T#9), S#7 |-> T#9[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in (letrec {E#6} in T#9[(var X#1)])) <-ucp3- (letrec {E#6} in T#9[S#2]) ................................................................................ (letrec {X#1=S#2} in (letrec {E#6} in T#9[(var X#1)])) -SR,llet-in1-> (letrec {X#1=S#2;E#6} in T#9[(var X#1)]) ================================================================================ Critical Pair: ( (letrec {X#10=T#9[S#2];E#12} in S#7) , (letrec {X#1=S#2;X#10=T#9[(var X#1)];E#12} in S#7) ) where Delta1 = {T#4} Delta2 = {E#5,E#6} Delta3 = {((var X#1),(letrec {X#10=T#9;E#12} in S#7)), (S#2,(letrec {X#10=T#9;E#12} in S#7)), ((letrec {X#10=T#9[(dummy3 )];E#12} in S#7),(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), [{X#1=S#2},(letrec {X#10=T#9[(var X#1)];E#12} in [.])], ((var X#1),(letrec {X#10=T#9[[.]];E#12} in S#7))} Delta4= {} from overlapping <-SR,llet-in1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in (letrec {E#6} in S#7)) -SR,llet-in1-> (letrec {E#5;E#6} in S#7) and constraints: E#5/= {}, E#6/= {}, ({E#5},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in (letrec {E#6} in S#7))} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),[{E#5},(letrec {E#6} in [.])],((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#8 |-> {}, T#4 |-> (letrec {X#10=T#9;E#12} in S#7), E#6 |-> {X#10=T#9[(var X#1)];E#12}, E#11 |-> {E#12}} and instantiated rules: (letrec {X#1=S#2} in (letrec {X#10=T#9[(var X#1)];E#12} in S#7)) <-ucp3- (letrec {X#10=T#9[S#2];E#12} in S#7) ................................................................................ (letrec {X#1=S#2} in (letrec {X#10=T#9[(var X#1)];E#12} in S#7)) -SR,llet-in1-> (letrec {X#1=S#2;X#10=T#9[(var X#1)];E#12} in S#7) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#6} in S#8) ;E#7 in A#11[(app A#12[(var X#5)] T#13[T#4[S#2]])] ) , (letrec X#5= S#8 ;E#6 ;E#7 in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#9,T#10,T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#1),T#4[[.]]), ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),A#11[(app A#12[[.]] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13)]), T#10 |-> A#11[(app A#12[(var X#5)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[T#4[S#2]])]) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#11[(app A#12[(var X#5)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {E#6} in T#13[T#4[S#2]]);E#7} in A#9[(var X#5)]) , (letrec X#5= T#13[(letrec {X#1=S#2} in T#4[(var X#1)])] ;E#6 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {T#10,T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{E#7},(letrec {E#6} in [.])], ((var X#1),T#4[[.]]), ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {E#6} in T#13);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {E#6} in T#13), S#8 |-> T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=(letrec {E#6} in T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#7} in A#9[(var X#5)]) <-ucp3- (letrec {X#5=(letrec {E#6} in T#13[T#4[S#2]]);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {E#6} in T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#6;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(letrec {X#14=T#13[T#4[S#2]];E#16} in S#8);E#7} in A#9[(var X#5)]) , (letrec X#14= T#13[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= S#8 ;E#16 ;E#7 in A#9[(var X#5)] ) ) where Delta1 = {T#10,T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (A#9[(var X#5)],(letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#16} in [.])), [{E#7},(letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#16} in [.])], ((var X#1),T#4[[.]]), ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {X#14=T#13;E#16} in S#8);E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> (letrec {X#14=T#13;E#16} in S#8), E#6 |-> {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#16}, E#15 |-> {E#16}} and instantiated rules: (letrec {X#5=(letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#16} in S#8);E#7} in A#9[(var X#5)]) <-ucp3- (letrec {X#5=(letrec {X#14=T#13[T#4[S#2]];E#16} in S#8);E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];E#16} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#14=T#13[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=S#8;E#16;E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=T#4[S#2];E#7} in A#9[(var X#5)]) , (letrec {X#1=S#2;X#5=T#4[(var X#1)];E#7} in A#9[(var X#5)]) ) where Delta1 = {T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (A#9[(var X#5)],(letrec {X#1=S#2} in [.])), [{E#7},(letrec {X#1=S#2} in [.])], ((var X#1),T#4[[.]]), ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=[.];E#7} in A#9[(var X#5)]), X#11 |-> X#5, E#12 |-> {E#7}, T#10 |-> [.], S#8 |-> T#4[(var X#1)], E#6 |-> {X#1=S#2}} and instantiated rules: (letrec {X#5=(letrec {X#1=S#2} in T#4[(var X#1)]);E#7} in A#9[(var X#5)]) <-ucp3- (letrec {X#5=T#4[S#2];E#7} in A#9[(var X#5)]) ................................................................................ (letrec {X#5=(letrec {X#1=S#2} in T#4[(var X#1)]);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#1=S#2;X#5=T#4[(var X#1)];E#7} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#11=T#10[T#4[S#2]];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) , (letrec X#11= T#10[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= S#8 ;E#13 ;E#6 in A#9[(var X#5)] ) ) where Delta1 = {T#3} Delta2 = {E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (A#9[(var X#5)],(letrec {E#6} in [.])), [{X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13},(letrec {E#6} in [.])], ((var X#1),T#4[[.]]), ((var X#5),A#9[[.]]), ((var X#5),A#9[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#11=T#10;X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]), E#7 |-> {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13}, E#12 |-> {X#5=(letrec {E#6} in S#8);E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) <-ucp3- (letrec {X#11=T#10[T#4[S#2]];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(letrec {E#6} in S#8);E#13} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=S#8;E#13;E#6} in A#9[(var X#5)]) ================================================================================ Critical Pair: ( A#10[(letrec {E#6} in S#8)] , (letrec {X#5=S#8;E#6} in A#10[(var X#5)]) ) where Delta1 = {T#4,A#9,A#10} Delta2 = {E#6} Delta3 = {((var X#5),A#10[[.]]), ((letrec {E#6} in S#8),A#10[[.]]), (A#10[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), ((letrec {E#6} in S#8),(letrec {X#5=(dummy3 )} in [.])), (A#10[(var X#5)],(letrec {E#6} in [.])), [{},(letrec {E#6} in [.])], ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> [.], X#1 |-> X#5, S#2 |-> (letrec {E#6} in S#8), E#7 |-> {}, A#9 |-> A#10, T#4 |-> A#10[[.]], T#11 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8)} in A#10[(var X#5)]) <-ucp3- A#10[(letrec {E#6} in S#8)] ................................................................................ (letrec {X#5=(letrec {E#6} in S#8)} in A#10[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( A#10[(letrec {E#6} in S#8)] , (letrec {X#5=S#8;E#6} in A#10[(var X#5)]) ) where Delta1 = {T#4,A#9,A#10} Delta2 = {E#6} Delta3 = {((var X#5),A#10), ((letrec {E#6} in S#8),A#10), (A#10[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), ((letrec {E#6} in S#8),(letrec {X#5=(dummy3 )} in [.])), (A#10[(var X#5)],(letrec {E#6} in [.])), [{},(letrec {E#6} in [.])], ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> [.], X#1 |-> X#5, S#2 |-> (letrec {E#6} in S#8), E#7 |-> {}, A#9 |-> A#10[[.]], T#4 |-> A#10, A#11 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8)} in A#10[(var X#5)]) <-ucp3- A#10[(letrec {E#6} in S#8)] ................................................................................ (letrec {X#5=(letrec {E#6} in S#8)} in A#10[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {E#6} in S#8) , (letrec {X#5=S#8;E#6} in (var X#5)) ) where Delta1 = {} Delta2 = {E#6} Delta3 = {((var X#5),[.]), ((letrec {E#6} in S#8),[.]), ((dummy3 ),(letrec {X#5=(dummy3 )} in [.])), ((letrec {E#6} in S#8),(letrec {X#5=(dummy3 )} in [.])), ((var X#5),(letrec {E#6} in [.])), [{},(letrec {E#6} in [.])], ((var X#5),[.]), ((var X#5),[.]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,llet-e1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)]) -SR,llet-e1-> (letrec {X#5=S#8;E#6;E#7} in A#9[(var X#5)]) and constraints: E#6/= {}, (A#9[(var X#5)],(letrec {E#6} in [.])), ({E#7},(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#6} in S#8);E#7} in A#9[(var X#5)])} Delta1= {} Delta2= {E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(A#9[(var X#5)],(letrec {E#6} in [.])),[{E#7},(letrec {E#6} in [.])],((var X#1),T#4[[.]]),((var X#5),A#9[[.]]),((var X#5),A#9[[.]])} and found solution: Sol = {T#3 |-> [.], X#1 |-> X#5, S#2 |-> (letrec {E#6} in S#8), E#7 |-> {}, A#9 |-> [.], T#4 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=(letrec {E#6} in S#8)} in (var X#5)) <-ucp3- (letrec {E#6} in S#8) ................................................................................ (letrec {X#5=(letrec {E#6} in S#8)} in (var X#5)) -SR,llet-e1-> (letrec {X#5=S#8;E#6} in (var X#5)) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[T#4[S#2]])] ) , (letrec X#5= S#9 ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#10,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),[.]), ((var X#6),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15)]), T#12 |-> A#13[(app A#14[(var X#6)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[T#4[S#2]])]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#13[(app A#14[(var X#6)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in T#15[T#4[S#2]]) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= T#15[(letrec {X#1=S#2} in T#4[(var X#1)])] ;E#7 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {E#7} in T#15);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {E#7} in T#15), S#9 |-> T#15[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in T#15[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#5=(letrec {E#7} in T#15[T#4[S#2]]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in T#15[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {X#16=T#15[T#4[S#2]];E#18} in S#9) ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= T#15[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= S#9 ;E#18 ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {X#16=T#15;E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> (letrec {X#16=T#15;E#18} in S#9), E#7 |-> {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18}, E#17 |-> {E#18}} and instantiated rules: (letrec {X#5=(letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#5=(letrec {X#16=T#15[T#4[S#2]];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];E#18} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=T#15[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=S#9;E#18;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec {X#5=T#4[S#2];E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) , (letrec X#1= S#2 ;X#5= T#4[(var X#1)] ;E#8 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#1=S#2;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {X#1=S#2} in [.])), [{E#8;EE#11[X#6,(var X#5)]},(letrec {X#1=S#2} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=[.];E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), X#13 |-> X#5, E#14 |-> {E#8;EE#11[X#6,(var X#5)]}, T#12 |-> [.], S#9 |-> T#4[(var X#1)], E#7 |-> {X#1=S#2}} and instantiated rules: (letrec {X#5=(letrec {X#1=S#2} in T#4[(var X#1)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#5=T#4[S#2];E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {X#1=S#2} in T#4[(var X#1)]);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#1=S#2;X#5=T#4[(var X#1)];E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[T#4[S#2]] ;X#5= (letrec {E#7} in S#9) ;E#15 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) , (letrec X#13= T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] ;X#5= S#9 ;E#15 ;E#7 ;EE#11[X#6,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;E#7;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#13=T#12;X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]), E#8 |-> {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15}, E#14 |-> {X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#13=T#12[T#4[S#2]];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=(letrec {E#7} in S#9);E#15;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];X#5=S#9;E#15;E#7;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#16[(app A#17[(var X#5)] T#18[T#4[S#2]])] ;E#8 in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#7 ;E#8 in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;E#8} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18)];E#8} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8}, T#12 |-> A#16[(app A#17[(var X#5)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#10[(var X#6)]) <-ucp3- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[T#4[S#2]])];E#8} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#16[(app A#17[(var X#5)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;E#8} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#5= (letrec {E#7} in S#9) ;X#6= A#18[(app A#19[(var X#16)] T#20[T#4[S#2]])] ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) , (letrec X#5= S#9 ;X#6= A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#7 ;E#8 ;EE#17[X#16,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;E#8;EE#17[X#16,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#17[X#16,(var X#5)]},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20)];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#17[X#16,[.2]]}, X#13 |-> X#6, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#16,(var X#5)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[T#4[S#2]])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;X#6=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;E#8;EE#17[X#16,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[T#4[S#2]])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= S#9 ;E#7 ;E#8 ;EE#18[X#6,(var X#16)] ;EE#19[X#17,(var X#5)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[T#4[S#2]])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(letrec {E#7} in S#9);E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=S#9;E#7;E#8;EE#18[X#6,(var X#16)];EE#19[X#17,(var X#5)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(var X#5)] T#20[T#4[S#2]])] ;X#5= (letrec {E#7} in S#9) ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) , (letrec X#16= A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;X#5= S#9 ;E#7 ;E#8 ;EE#17[X#6,(var X#16)] in A#10[(var X#6)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), ((var X#5),(letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#7;E#8;EE#17[X#6,(var X#16)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), [{X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#8;EE#17[X#6,(var X#16)]},(letrec {E#7} in [.])], ((var X#1),T#4[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]]), ((var X#5),[.]), ((var X#6),A#10[[.]])} Delta4= {} from overlapping <-SR,llet-e2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#5=S#9;E#7;E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)]) and constraints: E#7/= {}, ((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])), (A#10[(var X#6)],(letrec {E#7} in [.])), ({E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {X#5=(letrec {E#7} in S#9);E#8;EE#11[X#6,(var X#5)]} in A#10[(var X#6)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),((var X#5),(letrec {E#7;E#8;EE#11[X#6,(var X#5)]} in [.])),(A#10[(var X#6)],(letrec {E#7} in [.])),[{E#8;EE#11[X#6,(var X#5)]},(letrec {E#7} in [.])],((var X#1),T#4[[.]]),((var X#5),[.]),((var X#6),A#10[[.]]),((var X#5),[.]),((var X#6),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20)];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]}, T#12 |-> A#18[(app A#19[(var X#5)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) <-ucp3- (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[T#4[S#2]])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=(letrec {E#7} in S#9);E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) -SR,llet-e2-> (letrec {X#16=A#18[(app A#19[(var X#5)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];X#5=S#9;E#7;E#8;EE#17[X#6,(var X#16)]} in A#10[(var X#6)]) ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in T#12[T#4[S#2]]) S#6)] , A#9[(letrec {E#5} in (app T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] S#6))] ) where Delta1 = {T#11,T#10,A#8,T#3,A#9} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {E#5} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> A#9, T#3 |-> A#9[(app (letrec {E#5} in T#12) S#6)], T#10 |-> (app (letrec {E#5} in T#12) S#6), T#11 |-> (letrec {E#5} in T#12), S#7 |-> T#12[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: A#9[(app (letrec {E#5} in T#12[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#6)] <-ucp3- A#9[(app (letrec {E#5} in T#12[T#4[S#2]]) S#6)] ................................................................................ A#9[(app (letrec {E#5} in T#12[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#6)] -SR,lapp1-> A#9[(letrec {E#5} in (app T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {X#13=T#12[T#4[S#2]];E#15} in S#7) S#6)] , A#9[(letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in (app S#7 S#6))] ) where Delta1 = {T#11,T#10,A#8,T#3,A#9} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> A#9, T#3 |-> A#9[(app (letrec {X#13=T#12;E#15} in S#7) S#6)], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#7) S#6), T#11 |-> (letrec {X#13=T#12;E#15} in S#7), E#5 |-> {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15}, E#14 |-> {E#15}} and instantiated rules: A#9[(app (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in S#7) S#6)] <-ucp3- A#9[(app (letrec {X#13=T#12[T#4[S#2]];E#15} in S#7) S#6)] ................................................................................ A#9[(app (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in S#7) S#6)] -SR,lapp1-> A#9[(letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in (app S#7 S#6))] ================================================================================ Critical Pair: ( A#9[(app T#4[S#2] S#6)] , A#9[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#6))] ) where Delta1 = {T#10,A#8,T#3,A#9} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> A#9, T#3 |-> A#9[(app [.] S#6)], T#10 |-> (app [.] S#6), T#11 |-> [.], S#7 |-> T#4[(var X#1)], E#5 |-> {X#1=S#2}} and instantiated rules: A#9[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#6)] <-ucp3- A#9[(app T#4[S#2] S#6)] ................................................................................ A#9[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#6)] -SR,lapp1-> A#9[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#6))] ================================================================================ Critical Pair: ( A#9[(app (letrec {E#5} in S#7) T#11[T#4[S#2]])] , A#9[(letrec {E#5} in (app S#7 T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]))] ) where Delta1 = {T#10,A#8,T#3,A#9} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#11[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#5} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> A#9, T#3 |-> A#9[(app (letrec {E#5} in S#7) T#11)], T#10 |-> (app (letrec {E#5} in S#7) T#11), S#6 |-> T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: A#9[(app (letrec {E#5} in S#7) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] <-ucp3- A#9[(app (letrec {E#5} in S#7) T#11[T#4[S#2]])] ................................................................................ A#9[(app (letrec {E#5} in S#7) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] -SR,lapp1-> A#9[(letrec {E#5} in (app S#7 T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]))] ================================================================================ Critical Pair: ( A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[T#4[S#2]])] , A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) where Delta1 = {A#8,T#3} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {E#5} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11)], A#8 |-> A#9[(app A#10 T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] <-ucp3- A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[T#4[S#2]])] ................................................................................ A#9[(app A#10[(app (letrec {E#5} in S#7) S#6)] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] -SR,lapp1-> A#9[(app A#10[(letrec {E#5} in (app S#7 S#6))] T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])] ================================================================================ Critical Pair: ( (app (letrec {E#5} in T#10[T#4[S#2]]) S#6) , (letrec {E#5} in (app T#10[(letrec {X#1=S#2} in T#4[(var X#1)])] S#6)) ) where Delta1 = {T#9,T#3} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {E#5} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> [.], T#3 |-> (app (letrec {E#5} in T#10) S#6), T#9 |-> (letrec {E#5} in T#10), S#7 |-> T#10[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (app (letrec {E#5} in T#10[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#6) <-ucp3- (app (letrec {E#5} in T#10[T#4[S#2]]) S#6) ................................................................................ (app (letrec {E#5} in T#10[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#6) -SR,lapp1-> (letrec {E#5} in (app T#10[(letrec {X#1=S#2} in T#4[(var X#1)])] S#6)) ================================================================================ Critical Pair: ( (app (letrec {X#11=T#10[T#4[S#2]];E#13} in S#7) S#6) , (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in (app S#7 S#6)) ) where Delta1 = {T#9,T#3} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> [.], T#3 |-> (app (letrec {X#11=T#10;E#13} in S#7) S#6), T#9 |-> (letrec {X#11=T#10;E#13} in S#7), E#5 |-> {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13}, E#12 |-> {E#13}} and instantiated rules: (app (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in S#7) S#6) <-ucp3- (app (letrec {X#11=T#10[T#4[S#2]];E#13} in S#7) S#6) ................................................................................ (app (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in S#7) S#6) -SR,lapp1-> (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in (app S#7 S#6)) ================================================================================ Critical Pair: ( (app T#4[S#2] S#6) , (letrec {X#1=S#2} in (app T#4[(var X#1)] S#6)) ) where Delta1 = {T#3} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#6,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> [.], T#3 |-> (app [.] S#6), T#9 |-> [.], S#7 |-> T#4[(var X#1)], E#5 |-> {X#1=S#2}} and instantiated rules: (app (letrec {X#1=S#2} in T#4[(var X#1)]) S#6) <-ucp3- (app T#4[S#2] S#6) ................................................................................ (app (letrec {X#1=S#2} in T#4[(var X#1)]) S#6) -SR,lapp1-> (letrec {X#1=S#2} in (app T#4[(var X#1)] S#6)) ================================================================================ Critical Pair: ( (app (letrec {E#5} in S#7) T#9[T#4[S#2]]) , (letrec {E#5} in (app S#7 T#9[(letrec {X#1=S#2} in T#4[(var X#1)])])) ) where Delta1 = {T#3} Delta2 = {E#5} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#9[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#5} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp1- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ A#8[(app (letrec {E#5} in S#7) S#6)] -SR,lapp1-> A#8[(letrec {E#5} in (app S#7 S#6))] and constraints: E#5/= {}, (S#6,(letrec {E#5} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= A#8[(app (letrec {E#5} in S#7) S#6)]} Delta1= {} Delta2= {E#5} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#6,(letrec {E#5} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {A#8 |-> [.], T#3 |-> (app (letrec {E#5} in S#7) T#9), S#6 |-> T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (app (letrec {E#5} in S#7) T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]) <-ucp3- (app (letrec {E#5} in S#7) T#9[T#4[S#2]]) ................................................................................ (app (letrec {E#5} in S#7) T#9[(letrec {X#1=S#2} in T#4[(var X#1)])]) -SR,lapp1-> (letrec {E#5} in (app S#7 T#9[(letrec {X#1=S#2} in T#4[(var X#1)])])) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[T#4[S#2]]) S#7)]) , (letrec E#5 in A#11[(letrec {E#6} in (app T#14[(letrec {X#1=S#2} in T#4[(var X#1)])] S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#3,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in T#14) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in T#14) S#7)], T#12 |-> (app (letrec {E#6} in T#14) S#7), T#13 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#7)]) <-ucp3- (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[T#4[S#2]]) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in T#14[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app T#14[(letrec {X#1=S#2} in T#4[(var X#1)])] S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {X#15=T#14[T#4[S#2]];E#17} in S#8) S#7)]) , (letrec E#5 in A#11[(letrec {X#15=T#14[(letrec {X#1=S#2} in T#4[(var X#1)])];E#17} in (app S#8 S#7))] ) ) where Delta1 = {T#13,T#12,A#9,T#10,T#3,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#15=T#14[(letrec {X#1=S#2} in T#4[(var X#1)])];E#17} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#8) S#7), T#13 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(letrec {X#1=S#2} in T#4[(var X#1)])];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#2} in T#4[(var X#1)])];E#17} in S#8) S#7)]) <-ucp3- (letrec {E#5} in A#11[(app (letrec {X#15=T#14[T#4[S#2]];E#17} in S#8) S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {X#15=T#14[(letrec {X#1=S#2} in T#4[(var X#1)])];E#17} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {X#15=T#14[(letrec {X#1=S#2} in T#4[(var X#1)])];E#17} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app T#4[S#2] S#7)]) , (letrec {E#5} in A#11[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#7))]) ) where Delta1 = {T#12,A#9,T#10,T#3,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#11[(app [.] S#7)]), A#9 |-> A#11, T#10 |-> A#11[(app [.] S#7)], T#12 |-> (app [.] S#7), T#13 |-> [.], S#8 |-> T#4[(var X#1)], E#6 |-> {X#1=S#2}} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#7)]) <-ucp3- (letrec {E#5} in A#11[(app T#4[S#2] S#7)]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#7)]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#7))]) ================================================================================ Critical Pair: ( (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[T#4[S#2]])]) , (letrec E#5 in A#11[(letrec {E#6} in (app S#8 T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]))] ) ) where Delta1 = {T#12,A#9,T#10,T#3,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#13[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#6} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13)]), A#9 |-> A#11, T#10 |-> A#11[(app (letrec {E#6} in S#8) T#13)], T#12 |-> (app (letrec {E#6} in S#8) T#13), S#7 |-> T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[T#4[S#2]])]) ................................................................................ (letrec {E#5} in A#11[(app (letrec {E#6} in S#8) T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,lapp2-> (letrec {E#5} in A#11[(letrec {E#6} in (app S#8 T#13[(letrec {X#1=S#2} in T#4[(var X#1)])]))]) ================================================================================ Critical Pair: ( (letrec E#5 in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[T#4[S#2]])] ) , (letrec E#5 in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#9,T#10,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), T#10 |-> A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[T#4[S#2]])]) ................................................................................ (letrec {E#5} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,lapp2-> (letrec {E#5} in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in T#12[T#4[S#2]]) S#7)) , (letrec E#5 in (letrec {E#6} in (app T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] S#7)) ) ) where Delta1 = {T#11,T#10,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in (app (letrec {E#6} in T#12) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in T#12) S#7), T#11 |-> (letrec {E#6} in T#12), S#8 |-> T#12[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#7)) <-ucp3- (letrec {E#5} in (app (letrec {E#6} in T#12[T#4[S#2]]) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in T#12[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {X#13=T#12[T#4[S#2]];E#15} in S#8) S#7)) , (letrec E#5 in (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in (app S#8 S#7)) ) ) where Delta1 = {T#11,T#10,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in (app (letrec {X#13=T#12;E#15} in S#8) S#7)), A#9 |-> [.], T#10 |-> (app (letrec {X#13=T#12;E#15} in S#8) S#7), T#11 |-> (letrec {X#13=T#12;E#15} in S#8), E#6 |-> {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in S#8) S#7)) <-ucp3- (letrec {E#5} in (app (letrec {X#13=T#12[T#4[S#2]];E#15} in S#8) S#7)) ................................................................................ (letrec {E#5} in (app (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in S#8) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app T#4[S#2] S#7)) , (letrec {E#5} in (letrec {X#1=S#2} in (app T#4[(var X#1)] S#7))) ) where Delta1 = {T#10,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in (app [.] S#7)), A#9 |-> [.], T#10 |-> (app [.] S#7), T#11 |-> [.], S#8 |-> T#4[(var X#1)], E#6 |-> {X#1=S#2}} and instantiated rules: (letrec {E#5} in (app (letrec {X#1=S#2} in T#4[(var X#1)]) S#7)) <-ucp3- (letrec {E#5} in (app T#4[S#2] S#7)) ................................................................................ (letrec {E#5} in (app (letrec {X#1=S#2} in T#4[(var X#1)]) S#7)) -SR,lapp2-> (letrec {E#5} in (letrec {X#1=S#2} in (app T#4[(var X#1)] S#7))) ================================================================================ Critical Pair: ( (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[T#4[S#2]])) , (letrec E#5 in (letrec {E#6} in (app S#8 T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])) ) ) where Delta1 = {T#10,T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#11[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#6} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#5} in (app (letrec {E#6} in S#8) T#11)), A#9 |-> [.], T#10 |-> (app (letrec {E#6} in S#8) T#11), S#7 |-> T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])) <-ucp3- (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[T#4[S#2]])) ................................................................................ (letrec {E#5} in (app (letrec {E#6} in S#8) T#11[(letrec {X#1=S#2} in T#4[(var X#1)])])) -SR,lapp2-> (letrec {E#5} in (letrec {E#6} in (app S#8 T#11[(letrec {X#1=S#2} in T#4[(var X#1)])]))) ================================================================================ Critical Pair: ( (letrec {X#11=T#10[T#4[S#2]];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) , (letrec X#11= T#10[(letrec {X#1=S#2} in T#4[(var X#1)])] ;E#13 in A#9[(letrec {E#6} in (app S#8 S#7))] ) ) where Delta1 = {T#3} Delta2 = {E#5,E#6} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),T#4[[.]])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#11=T#10;E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]), E#5 |-> {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13}, E#12 |-> {E#13}} and instantiated rules: (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) <-ucp3- (letrec {X#11=T#10[T#4[S#2]];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) ................................................................................ (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {X#11=T#10[(letrec {X#1=S#2} in T#4[(var X#1)])];E#13} in A#9[(letrec {E#6} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( A#11[(app (letrec {E#6} in T#14[S#2]) S#7)] , (letrec {X#1=S#2} in A#11[(letrec {E#6} in (app T#14[(var X#1)] S#7))]) ) where Delta1 = {T#13,T#12,T#4,A#9,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),A#11[(app (letrec {E#6} in T#14) S#7)]), (S#2,A#11[(app (letrec {E#6} in T#14) S#7)]), (A#11[(app (letrec {E#6} in T#14[(dummy3 )]) S#7)],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),A#11[(app (letrec {E#6} in T#14[[.]]) S#7)])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> A#11, T#4 |-> A#11[(app (letrec {E#6} in T#14) S#7)], T#12 |-> (app (letrec {E#6} in T#14) S#7), T#13 |-> (letrec {E#6} in T#14), S#8 |-> T#14[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in A#11[(app (letrec {E#6} in T#14[(var X#1)]) S#7)]) <-ucp3- A#11[(app (letrec {E#6} in T#14[S#2]) S#7)] ................................................................................ (letrec {X#1=S#2} in A#11[(app (letrec {E#6} in T#14[(var X#1)]) S#7)]) -SR,lapp2-> (letrec {X#1=S#2} in A#11[(letrec {E#6} in (app T#14[(var X#1)] S#7))]) ================================================================================ Critical Pair: ( A#11[(app (letrec {X#15=T#14[S#2];E#17} in S#8) S#7)] , (letrec X#1= S#2 in A#11[(letrec {X#15=T#14[(var X#1)];E#17} in (app S#8 S#7))] ) ) where Delta1 = {T#13,T#12,T#4,A#9,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), (S#2,A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)]), (A#11[(app (letrec {X#15=T#14[(dummy3 )];E#17} in S#8) S#7)],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#15=T#14[(var X#1)];E#17} in [.])), ((var X#1),A#11[(app (letrec {X#15=T#14[[.]];E#17} in S#8) S#7)])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> A#11, T#4 |-> A#11[(app (letrec {X#15=T#14;E#17} in S#8) S#7)], T#12 |-> (app (letrec {X#15=T#14;E#17} in S#8) S#7), T#13 |-> (letrec {X#15=T#14;E#17} in S#8), E#6 |-> {X#15=T#14[(var X#1)];E#17}, E#16 |-> {E#17}} and instantiated rules: (letrec {X#1=S#2} in A#11[(app (letrec {X#15=T#14[(var X#1)];E#17} in S#8) S#7)]) <-ucp3- A#11[(app (letrec {X#15=T#14[S#2];E#17} in S#8) S#7)] ................................................................................ (letrec {X#1=S#2} in A#11[(app (letrec {X#15=T#14[(var X#1)];E#17} in S#8) S#7)]) -SR,lapp2-> (letrec {X#1=S#2} in A#11[(letrec {X#15=T#14[(var X#1)];E#17} in (app S#8 S#7))]) ================================================================================ Critical Pair: ( A#11[(app (letrec {E#6} in S#8) T#13[S#2])] , (letrec {X#1=S#2} in A#11[(letrec {E#6} in (app S#8 T#13[(var X#1)]))]) ) where Delta1 = {T#12,T#4,A#9,A#11} Delta2 = {E#5,E#6} Delta3 = {((var X#1),A#11[(app (letrec {E#6} in S#8) T#13)]), (S#2,A#11[(app (letrec {E#6} in S#8) T#13)]), (A#11[(app (letrec {E#6} in S#8) T#13[(dummy3 )])],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#13[(var X#1)],(letrec {E#6} in [.])), ((var X#1),A#11[(app (letrec {E#6} in S#8) T#13[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> A#11, T#4 |-> A#11[(app (letrec {E#6} in S#8) T#13)], T#12 |-> (app (letrec {E#6} in S#8) T#13), S#7 |-> T#13[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in A#11[(app (letrec {E#6} in S#8) T#13[(var X#1)])]) <-ucp3- A#11[(app (letrec {E#6} in S#8) T#13[S#2])] ................................................................................ (letrec {X#1=S#2} in A#11[(app (letrec {E#6} in S#8) T#13[(var X#1)])]) -SR,lapp2-> (letrec {X#1=S#2} in A#11[(letrec {E#6} in (app S#8 T#13[(var X#1)]))]) ================================================================================ Critical Pair: ( A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[S#2])] , (letrec X#1= S#2 in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(var X#1)])] ) ) where Delta1 = {T#4,A#9} Delta2 = {E#5,E#6} Delta3 = {((var X#1),A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), (S#2,A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)]), (A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(dummy3 )])],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[[.]])])} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, T#4 |-> A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13)], A#9 |-> A#11[(app A#12 T#13[(var X#1)])]} and instantiated rules: (letrec {X#1=S#2} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(var X#1)])]) <-ucp3- A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[S#2])] ................................................................................ (letrec {X#1=S#2} in A#11[(app A#12[(app (letrec {E#6} in S#8) S#7)] T#13[(var X#1)])]) -SR,lapp2-> (letrec {X#1=S#2} in A#11[(app A#12[(letrec {E#6} in (app S#8 S#7))] T#13[(var X#1)])]) ================================================================================ Critical Pair: ( (app (letrec {E#6} in T#12[S#2]) S#7) , (letrec {X#1=S#2} in (letrec {E#6} in (app T#12[(var X#1)] S#7))) ) where Delta1 = {T#11,T#4} Delta2 = {E#5,E#6} Delta3 = {((var X#1),(app (letrec {E#6} in T#12) S#7)), (S#2,(app (letrec {E#6} in T#12) S#7)), ((app (letrec {E#6} in T#12[(dummy3 )]) S#7),(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {E#6} in [.])), ((var X#1),(app (letrec {E#6} in T#12[[.]]) S#7))} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> [.], T#4 |-> (app (letrec {E#6} in T#12) S#7), T#11 |-> (letrec {E#6} in T#12), S#8 |-> T#12[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in (app (letrec {E#6} in T#12[(var X#1)]) S#7)) <-ucp3- (app (letrec {E#6} in T#12[S#2]) S#7) ................................................................................ (letrec {X#1=S#2} in (app (letrec {E#6} in T#12[(var X#1)]) S#7)) -SR,lapp2-> (letrec {X#1=S#2} in (letrec {E#6} in (app T#12[(var X#1)] S#7))) ================================================================================ Critical Pair: ( (app (letrec {X#13=T#12[S#2];E#15} in S#8) S#7) , (letrec {X#1=S#2} in (letrec {X#13=T#12[(var X#1)];E#15} in (app S#8 S#7))) ) where Delta1 = {T#11,T#4} Delta2 = {E#5,E#6} Delta3 = {((var X#1),(app (letrec {X#13=T#12;E#15} in S#8) S#7)), (S#2,(app (letrec {X#13=T#12;E#15} in S#8) S#7)), ((app (letrec {X#13=T#12[(dummy3 )];E#15} in S#8) S#7),(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#7,(letrec {X#13=T#12[(var X#1)];E#15} in [.])), ((var X#1),(app (letrec {X#13=T#12[[.]];E#15} in S#8) S#7))} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> [.], T#4 |-> (app (letrec {X#13=T#12;E#15} in S#8) S#7), T#11 |-> (letrec {X#13=T#12;E#15} in S#8), E#6 |-> {X#13=T#12[(var X#1)];E#15}, E#14 |-> {E#15}} and instantiated rules: (letrec {X#1=S#2} in (app (letrec {X#13=T#12[(var X#1)];E#15} in S#8) S#7)) <-ucp3- (app (letrec {X#13=T#12[S#2];E#15} in S#8) S#7) ................................................................................ (letrec {X#1=S#2} in (app (letrec {X#13=T#12[(var X#1)];E#15} in S#8) S#7)) -SR,lapp2-> (letrec {X#1=S#2} in (letrec {X#13=T#12[(var X#1)];E#15} in (app S#8 S#7))) ================================================================================ Critical Pair: ( (app (letrec {E#6} in S#8) T#11[S#2]) , (letrec {X#1=S#2} in (letrec {E#6} in (app S#8 T#11[(var X#1)]))) ) where Delta1 = {T#4} Delta2 = {E#5,E#6} Delta3 = {((var X#1),(app (letrec {E#6} in S#8) T#11)), (S#2,(app (letrec {E#6} in S#8) T#11)), ((app (letrec {E#6} in S#8) T#11[(dummy3 )]),(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#11[(var X#1)],(letrec {E#6} in [.])), ((var X#1),(app (letrec {E#6} in S#8) T#11[[.]]))} Delta4= {} from overlapping <-SR,lapp2- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)]) -SR,lapp2-> (letrec {E#5} in A#9[(letrec {E#6} in (app S#8 S#7))]) and constraints: E#5/= {}, E#6/= {}, (S#7,(letrec {E#6} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#5} in A#9[(app (letrec {E#6} in S#8) S#7)])} Delta1= {} Delta2= {E#5,E#6} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#7,(letrec {E#6} in [.])),((var X#1),T#4[[.]])} and found solution: Sol = {T#3 |-> [.], E#5 |-> {X#1=S#2}, E#10 |-> {}, A#9 |-> [.], T#4 |-> (app (letrec {E#6} in S#8) T#11), S#7 |-> T#11[(var X#1)]} and instantiated rules: (letrec {X#1=S#2} in (app (letrec {E#6} in S#8) T#11[(var X#1)])) <-ucp3- (app (letrec {E#6} in S#8) T#11[S#2]) ................................................................................ (letrec {X#1=S#2} in (app (letrec {E#6} in S#8) T#11[(var X#1)])) -SR,lapp2-> (letrec {X#1=S#2} in (letrec {E#6} in (app S#8 T#11[(var X#1)]))) ================================================================================ Critical Pair: ( (letrec E#6 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#13[(app A#14[(var X#5)] T#15[T#4[S#2]])] ) , (letrec E#6 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])] ) ) where Delta1 = {A#10,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]), ((var X#5),A#13[(app A#14[[.]] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15)]), T#12 |-> A#13[(app A#14[(var X#5)] T#15)], A#10 |-> A#13[(app A#14 T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) <-ucp3- (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[T#4[S#2]])]) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#13[(app A#14[(var X#5)] T#15[(letrec {X#1=S#2} in T#4[(var X#1)])])]) ================================================================================ Critical Pair: ( (letrec X#13= T#12[T#4[S#2]] ;E#15 ;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#13= T#12[(letrec {X#1=S#2} in T#4[(var X#1)])] ;E#15 ;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#13=T#12;E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), E#6 |-> {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15}, E#14 |-> {E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]}} and instantiated rules: (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#13=T#12[T#4[S#2]];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#13=T#12[(letrec {X#1=S#2} in T#4[(var X#1)])];E#15;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in T#19[T#4[S#2]]) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app T#19[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#3,A#16} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app (letrec {E#7} in T#19) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in T#19) S#8)], T#17 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8)];E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app (letrec {E#7} in T#19[T#4[S#2]]) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app T#19[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {X#20=T#19[T#4[S#2]];E#22} in S#9) S#8)] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in (app S#9 S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#17,A#15,T#12,T#3,A#16} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {X#20=T#19;E#22} in S#9) S#8)], T#17 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app (letrec {X#20=T#19[T#4[S#2]];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in S#9) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in (app S#9 S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=A#16[(app T#4[S#2] S#8)];E#6} in A#10[(var X#5)]) , (letrec X#5= A#16[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#8))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#3,A#16} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app [.] S#8)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app [.] S#8)], T#17 |-> (app [.] S#8), T#18 |-> [.], S#9 |-> T#4[(var X#1)], E#7 |-> {X#1=S#2}} and instantiated rules: (letrec {X#5=A#16[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8)];E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app T#4[S#2] S#8)];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8)];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#8))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app (letrec {E#7} in S#9) T#18[T#4[S#2]])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(letrec {E#7} in (app S#9 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]))] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#17,A#15,T#12,T#3,A#16} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#18[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[[.2]]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> A#16, T#12 |-> A#16[(app (letrec {E#7} in S#9) T#18)], T#17 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[T#4[S#2]])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(letrec {E#7} in (app S#9 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]))];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[T#4[S#2]])] ;E#6 in A#10[(var X#5)] ) , (letrec X#5= A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)];E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#16[(app A#17[[.2]] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]}, X#13 |-> X#5, E#14 |-> {E#6}, T#12 |-> A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18)], A#15 |-> A#16[(app A#17 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[T#4[S#2]])];E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#16[(app A#17[(app (letrec {E#7} in S#9) S#8)] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#16[(app A#17[(letrec {E#7} in (app S#9 S#8))] T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(app (letrec {E#7} in T#17[T#4[S#2]]) S#8);E#6} in A#10[(var X#5)]) , (letrec X#5= (letrec {E#7} in (app T#17[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(app (letrec {E#7} in T#17) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#17) S#8), T#16 |-> (letrec {E#7} in T#17), S#9 |-> T#17[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8);E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=(app (letrec {E#7} in T#17[T#4[S#2]]) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in T#17[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app T#17[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= (app (letrec {X#18=T#17[T#4[S#2]];E#20} in S#9) S#8) ;E#6 in A#10[(var X#5)] ) , (letrec X#5= (letrec {X#18=T#17[(letrec {X#1=S#2} in T#4[(var X#1)])];E#20} in (app S#9 S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#16,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#18=T#17[(letrec {X#1=S#2} in T#4[(var X#1)])];E#20} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(app (letrec {X#18=T#17;E#20} in S#9) S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {X#18=T#17;E#20} in S#9) S#8), T#16 |-> (letrec {X#18=T#17;E#20} in S#9), E#7 |-> {X#18=T#17[(letrec {X#1=S#2} in T#4[(var X#1)])];E#20}, E#19 |-> {E#20}} and instantiated rules: (letrec {X#5=(app (letrec {X#18=T#17[(letrec {X#1=S#2} in T#4[(var X#1)])];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=(app (letrec {X#18=T#17[T#4[S#2]];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {X#18=T#17[(letrec {X#1=S#2} in T#4[(var X#1)])];E#20} in S#9) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {X#18=T#17[(letrec {X#1=S#2} in T#4[(var X#1)])];E#20} in (app S#9 S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(app T#4[S#2] S#8);E#6} in A#10[(var X#5)]) , (letrec X#5= (letrec {X#1=S#2} in (app T#4[(var X#1)] S#8)) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(app [.] S#8);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app [.] S#8), T#16 |-> [.], S#9 |-> T#4[(var X#1)], E#7 |-> {X#1=S#2}} and instantiated rules: (letrec {X#5=(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8);E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=(app T#4[S#2] S#8);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {X#1=S#2} in (app T#4[(var X#1)] S#8));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#5=(app (letrec {E#7} in S#9) T#16[T#4[S#2]]);E#6} in A#10[(var X#5)]) , (letrec X#5= (letrec {E#7} in (app S#9 T#16[(letrec {X#1=S#2} in T#4[(var X#1)])])) ;E#6 in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#16[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=(app (letrec {E#7} in S#9) T#16);E#6} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=[.2]}, X#13 |-> X#5, E#14 |-> {E#6}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#16), S#8 |-> T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#6} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=(app (letrec {E#7} in S#9) T#16[T#4[S#2]]);E#6} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=(app (letrec {E#7} in S#9) T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#6} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=(letrec {E#7} in (app S#9 T#16[(letrec {X#1=S#2} in T#4[(var X#1)])]));E#6} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#5= A#18[(app A#19[(var X#16)] T#20[T#4[S#2]])] ;E#6 ;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#5= A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#6 ;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20)];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {[.1]=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#17[X#16,[.2]]}, X#13 |-> X#5, E#14 |-> {E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#18[(app A#19[(var X#16)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[T#4[S#2]])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#16,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#18[(app A#19[(var X#16)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#16,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#20[(app A#21[(var X#17)] T#22[T#4[S#2]])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(app (letrec {E#7} in S#9) S#8)] in A#10[(var X#5)] ) , (letrec X#16= A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#6 ;EE#18[X#5,(var X#16)] ;EE#19[X#17,(letrec {E#7} in (app S#9 S#8))] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22)];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#18[[.1],(var X#16)];EE#19[X#17,[.2]]}, X#13 |-> X#16, E#14 |-> {E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]}, T#12 |-> A#20[(app A#21[(var X#17)] T#22)], A#15 |-> A#20[(app A#21 T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[T#4[S#2]])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#20[(app A#21[(var X#17)] T#22[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#18[X#5,(var X#16)];EE#19[X#17,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in T#21[T#4[S#2]]) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app T#21[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#3,A#18} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app (letrec {E#7} in T#21) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in T#21) S#8)], T#19 |-> (app (letrec {E#7} in T#21) S#8), T#20 |-> (letrec {E#7} in T#21), S#9 |-> T#21[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app (letrec {E#7} in T#21[T#4[S#2]]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in T#21[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app T#21[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {X#22=T#21[T#4[S#2]];E#24} in S#9) S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#22=T#21[(letrec {X#1=S#2} in T#4[(var X#1)])];E#24} in (app S#9 S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#20,T#19,A#15,T#12,T#3,A#18} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#22=T#21[(letrec {X#1=S#2} in T#4[(var X#1)])];E#24} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {X#22=T#21;E#24} in S#9) S#8)], T#19 |-> (app (letrec {X#22=T#21;E#24} in S#9) S#8), T#20 |-> (letrec {X#22=T#21;E#24} in S#9), E#7 |-> {X#22=T#21[(letrec {X#1=S#2} in T#4[(var X#1)])];E#24}, E#23 |-> {E#24}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#2} in T#4[(var X#1)])];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app (letrec {X#22=T#21[T#4[S#2]];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {X#22=T#21[(letrec {X#1=S#2} in T#4[(var X#1)])];E#24} in S#9) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {X#22=T#21[(letrec {X#1=S#2} in T#4[(var X#1)])];E#24} in (app S#9 S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app T#4[S#2] S#8)] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#8))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#3,A#18} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app [.] S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app [.] S#8)], T#19 |-> (app [.] S#8), T#20 |-> [.], S#9 |-> T#4[(var X#1)], E#7 |-> {X#1=S#2}} and instantiated rules: (letrec {X#16=A#18[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app T#4[S#2] S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {X#1=S#2} in (app T#4[(var X#1)] S#8))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app (letrec {E#7} in S#9) T#20[T#4[S#2]])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(letrec {E#7} in (app S#9 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])]))] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#19,A#15,T#12,T#3,A#18} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#20[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[[.2]];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> A#18, T#12 |-> A#18[(app (letrec {E#7} in S#9) T#20)], T#19 |-> (app (letrec {E#7} in S#9) T#20), S#8 |-> T#20[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[T#4[S#2]])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app (letrec {E#7} in S#9) T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(letrec {E#7} in (app S#9 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])]))];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[T#4[S#2]])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])] ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {A#15,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=A#18[(app A#19[[.2]] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, T#12 |-> A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20)], A#15 |-> A#18[(app A#19 T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])]} and instantiated rules: (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[T#4[S#2]])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=A#18[(app A#19[(app (letrec {E#7} in S#9) S#8)] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=A#18[(app A#19[(letrec {E#7} in (app S#9 S#8))] T#20[(letrec {X#1=S#2} in T#4[(var X#1)])])];E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in T#19[T#4[S#2]]) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app T#19[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=(app (letrec {E#7} in T#19) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in T#19) S#8), T#18 |-> (letrec {E#7} in T#19), S#9 |-> T#19[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=(app (letrec {E#7} in T#19[T#4[S#2]]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in T#19[(letrec {X#1=S#2} in T#4[(var X#1)])]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app T#19[(letrec {X#1=S#2} in T#4[(var X#1)])] S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {X#20=T#19[T#4[S#2]];E#22} in S#9) S#8) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in (app S#9 S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#18,T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=(app (letrec {X#20=T#19;E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {X#20=T#19;E#22} in S#9) S#8), T#18 |-> (letrec {X#20=T#19;E#22} in S#9), E#7 |-> {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22}, E#21 |-> {E#22}} and instantiated rules: (letrec {X#16=(app (letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=(app (letrec {X#20=T#19[T#4[S#2]];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in S#9) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {X#20=T#19[(letrec {X#1=S#2} in T#4[(var X#1)])];E#22} in (app S#9 S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec {X#16=(app T#4[S#2] S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) , (letrec X#16= (letrec {X#1=S#2} in (app T#4[(var X#1)] S#8)) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (S#8,(letrec {X#1=S#2} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=(app [.] S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app [.] S#8), T#18 |-> [.], S#9 |-> T#4[(var X#1)], E#7 |-> {X#1=S#2}} and instantiated rules: (letrec {X#16=(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=(app T#4[S#2] S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {X#1=S#2} in T#4[(var X#1)]) S#8);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {X#1=S#2} in (app T#4[(var X#1)] S#8));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( (letrec X#16= (app (letrec {E#7} in S#9) T#18[T#4[S#2]]) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) , (letrec X#16= (letrec {E#7} in (app S#9 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])])) ;E#6 ;EE#17[X#5,(var X#16)] in A#10[(var X#5)] ) ) where Delta1 = {T#12,T#3} Delta2 = {E#7} Delta3 = {((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])), (T#18[(letrec {X#1=S#2} in T#4[(var X#1)])],(letrec {E#7} in [.])), ((var X#1),T#4[[.]]), ((var X#5),A#10[[.]]), ((var X#5),A#10[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> (letrec {X#16=(app (letrec {E#7} in S#9) T#18);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]), EE#11[.1,.2] |-> {X#16=[.2];EE#17[[.1],(var X#16)]}, X#13 |-> X#16, E#14 |-> {E#6;EE#17[X#5,(var X#16)]}, A#15 |-> [.], T#12 |-> (app (letrec {E#7} in S#9) T#18), S#8 |-> T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]} and instantiated rules: (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) <-ucp3- (letrec {X#16=(app (letrec {E#7} in S#9) T#18[T#4[S#2]]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ................................................................................ (letrec {X#16=(app (letrec {E#7} in S#9) T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]);E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {X#16=(letrec {E#7} in (app S#9 T#18[(letrec {X#1=S#2} in T#4[(var X#1)])]));E#6;EE#17[X#5,(var X#16)]} in A#10[(var X#5)]) ================================================================================ Critical Pair: ( A#13[A#12[(app (letrec {E#7} in S#9) S#8)]] , (letrec {X#5=A#12[(letrec {E#7} in (app S#9 S#8))]} in A#13[(var X#5)]) ) where Delta1 = {T#4,A#10,A#13} Delta2 = {E#7} Delta3 = {((var X#5),A#13[[.]]), (A#12[(app (letrec {E#7} in S#9) S#8)],A#13[[.]]), (A#13[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), (A#12[(app (letrec {E#7} in S#9) S#8)],(letrec {X#5=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> [.], EE#11[.1,.2] |-> {[.1]=A#12[[.2]]}, X#1 |-> X#5, S#2 |-> A#12[(app (letrec {E#7} in S#9) S#8)], E#6 |-> {}, A#10 |-> A#13, T#4 |-> A#13[[.]], T#14 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=A#12[(app (letrec {E#7} in S#9) S#8)]} in A#13[(var X#5)]) <-ucp3- A#13[A#12[(app (letrec {E#7} in S#9) S#8)]] ................................................................................ (letrec {X#5=A#12[(app (letrec {E#7} in S#9) S#8)]} in A#13[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#12[(letrec {E#7} in (app S#9 S#8))]} in A#13[(var X#5)]) ================================================================================ Critical Pair: ( A#13[A#12[(app (letrec {E#7} in S#9) S#8)]] , (letrec {X#5=A#12[(letrec {E#7} in (app S#9 S#8))]} in A#13[(var X#5)]) ) where Delta1 = {T#4,A#10,A#13} Delta2 = {E#7} Delta3 = {((var X#5),A#13), (A#12[(app (letrec {E#7} in S#9) S#8)],A#13), (A#13[(dummy3 )],(letrec {X#5=(dummy3 )} in [.])), (A#12[(app (letrec {E#7} in S#9) S#8)],(letrec {X#5=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]]), ((var X#5),A#13[[.]])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> [.], EE#11[.1,.2] |-> {[.1]=A#12[[.2]]}, X#1 |-> X#5, S#2 |-> A#12[(app (letrec {E#7} in S#9) S#8)], E#6 |-> {}, A#10 |-> A#13[[.]], T#4 |-> A#13, A#14 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=A#12[(app (letrec {E#7} in S#9) S#8)]} in A#13[(var X#5)]) <-ucp3- A#13[A#12[(app (letrec {E#7} in S#9) S#8)]] ................................................................................ (letrec {X#5=A#12[(app (letrec {E#7} in S#9) S#8)]} in A#13[(var X#5)]) -SR,lapp3-> (letrec {X#5=A#12[(letrec {E#7} in (app S#9 S#8))]} in A#13[(var X#5)]) ================================================================================ Critical Pair: ( A#12[(app (letrec {E#7} in S#9) S#8)] , (letrec {X#5=A#12[(letrec {E#7} in (app S#9 S#8))]} in (var X#5)) ) where Delta1 = {} Delta2 = {E#7} Delta3 = {((var X#5),[.]), (A#12[(app (letrec {E#7} in S#9) S#8)],[.]), ((dummy3 ),(letrec {X#5=(dummy3 )} in [.])), (A#12[(app (letrec {E#7} in S#9) S#8)],(letrec {X#5=(dummy3 )} in [.])), (S#8,(letrec {E#7} in [.])), ((var X#5),[.]), ((var X#5),[.]), ((var X#5),[.])} Delta4= {} from overlapping <-SR,lapp3- . -ucp3-> with input rules: T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] <-ucp3- T#3[T#4[S#2]] and constraints: ((var X#1),T#4), (S#2,T#4), (T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])), (S#2,(letrec {X#1=(dummy3 )} in [.])) ................................................................................ (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)]) -SR,lapp3-> (letrec {E#6;EE#11[X#5,(letrec {E#7} in (app S#9 S#8))]} in A#10[(var X#5)]) and constraints: E#7/= {}, (S#8,(letrec {E#7} in [.])) and letrec unification problem: Gamma ={ T#3[(letrec {X#1=S#2} in T#4[(var X#1)])] =?= (letrec {E#6;EE#11[X#5,(app (letrec {E#7} in S#9) S#8)]} in A#10[(var X#5)])} Delta1= {} Delta2= {E#7} Delta3= {((var X#1),T#4),(S#2,T#4),(T#4[(dummy3 )],(letrec {X#1=(dummy3 )} in [.])),(S#2,(letrec {X#1=(dummy3 )} in [.])),(S#8,(letrec {E#7} in [.])),((var X#1),T#4[[.]]),((var X#5),A#10[[.]]),((var X#5),A#10[[.]])} and found solution: Sol = {T#3 |-> [.], EE#11[.1,.2] |-> {[.1]=A#12[[.2]]}, X#1 |-> X#5, S#2 |-> A#12[(app (letrec {E#7} in S#9) S#8)], E#6 |-> {}, A#10 |-> [.], T#4 |-> [.], X#5 |-> X#5} and instantiated rules: (letrec {X#5=A#12[(app (letrec {E#7} in S#9) S#8)]} in (var X#5)) <-ucp3- A#12[(app (letrec {E#7} in S#9) S#8)] ................................................................................ (letrec {X#5=A#12[(app (letrec {E#7} in S#9) S#8)]} in (var X#5)) -SR,lapp3-> (letrec {X#5=A#12[(letrec {E#7} in (app S#9 S#8))]} in (var X#5)) ========================================================= Statistics: --------------------------------------------------------- #critical pairs <==llet-in1== . ==SR,lbeta1==> : 3 <==llet-in1== . ==SR,lbeta2==> : 4 <==llet-in1== . ==SR,lbeta3==> : 10 <==llet-in1== . ==SR,cp-in1==> : 2 <==llet-in1== . ==SR,cp-in2==> : 2 <==llet-in1== . ==SR,cp-e1==> : 10 <==llet-in1== . ==SR,cp-e2==> : 10 <==llet-in1== . ==SR,llet-in1==> : 5 <==llet-in1== . ==SR,llet-e1==> : 5 <==llet-in1== . ==SR,llet-e2==> : 9 <==llet-in1== . ==SR,lapp1==> : 9 <==llet-in1== . ==SR,lapp2==> : 10 <==llet-in1== . ==SR,lapp3==> : 22 <==llet-e1== . ==SR,lbeta1==> : 3 <==llet-e1== . ==SR,lbeta2==> : 5 <==llet-e1== . ==SR,lbeta3==> : 11 <==llet-e1== . ==SR,cp-in1==> : 3 <==llet-e1== . ==SR,cp-in2==> : 3 <==llet-e1== . ==SR,cp-e1==> : 11 <==llet-e1== . ==SR,cp-e2==> : 11 <==llet-e1== . ==SR,llet-in1==> : 5 <==llet-e1== . ==SR,llet-e1==> : 7 <==llet-e1== . ==SR,llet-e2==> : 11 <==llet-e1== . ==SR,lapp1==> : 9 <==llet-e1== . ==SR,lapp2==> : 11 <==llet-e1== . ==SR,lapp3==> : 23 <==cp-e1== . ==SR,lbeta1==> : 3 <==cp-e1== . ==SR,lbeta2==> : 5 <==cp-e1== . ==SR,lbeta3==> : 23 <==cp-e1== . ==SR,cp-in1==> : 5 <==cp-e1== . ==SR,cp-in2==> : 7 <==cp-e1== . ==SR,cp-e1==> : 37 <==cp-e1== . ==SR,cp-e2==> : 31 <==cp-e1== . ==SR,llet-in1==> : 5 <==cp-e1== . ==SR,llet-e1==> : 8 <==cp-e1== . ==SR,llet-e2==> : 16 <==cp-e1== . ==SR,lapp1==> : 9 <==cp-e1== . ==SR,lapp2==> : 11 <==cp-e1== . ==SR,lapp3==> : 39 <==cp-in1== . ==SR,lbeta1==> : 3 <==cp-in1== . ==SR,lbeta2==> : 9 <==cp-in1== . ==SR,lbeta3==> : 11 <==cp-in1== . ==SR,cp-in1==> : 7 <==cp-in1== . ==SR,cp-in2==> : 4 <==cp-in1== . ==SR,cp-e1==> : 12 <==cp-in1== . ==SR,cp-e2==> : 12 <==cp-in1== . ==SR,llet-in1==> : 6 <==cp-in1== . ==SR,llet-e1==> : 6 <==cp-in1== . ==SR,llet-e2==> : 10 <==cp-in1== . ==SR,lapp1==> : 9 <==cp-in1== . ==SR,lapp2==> : 17 <==cp-in1== . ==SR,lapp3==> : 23 <==lbeta1== . ==SR,lbeta1==> : 6 <==lbeta1== . ==SR,lbeta2==> : 7 <==lbeta1== . ==SR,lbeta3==> : 16 <==lbeta1== . ==SR,cp-in1==> : 2 <==lbeta1== . ==SR,cp-in2==> : 2 <==lbeta1== . ==SR,cp-e1==> : 10 <==lbeta1== . ==SR,cp-e2==> : 10 <==lbeta1== . ==SR,llet-in1==> : 3 <==lbeta1== . ==SR,llet-e1==> : 4 <==lbeta1== . ==SR,llet-e2==> : 8 <==lbeta1== . ==SR,lapp1==> : 7 <==lbeta1== . ==SR,lapp2==> : 8 <==lbeta1== . ==SR,lapp3==> : 18 <==lapp1== . ==SR,lbeta1==> : 3 <==lapp1== . ==SR,lbeta2==> : 4 <==lapp1== . ==SR,lbeta3==> : 10 <==lapp1== . ==SR,cp-in1==> : 2 <==lapp1== . ==SR,cp-in2==> : 2 <==lapp1== . ==SR,cp-e1==> : 10 <==lapp1== . ==SR,cp-e2==> : 10 <==lapp1== . ==SR,llet-in1==> : 3 <==lapp1== . ==SR,llet-e1==> : 4 <==lapp1== . ==SR,llet-e2==> : 8 <==lapp1== . ==SR,lapp1==> : 10 <==lapp1== . ==SR,lapp2==> : 11 <==lapp1== . ==SR,lapp3==> : 24 <==cpx-in1== . ==SR,lbeta1==> : 3 <==cpx-in1== . ==SR,lbeta2==> : 9 <==cpx-in1== . ==SR,lbeta3==> : 16 <==cpx-in1== . ==SR,cp-in1==> : 3 <==cpx-in1== . ==SR,cp-in2==> : 13 <==cpx-in1== . ==SR,cp-e1==> : 16 <==cpx-in1== . ==SR,cp-e2==> : 20 <==cpx-in1== . ==SR,llet-in1==> : 6 <==cpx-in1== . ==SR,llet-e1==> : 6 <==cpx-in1== . ==SR,llet-e2==> : 20 <==cpx-in1== . ==SR,lapp1==> : 9 <==cpx-in1== . ==SR,lapp2==> : 17 <==cpx-in1== . ==SR,lapp3==> : 28 <==cpx-e1== . ==SR,lbeta1==> : 3 <==cpx-e1== . ==SR,lbeta2==> : 5 <==cpx-e1== . ==SR,lbeta3==> : 59 <==cpx-e1== . ==SR,cp-in1==> : 4 <==cpx-e1== . ==SR,cp-in2==> : 16 <==cpx-e1== . ==SR,cp-e1==> : 50 <==cpx-e1== . ==SR,cp-e2==> : 110 <==cpx-e1== . ==SR,llet-in1==> : 5 <==cpx-e1== . ==SR,llet-e1==> : 8 <==cpx-e1== . ==SR,llet-e2==> : 56 <==cpx-e1== . ==SR,lapp1==> : 9 <==cpx-e1== . ==SR,lapp2==> : 11 <==cpx-e1== . ==SR,lapp3==> : 83 <==xch1== . ==SR,lbeta1==> : 3 <==xch1== . ==SR,lbeta2==> : 5 <==xch1== . ==SR,lbeta3==> : 19 <==xch1== . ==SR,cp-in1==> : 4 <==xch1== . ==SR,cp-in2==> : 14 <==xch1== . ==SR,cp-e1==> : 20 <==xch1== . ==SR,cp-e2==> : 30 <==xch1== . ==SR,llet-in1==> : 5 <==xch1== . ==SR,llet-e1==> : 7 <==xch1== . ==SR,llet-e2==> : 21 <==xch1== . ==SR,lapp1==> : 9 <==xch1== . ==SR,lapp2==> : 11 <==xch1== . ==SR,lapp3==> : 31 <==gc1== . ==SR,lbeta1==> : 3 <==gc1== . ==SR,lbeta2==> : 5 <==gc1== . ==SR,lbeta3==> : 10 <==gc1== . ==SR,cp-in1==> : 2 <==gc1== . ==SR,cp-in2==> : 2 <==gc1== . ==SR,cp-e1==> : 10 <==gc1== . ==SR,cp-e2==> : 10 <==gc1== . ==SR,llet-in1==> : 5 <==gc1== . ==SR,llet-e1==> : 5 <==gc1== . ==SR,llet-e2==> : 9 <==gc1== . ==SR,lapp1==> : 9 <==gc1== . ==SR,lapp2==> : 11 <==gc1== . ==SR,lapp3==> : 22 <==gc2== . ==SR,lbeta1==> : 3 <==gc2== . ==SR,lbeta2==> : 5 <==gc2== . ==SR,lbeta3==> : 11 <==gc2== . ==SR,cp-in1==> : 3 <==gc2== . ==SR,cp-in2==> : 3 <==gc2== . ==SR,cp-e1==> : 11 <==gc2== . ==SR,cp-e2==> : 11 <==gc2== . ==SR,llet-in1==> : 5 <==gc2== . ==SR,llet-e1==> : 6 <==gc2== . ==SR,llet-e2==> : 10 <==gc2== . ==SR,lapp1==> : 9 <==gc2== . ==SR,lapp2==> : 11 <==gc2== . ==SR,lapp3==> : 23 <==ucp1== . ==SR,lbeta1==> : 3 <==ucp1== . ==SR,lbeta2==> : 7 <==ucp1== . ==SR,lbeta3==> : 17 <==ucp1== . ==SR,cp-in1==> : 6 <==ucp1== . ==SR,cp-in2==> : 9 <==ucp1== . ==SR,cp-e1==> : 17 <==ucp1== . ==SR,cp-e2==> : 17 <==ucp1== . ==SR,llet-in1==> : 6 <==ucp1== . ==SR,llet-e1==> : 9 <==ucp1== . ==SR,llet-e2==> : 16 <==ucp1== . ==SR,lapp1==> : 9 <==ucp1== . ==SR,lapp2==> : 17 <==ucp1== . ==SR,lapp3==> : 29 <==ucp2== . ==SR,lbeta1==> : 3 <==ucp2== . ==SR,lbeta2==> : 5 <==ucp2== . ==SR,lbeta3==> : 31 <==ucp2== . ==SR,cp-in1==> : 3 <==ucp2== . ==SR,cp-in2==> : 9 <==ucp2== . ==SR,cp-e1==> : 39 <==ucp2== . ==SR,cp-e2==> : 53 <==ucp2== . ==SR,llet-in1==> : 5 <==ucp2== . ==SR,llet-e1==> : 8 <==ucp2== . ==SR,llet-e2==> : 34 <==ucp2== . ==SR,lapp1==> : 9 <==ucp2== . ==SR,lapp2==> : 11 <==ucp2== . ==SR,lapp3==> : 51 <==ucp3== . ==SR,lbeta1==> : 3 <==ucp3== . ==SR,lbeta2==> : 7 <==ucp3== . ==SR,lbeta3==> : 13 <==ucp3== . ==SR,cp-in1==> : 5 <==ucp3== . ==SR,cp-in2==> : 2 <==ucp3== . ==SR,cp-e1==> : 10 <==ucp3== . ==SR,cp-e2==> : 10 <==ucp3== . ==SR,llet-in1==> : 6 <==ucp3== . ==SR,llet-e1==> : 8 <==ucp3== . ==SR,llet-e2==> : 9 <==ucp3== . ==SR,lapp1==> : 9 <==ucp3== . ==SR,lapp2==> : 17 <==ucp3== . ==SR,lapp3==> : 25 --------------------------------------------------------- Overlaps per transformation #critical pairs cp-e1 : 199 cp-in1 : 129 cpx-e1 : 419 cpx-in1 : 166 gc1 : 103 gc2 : 111 lapp1 : 101 lbeta1 : 101 llet-e1 : 113 llet-in1 : 101 ucp1 : 162 ucp2 : 261 ucp3 : 124 xch1 : 179 --------------------------------------------------------- ========================================================= Total number of critical pairs: 2269 =========================================================