YES We show the termination of the TRS R: app(rev(),nil()) -> nil() app(rev(),app(app(cons(),x),l)) -> app(app(cons(),app(app(rev1(),x),l)),app(app(rev2(),x),l)) app(app(rev1(),|0|()),nil()) -> |0|() app(app(rev1(),app(s(),x)),nil()) -> app(s(),x) app(app(rev1(),x),app(app(cons(),y),l)) -> app(app(rev1(),y),l) app(app(rev2(),x),nil()) -> nil() app(app(rev2(),x),app(app(cons(),y),l)) -> app(rev(),app(app(cons(),x),app(app(rev2(),y),l))) app(app(map(),f),nil()) -> nil() app(app(map(),f),app(app(cons(),x),xs)) -> app(app(cons(),app(f,x)),app(app(map(),f),xs)) app(app(filter(),f),nil()) -> nil() app(app(filter(),f),app(app(cons(),x),xs)) -> app(app(app(app(filter2(),app(f,x)),f),x),xs) app(app(app(app(filter2(),true()),f),x),xs) -> app(app(cons(),x),app(app(filter(),f),xs)) app(app(app(app(filter2(),false()),f),x),xs) -> app(app(filter(),f),xs) Instead we prove termination of the uncurried system: app(cons_0(),y) -> cons_1(y) app(cons_1(x1),y) -> cons_2(x1,y) app(filter_0(),y) -> filter_1(y) app(filter_1(x1),y) -> filter_2(x1,y) app(filter2_0(),y) -> filter2_1(y) app(filter2_1(x1),y) -> filter2_2(x1,y) app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) app(map_0(),y) -> map_1(y) app(map_1(x1),y) -> map_2(x1,y) app(rev_0(),y) -> rev_1(y) app(rev1_0(),y) -> rev1_1(y) app(rev1_1(x1),y) -> rev1_2(x1,y) app(rev2_0(),y) -> rev2_1(y) app(rev2_1(x1),y) -> rev2_2(x1,y) app(s_0(),y) -> s_1(y) rev_1(nil_0()) -> nil_0() rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) rev1_2(|0|_0(),nil_0()) -> |0|_0() rev1_2(s_1(x),nil_0()) -> s_1(x) rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) rev2_2(x,nil_0()) -> nil_0() rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) map_2(f,nil_0()) -> nil_0() map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) filter_2(f,nil_0()) -> nil_0() filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: app#(filter_1(x1),y) -> filter_2#(x1,y) p2: app#(filter2_3(x1,x2,x3),y) -> filter2_4#(x1,x2,x3,y) p3: app#(map_1(x1),y) -> map_2#(x1,y) p4: app#(rev_0(),y) -> rev_1#(y) p5: app#(rev1_1(x1),y) -> rev1_2#(x1,y) p6: app#(rev2_1(x1),y) -> rev2_2#(x1,y) p7: rev_1#(cons_2(x,l)) -> rev1_2#(x,l) p8: rev_1#(cons_2(x,l)) -> rev2_2#(x,l) p9: rev1_2#(x,cons_2(y,l)) -> rev1_2#(y,l) p10: rev2_2#(x,cons_2(y,l)) -> rev_1#(cons_2(x,rev2_2(y,l))) p11: rev2_2#(x,cons_2(y,l)) -> rev2_2#(y,l) p12: map_2#(f,cons_2(x,xs)) -> app#(f,x) p13: map_2#(f,cons_2(x,xs)) -> map_2#(f,xs) p14: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p15: filter_2#(f,cons_2(x,xs)) -> app#(f,x) p16: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) p17: filter2_4#(false_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The estimated dependency graph contains the following SCCs: {p1, p2, p3, p12, p13, p14, p15, p16, p17} {p8, p10, p11} {p9} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: app#(filter_1(x1),y) -> filter_2#(x1,y) p2: filter_2#(f,cons_2(x,xs)) -> app#(f,x) p3: app#(map_1(x1),y) -> map_2#(x1,y) p4: map_2#(f,cons_2(x,xs)) -> map_2#(f,xs) p5: map_2#(f,cons_2(x,xs)) -> app#(f,x) p6: app#(filter2_3(x1,x2,x3),y) -> filter2_4#(x1,x2,x3,y) p7: filter2_4#(false_0(),f,x,xs) -> filter_2#(f,xs) p8: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p9: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of r19, r20, r24, r26 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: app#_A(x1,x2) = max{1, x1 - 92, x2 - 20} filter_1_A(x1) = x1 + 50 filter_2#_A(x1,x2) = max{1, x1 - 42, x2 - 20} cons_2_A(x1,x2) = max{19, x1, x2} map_1_A(x1) = max{87, x1 + 82} map_2#_A(x1,x2) = max{1, x1 - 10, x2 - 20} filter2_3_A(x1,x2,x3) = max{x2 + 52, x3 + 91} filter2_4#_A(x1,x2,x3,x4) = max{1, x2 - 42, x3 - 20, x4 - 20} false_0_A = 161 app_A(x1,x2) = max{161, x1 - 88, x2 + 140} true_0_A = 161 rev1_2_A(x1,x2) = max{16, x2 - 175} |0|_0_A = 16 nil_0_A = 174 s_1_A(x1) = 16 map_2_A(x1,x2) = max{173, x1 - 5, x2 + 141} filter_2_A(x1,x2) = max{24, x2 + 4} app#!_A(x1,x2) = max{0, x1 - 51} filter_1!_A(x1) = max{49, x1 + 1} filter_2#!_A(x1,x2) = max{0, x1 - 2} cons_2!_A(x1,x2) = max{29, x1 + 15, x2 + 3} map_1!_A(x1) = 179 map_2#!_A(x1,x2) = max{30, x1 - 51} filter2_3!_A(x1,x2,x3) = max{177, x2 + 49, x3 + 1} filter2_4#!_A(x1,x2,x3,x4) = max{0, x2 - 2} false_0!_A = 49 app!_A(x1,x2) = max{178, x1 - 90, x2 + 28} true_0!_A = 30 rev1_2!_A(x1,x2) = 29 |0|_0!_A = 30 nil_0!_A = 178 s_1!_A(x1) = 178 map_2!_A(x1,x2) = max{177, x1 - 1, x2 + 156} filter_2!_A(x1,x2) = max{48, x2 + 28} 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: app#_A(x1,x2) = max{1, x1 - 14, x2 - 27} filter_1_A(x1) = max{3, x1 + 2} filter_2#_A(x1,x2) = max{1, x1 - 14, x2 - 27} cons_2_A(x1,x2) = max{26, x1, x2} map_1_A(x1) = max{3, x1} map_2#_A(x1,x2) = max{1, x1 - 14, x2 - 27} filter2_3_A(x1,x2,x3) = max{13, x1 - 21, x2, x3 + 11} filter2_4#_A(x1,x2,x3,x4) = max{1, x2 - 14, x3 - 27, x4 - 27} false_0_A = 25 app_A(x1,x2) = 2 true_0_A = 25 rev1_2_A(x1,x2) = max{53, x2 - 107} |0|_0_A = 53 nil_0_A = 53 s_1_A(x1) = 3 map_2_A(x1,x2) = max{52, x1 - 12, x2 + 25} filter_2_A(x1,x2) = max{x1 - 32, x2 + 1} app#!_A(x1,x2) = 28 filter_1!_A(x1) = max{30, x1 - 1} filter_2#!_A(x1,x2) = 28 cons_2!_A(x1,x2) = 4 map_1!_A(x1) = 10 map_2#!_A(x1,x2) = max{29, x1 - 1, x2 + 1} filter2_3!_A(x1,x2,x3) = max{29, x1 - 14, x2 + 7, x3 + 5} filter2_4#!_A(x1,x2,x3,x4) = 28 false_0!_A = 7 app!_A(x1,x2) = max{30, x1 - 4, x2 + 9} true_0!_A = 29 rev1_2!_A(x1,x2) = 4 |0|_0!_A = 5 nil_0!_A = 6 s_1!_A(x1) = 5 map_2!_A(x1,x2) = max{31, x1 - 1, x2 - 54} filter_2!_A(x1,x2) = 6 partial status: pi(app#) = [] pi(filter_1) = [] pi(filter_2#) = [] pi(cons_2) = [2] pi(map_1) = [] pi(map_2#) = [] pi(filter2_3) = [3] pi(filter2_4#) = [] pi(false_0) = [] pi(app) = [2] pi(true_0) = [] pi(rev1_2) = [2] pi(|0|_0) = [] pi(nil_0) = [] pi(s_1) = [] pi(map_2) = [2] pi(filter_2) = [] The following rules are removed: p3, p5, p6 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: app#(filter_1(x1),y) -> filter_2#(x1,y) p2: filter_2#(f,cons_2(x,xs)) -> app#(f,x) p3: map_2#(f,cons_2(x,xs)) -> map_2#(f,xs) p4: filter2_4#(false_0(),f,x,xs) -> filter_2#(f,xs) p5: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p6: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The estimated dependency graph contains the following SCCs: {p1, p2, p4, p5, p6} {p3} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: app#(filter_1(x1),y) -> filter_2#(x1,y) p2: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p3: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) p4: filter_2#(f,cons_2(x,xs)) -> app#(f,x) p5: filter2_4#(false_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17, r18, r19, r20, r21, r22, r23, r24, r25, r26, r27, r28, r29 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: app#_A(x1,x2) = max{0, x1 - 22, x2 - 43} filter_1_A(x1) = x1 + 9 filter_2#_A(x1,x2) = max{0, x1 - 22, x2 - 43} cons_2_A(x1,x2) = max{42, x1 + 9, x2} filter2_4#_A(x1,x2,x3,x4) = max{0, x1 - 65, x2 - 22, x3 - 34, x4 - 43} app_A(x1,x2) = max{44, x1 - 16, x2 + 31} true_0_A = 31 false_0_A = 0 cons_0_A = 9 cons_1_A(x1) = max{32, x1 + 25} filter_0_A = 9 filter_2_A(x1,x2) = max{44, x1 - 23, x2 + 1} filter2_0_A = 9 filter2_1_A(x1) = x1 + 31 filter2_2_A(x1,x2) = max{x1 + 15, x2 + 9} filter2_3_A(x1,x2,x3) = max{x1 - 1, x2 - 7, x3 + 25} filter2_4_A(x1,x2,x3,x4) = max{44, x1 - 45, x2 - 23, x3 + 9, x4 + 1} map_0_A = 9 map_1_A(x1) = x1 + 9 map_2_A(x1,x2) = max{41, x1 - 7, x2 + 31} rev_0_A = 9 rev_1_A(x1) = max{42, x1 - 44} rev1_0_A = 11 rev1_1_A(x1) = x1 + 9 rev1_2_A(x1,x2) = max{32, x2 - 144} rev2_0_A = 9 rev2_1_A(x1) = x1 + 9 rev2_2_A(x1,x2) = max{42, x1 - 35, x2 - 45} s_0_A = 9 s_1_A(x1) = 32 nil_0_A = 0 |0|_0_A = 8 app#!_A(x1,x2) = max{75, x1 + 68, x2 + 6} filter_1!_A(x1) = max{1, x1 - 49} filter_2#!_A(x1,x2) = max{76, x1 + 74, x2 - 3} cons_2!_A(x1,x2) = max{x1 + 7, x2 - 93} filter2_4#!_A(x1,x2,x3,x4) = max{76, x1 - 138, x2 + 74, x4 - 3} app!_A(x1,x2) = max{x1 - 10, x2 + 76} true_0!_A = 1 false_0!_A = 9 cons_0!_A = 1 cons_1!_A(x1) = max{8, x1 - 1} filter_0!_A = 2 filter_2!_A(x1,x2) = max{8, x1 - 48, x2 - 1} filter2_0!_A = 1 filter2_1!_A(x1) = max{2, x1 - 35} filter2_2!_A(x1,x2) = max{3, x1 - 34, x2 - 49} filter2_3!_A(x1,x2,x3) = max{4, x1 - 33, x2 - 48, x3 - 1} filter2_4!_A(x1,x2,x3,x4) = max{x1 - 32, x2 - 48, x3 + 8, x4 - 1} map_0!_A = 1 map_1!_A(x1) = max{37, x1 - 1} map_2!_A(x1,x2) = max{38, x1 - 2, x2 + 30} rev_0!_A = 1 rev_1!_A(x1) = max{40, x1 - 136} rev1_0!_A = 1 rev1_1!_A(x1) = max{0, x1 - 1} rev1_2!_A(x1,x2) = max{3, x2 - 137} rev2_0!_A = 75 rev2_1!_A(x1) = max{74, x1 - 3} rev2_2!_A(x1,x2) = max{75, x1 - 2, x2 - 50} s_0!_A = 1 s_1!_A(x1) = 2 nil_0!_A = 1 |0|_0!_A = 2 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: app#_A(x1,x2) = max{0, x1 - 15, x2 - 47} filter_1_A(x1) = max{14, x1 + 2} filter_2#_A(x1,x2) = max{0, x1 - 13, x2 - 47} cons_2_A(x1,x2) = max{46, x1 + 4, x2} filter2_4#_A(x1,x2,x3,x4) = max{0, x1 - 65, x2 - 13, x3 - 43, x4 - 47} app_A(x1,x2) = max{64, x1 - 18, x2 + 22} true_0_A = 0 false_0_A = 54 cons_0_A = 0 cons_1_A(x1) = x1 + 22 filter_0_A = 14 filter_2_A(x1,x2) = max{48, x1 - 23, x2 + 1} filter2_0_A = 14 filter2_1_A(x1) = max{14, x1 + 13} filter2_2_A(x1,x2) = max{14, x1 - 5, x2 + 13} filter2_3_A(x1,x2,x3) = max{x1 - 39, x2 - 5, x3 + 22} filter2_4_A(x1,x2,x3,x4) = max{48, x1 - 65, x2 - 23, x3 + 4, x4 + 1} map_0_A = 16 map_1_A(x1) = max{16, x1 + 13} map_2_A(x1,x2) = max{28, x1 - 14, x2 + 22} rev_0_A = 14 rev_1_A(x1) = max{1, x1} rev1_0_A = 17 rev1_1_A(x1) = 17 rev1_2_A(x1,x2) = max{23, x2 - 47} rev2_0_A = 14 rev2_1_A(x1) = x1 + 22 rev2_2_A(x1,x2) = max{44, x1 + 4, x2} s_0_A = 14 s_1_A(x1) = 23 nil_0_A = 2 |0|_0_A = 23 app#!_A(x1,x2) = max{0, x1 - 13, x2 - 43} filter_1!_A(x1) = max{45, x1 - 1} filter_2#!_A(x1,x2) = max{0, x1 - 12, x2 - 47} cons_2!_A(x1,x2) = max{x1 - 24, x2 + 12} filter2_4#!_A(x1,x2,x3,x4) = max{0, x1 - 66, x2 - 12, x3 - 44, x4 - 47} app!_A(x1,x2) = max{82, x1 - 15} true_0!_A = 61 false_0!_A = 45 cons_0!_A = 84 cons_1!_A(x1) = max{83, x1 - 25} filter_0!_A = 46 filter_2!_A(x1,x2) = max{44, x1 - 12, x2 - 3} filter2_0!_A = 84 filter2_1!_A(x1) = max{83, x1 - 2} filter2_2!_A(x1,x2) = max{84, x1 - 1, x2 + 1} filter2_3!_A(x1,x2,x3) = max{85, x1 - 53, x2 - 1, x3 - 2} filter2_4!_A(x1,x2,x3,x4) = max{44, x1 - 53, x2 - 12, x3 - 1, x4 - 3} map_0!_A = 1 map_1!_A(x1) = max{83, x1 - 2} map_2!_A(x1,x2) = max{84, x1 - 1, x2 + 35} rev_0!_A = 1 rev_1!_A(x1) = max{84, x1 - 71} rev1_0!_A = 2 rev1_1!_A(x1) = max{1, x1 - 42} rev1_2!_A(x1,x2) = max{85, x1 - 43, x2 - 47} rev2_0!_A = 2 rev2_1!_A(x1) = max{1, x1 - 24} rev2_2!_A(x1,x2) = max{83, x1 - 23, x2 - 72} s_0!_A = 38 s_1!_A(x1) = max{37, x1 - 21} nil_0!_A = 38 |0|_0!_A = 86 partial status: pi(app#) = [] pi(filter_1) = [1] pi(filter_2#) = [] pi(cons_2) = [] pi(filter2_4#) = [] pi(app) = [1, 2] pi(true_0) = [] pi(false_0) = [] pi(cons_0) = [] pi(cons_1) = [1] pi(filter_0) = [] pi(filter_2) = [1] pi(filter2_0) = [] pi(filter2_1) = [1] pi(filter2_2) = [1, 2] pi(filter2_3) = [2, 3] pi(filter2_4) = [2] pi(map_0) = [] pi(map_1) = [] pi(map_2) = [] pi(rev_0) = [] pi(rev_1) = [] pi(rev1_0) = [] pi(rev1_1) = [1] pi(rev1_2) = [] pi(rev2_0) = [] pi(rev2_1) = [1] pi(rev2_2) = [1, 2] pi(s_0) = [] pi(s_1) = [] pi(nil_0) = [] pi(|0|_0) = [] The following rules are removed: p1 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p2: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) p3: filter_2#(f,cons_2(x,xs)) -> app#(f,x) p4: filter2_4#(false_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The estimated dependency graph contains the following SCCs: {p1, p2, p4} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p2: filter2_4#(false_0(),f,x,xs) -> filter_2#(f,xs) p3: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12, r13, r14, r15, r16, r17, r18, r19, r20, r21, r22, r23, r24, r25, r26, r27, r28, r29 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: filter_2#_A(x1,x2) = max{0, x1 - 3, x2 - 12} cons_2_A(x1,x2) = max{9, x1 - 34, x2} filter2_4#_A(x1,x2,x3,x4) = max{0, x1 - 58, x2 - 3, x3 - 46, x4 - 12} app_A(x1,x2) = max{56, x1 - 9, x2 + 8} false_0_A = 57 true_0_A = 43 cons_0_A = 6 cons_1_A(x1) = max{6, x1 - 25} filter_0_A = 8 filter_1_A(x1) = x1 + 6 filter_2_A(x1,x2) = max{14, x1 - 12, x2 + 2} filter2_0_A = 6 filter2_1_A(x1) = x1 + 6 filter2_2_A(x1,x2) = max{x1 - 3, x2 + 6} filter2_3_A(x1,x2,x3) = max{x1 - 12, x2 - 3, x3 + 8} filter2_4_A(x1,x2,x3,x4) = max{14, x1 - 44, x2 - 12, x3 - 32, x4 + 2} map_0_A = 6 map_1_A(x1) = x1 + 6 map_2_A(x1,x2) = max{22, x1 - 3, x2 + 8} rev_0_A = 8 rev_1_A(x1) = max{23, x1 - 29} rev1_0_A = 6 rev1_1_A(x1) = x1 + 6 rev1_2_A(x1,x2) = max{32, x2 - 24} rev2_0_A = 6 rev2_1_A(x1) = x1 + 6 rev2_2_A(x1,x2) = max{23, x1 - 63, x2 - 30} s_0_A = 6 s_1_A(x1) = 29 nil_0_A = 23 |0|_0_A = 29 filter_2#!_A(x1,x2) = max{12, x1 - 8, x2 - 1} cons_2!_A(x1,x2) = 11 filter2_4#!_A(x1,x2,x3,x4) = max{12, x1 - 44, x2 - 8, x3 - 35, x4 - 1} app!_A(x1,x2) = max{x1 - 7, x2 + 17} false_0!_A = 17 true_0!_A = 1 cons_0!_A = 11 cons_1!_A(x1) = max{10, x1 - 32} filter_0!_A = 1 filter_1!_A(x1) = max{0, x1 - 1} filter_2!_A(x1,x2) = 16 filter2_0!_A = 13 filter2_1!_A(x1) = max{14, x1 - 9} filter2_2!_A(x1,x2) = max{16, x1 - 10, x2 - 3} filter2_3!_A(x1,x2,x3) = max{0, x1 - 11, x2 - 2, x3 - 1} filter2_4!_A(x1,x2,x3,x4) = 16 map_0!_A = 1 map_1!_A(x1) = max{16, x1 - 7} map_2!_A(x1,x2) = max{11, x1 - 6, x2 + 1} rev_0!_A = 1 rev_1!_A(x1) = max{12, x1 - 25} rev1_0!_A = 17 rev1_1!_A(x1) = x1 + 16 rev1_2!_A(x1,x2) = 10 rev2_0!_A = 1 rev2_1!_A(x1) = max{14, x1 - 58} rev2_2!_A(x1,x2) = max{13, x1 - 58, x2 - 24} s_0!_A = 0 s_1!_A(x1) = 0 nil_0!_A = 2 |0|_0!_A = 1 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: filter_2#_A(x1,x2) = max{1, x1 - 23} cons_2_A(x1,x2) = 13 filter2_4#_A(x1,x2,x3,x4) = max{1, x1 - 48, x2 - 23} app_A(x1,x2) = 26 false_0_A = 47 true_0_A = 0 cons_0_A = 2 cons_1_A(x1) = 2 filter_0_A = 4 filter_1_A(x1) = 4 filter_2_A(x1,x2) = 13 filter2_0_A = 2 filter2_1_A(x1) = 2 filter2_2_A(x1,x2) = 2 filter2_3_A(x1,x2,x3) = 2 filter2_4_A(x1,x2,x3,x4) = 13 map_0_A = 2 map_1_A(x1) = 4 map_2_A(x1,x2) = 18 rev_0_A = 2 rev_1_A(x1) = 13 rev1_0_A = 2 rev1_1_A(x1) = 4 rev1_2_A(x1,x2) = 26 rev2_0_A = 2 rev2_1_A(x1) = 1 rev2_2_A(x1,x2) = 26 s_0_A = 2 s_1_A(x1) = 1 nil_0_A = 13 |0|_0_A = 1 filter_2#!_A(x1,x2) = 5 cons_2!_A(x1,x2) = max{4, x2 - 14} filter2_4#!_A(x1,x2,x3,x4) = max{5, x1 - 41} app!_A(x1,x2) = max{6, x1 - 3, x2 + 1} false_0!_A = 9 true_0!_A = 9 cons_0!_A = 3 cons_1!_A(x1) = max{2, x1 - 1} filter_0!_A = 1 filter_1!_A(x1) = 7 filter_2!_A(x1,x2) = 8 filter2_0!_A = 3 filter2_1!_A(x1) = max{2, x1 - 41} filter2_2!_A(x1,x2) = max{7, x1 - 40, x2 - 1} filter2_3!_A(x1,x2,x3) = max{0, x1 - 39, x2 - 2, x3 - 1} filter2_4!_A(x1,x2,x3,x4) = max{5, x1 - 38} map_0!_A = 1 map_1!_A(x1) = max{0, x1 - 1} map_2!_A(x1,x2) = max{5, x1 - 2} rev_0!_A = 1 rev_1!_A(x1) = max{0, x1 - 14} rev1_0!_A = 8 rev1_1!_A(x1) = x1 + 38 rev1_2!_A(x1,x2) = 3 rev2_0!_A = 1 rev2_1!_A(x1) = 2 rev2_2!_A(x1,x2) = max{0, x1 - 2} s_0!_A = 1 s_1!_A(x1) = 2 nil_0!_A = 5 |0|_0!_A = 1 partial status: pi(filter_2#) = [1] pi(cons_2) = [] pi(filter2_4#) = [2] pi(app) = [] pi(false_0) = [] pi(true_0) = [] pi(cons_0) = [] pi(cons_1) = [] pi(filter_0) = [] pi(filter_1) = [] pi(filter_2) = [] pi(filter2_0) = [] pi(filter2_1) = [] pi(filter2_2) = [] pi(filter2_3) = [] pi(filter2_4) = [] pi(map_0) = [] pi(map_1) = [] pi(map_2) = [] pi(rev_0) = [] pi(rev_1) = [] pi(rev1_0) = [] pi(rev1_1) = [] pi(rev1_2) = [] pi(rev2_0) = [] pi(rev2_1) = [] pi(rev2_2) = [] pi(s_0) = [] pi(s_1) = [] pi(nil_0) = [] pi(|0|_0) = [] The following rules are removed: p2 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p2: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The estimated dependency graph contains the following SCCs: {p1, p2} -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) p2: filter2_4#(true_0(),f,x,xs) -> filter_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of r17, r19, r24, r26 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: filter_2#_A(x1,x2) = max{1, x1 - 1, x2 - 4} cons_2_A(x1,x2) = max{x1 - 27, x2 + 3} filter2_4#_A(x1,x2,x3,x4) = max{1, x2 - 1, x3 - 31, x4 - 1} app_A(x1,x2) = max{47, x1 - 7} true_0_A = 47 rev_1_A(x1) = max{67, x1 - 51} nil_0_A = 50 rev1_2_A(x1,x2) = 26 |0|_0_A = 26 map_2_A(x1,x2) = x2 + 18 filter_2_A(x1,x2) = max{49, x2 + 15} filter_2#!_A(x1,x2) = x2 + 30 cons_2!_A(x1,x2) = max{72, x1 + 25, x2 + 34} filter2_4#!_A(x1,x2,x3,x4) = max{33, x3 + 2, x4 + 31} app!_A(x1,x2) = max{x1 + 37, x2 + 109} true_0!_A = 38 rev_1!_A(x1) = 110 nil_0!_A = 37 rev1_2!_A(x1,x2) = x2 + 30 |0|_0!_A = 36 map_2!_A(x1,x2) = max{x1 + 36, x2 + 69} filter_2!_A(x1,x2) = max{x1 + 27, x2 + 66} 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: filter_2#_A(x1,x2) = max{1, x1 - 1, x2 - 5} cons_2_A(x1,x2) = max{4, x1 - 29, x2} filter2_4#_A(x1,x2,x3,x4) = max{1, x2 - 1, x3 - 34, x4 - 5} app_A(x1,x2) = max{x1 - 58, x2 + 31} true_0_A = 31 rev_1_A(x1) = max{32, x1 - 56} nil_0_A = 15 rev1_2_A(x1,x2) = max{28, x2 + 3} |0|_0_A = 28 map_2_A(x1,x2) = max{x1 - 17, x2 + 32} filter_2_A(x1,x2) = max{14, x1 - 94, x2 + 6} filter_2#!_A(x1,x2) = 0 cons_2!_A(x1,x2) = 0 filter2_4#!_A(x1,x2,x3,x4) = 0 app!_A(x1,x2) = max{x1 - 25, x2 + 30} true_0!_A = 1 rev_1!_A(x1) = max{11, x1 - 62} nil_0!_A = 9 rev1_2!_A(x1,x2) = 30 |0|_0!_A = 1 map_2!_A(x1,x2) = max{8, x1 - 24, x2 - 5} filter_2!_A(x1,x2) = 0 partial status: pi(filter_2#) = [] pi(cons_2) = [] pi(filter2_4#) = [] pi(app) = [2] pi(true_0) = [] pi(rev_1) = [1] pi(nil_0) = [] pi(rev1_2) = [] pi(|0|_0) = [] pi(map_2) = [] pi(filter_2) = [] The following rules are removed: p2 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: filter_2#(f,cons_2(x,xs)) -> filter2_4#(app(f,x),f,x,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The estimated dependency graph contains the following SCCs: (no SCCs) -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: map_2#(f,cons_2(x,xs)) -> map_2#(f,xs) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of (no rules) Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: map_2#_A(x1,x2) = 0 cons_2_A(x1,x2) = max{7, x1 - 21, x2 - 7} map_2#!_A(x1,x2) = max{1, x2 - 58} cons_2!_A(x1,x2) = max{3, x1 - 54, x2 - 57} 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: map_2#_A(x1,x2) = 0 cons_2_A(x1,x2) = max{4, x1 - 9, x2 - 4} map_2#!_A(x1,x2) = max{7, x1 - 1, x2 - 5} cons_2!_A(x1,x2) = max{6, x1 - 72, x2 - 43} partial status: pi(map_2#) = [2] pi(cons_2) = [2] The following rules are removed: p1 Then no dependency pair remains. -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: rev2_2#(x,cons_2(y,l)) -> rev_1#(cons_2(x,rev2_2(y,l))) p2: rev_1#(cons_2(x,l)) -> rev2_2#(x,l) p3: rev2_2#(x,cons_2(y,l)) -> rev2_2#(y,l) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of r17, r18, r19, r20, r21, r22, r23 Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: rev2_2#_A(x1,x2) = max{76, x2 + 1} cons_2_A(x1,x2) = max{74, x2 + 7} rev_1#_A(x1) = max{76, x1 + 1} rev2_2_A(x1,x2) = max{67, x2} rev_1_A(x1) = x1 nil_0_A = 78 rev1_2_A(x1,x2) = 3 |0|_0_A = 0 s_1_A(x1) = 0 rev2_2#!_A(x1,x2) = max{1, x2 - 4} cons_2!_A(x1,x2) = max{10, x1 - 4} rev_1#!_A(x1) = max{70, x1 - 5} rev2_2!_A(x1,x2) = max{83, x1} rev_1!_A(x1) = 0 nil_0!_A = 80 rev1_2!_A(x1,x2) = max{0, x2 - 75} |0|_0!_A = 3 s_1!_A(x1) = 2 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: rev2_2#_A(x1,x2) = max{15, x2 + 1} cons_2_A(x1,x2) = max{13, x2 + 8} rev_1#_A(x1) = max{15, x1} rev2_2_A(x1,x2) = max{5, x2} rev_1_A(x1) = max{12, x1} nil_0_A = 5 rev1_2_A(x1,x2) = max{0, x2 - 39} |0|_0_A = 0 s_1_A(x1) = 0 rev2_2#!_A(x1,x2) = max{7, x2 + 1} cons_2!_A(x1,x2) = max{x1 + 24, x2 + 16} rev_1#!_A(x1) = max{8, x1 + 1} rev2_2!_A(x1,x2) = max{x1 + 25, x2 + 9} rev_1!_A(x1) = 23 nil_0!_A = 25 rev1_2!_A(x1,x2) = x2 |0|_0!_A = 1 s_1!_A(x1) = max{35, x1 - 46} partial status: pi(rev2_2#) = [] pi(cons_2) = [] pi(rev_1#) = [] pi(rev2_2) = [1] pi(rev_1) = [1] pi(nil_0) = [] pi(rev1_2) = [] pi(|0|_0) = [] pi(s_1) = [] The following rules are removed: p2, p3 -- SCC decomposition. Consider the dependency pair problem (P, R), where P consists of p1: rev2_2#(x,cons_2(y,l)) -> rev_1#(cons_2(x,rev2_2(y,l))) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The estimated dependency graph contains the following SCCs: (no SCCs) -- Reduction pair. Consider the dependency pair problem (P, R), where P consists of p1: rev1_2#(x,cons_2(y,l)) -> rev1_2#(y,l) and R consists of: r1: app(cons_0(),y) -> cons_1(y) r2: app(cons_1(x1),y) -> cons_2(x1,y) r3: app(filter_0(),y) -> filter_1(y) r4: app(filter_1(x1),y) -> filter_2(x1,y) r5: app(filter2_0(),y) -> filter2_1(y) r6: app(filter2_1(x1),y) -> filter2_2(x1,y) r7: app(filter2_2(x1,x2),y) -> filter2_3(x1,x2,y) r8: app(filter2_3(x1,x2,x3),y) -> filter2_4(x1,x2,x3,y) r9: app(map_0(),y) -> map_1(y) r10: app(map_1(x1),y) -> map_2(x1,y) r11: app(rev_0(),y) -> rev_1(y) r12: app(rev1_0(),y) -> rev1_1(y) r13: app(rev1_1(x1),y) -> rev1_2(x1,y) r14: app(rev2_0(),y) -> rev2_1(y) r15: app(rev2_1(x1),y) -> rev2_2(x1,y) r16: app(s_0(),y) -> s_1(y) r17: rev_1(nil_0()) -> nil_0() r18: rev_1(cons_2(x,l)) -> cons_2(rev1_2(x,l),rev2_2(x,l)) r19: rev1_2(|0|_0(),nil_0()) -> |0|_0() r20: rev1_2(s_1(x),nil_0()) -> s_1(x) r21: rev1_2(x,cons_2(y,l)) -> rev1_2(y,l) r22: rev2_2(x,nil_0()) -> nil_0() r23: rev2_2(x,cons_2(y,l)) -> rev_1(cons_2(x,rev2_2(y,l))) r24: map_2(f,nil_0()) -> nil_0() r25: map_2(f,cons_2(x,xs)) -> cons_2(app(f,x),map_2(f,xs)) r26: filter_2(f,nil_0()) -> nil_0() r27: filter_2(f,cons_2(x,xs)) -> filter2_4(app(f,x),f,x,xs) r28: filter2_4(true_0(),f,x,xs) -> cons_2(x,filter_2(f,xs)) r29: filter2_4(false_0(),f,x,xs) -> filter_2(f,xs) The set of usable rules consists of (no rules) Take the reduction pair: generalized weighted path order (>=MG, >G) base order 1: trivial reduction triple (T x T, T x T, Φ) base order 2: lexicographic combination of reduction triples: 1. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: rev1_2#_A(x1,x2) = 0 cons_2_A(x1,x2) = max{4, x1 - 4, x2 - 4} rev1_2#!_A(x1,x2) = max{3, x1 - 36, x2 - 43} cons_2!_A(x1,x2) = max{3, x1 - 36, x2 - 42} 2. marked-algebra reduction triple (>=A, >=A!, >A!): max/plus interpretation on natural numbers: rev1_2#_A(x1,x2) = 0 cons_2_A(x1,x2) = max{15, x1 - 21, x2 - 16} rev1_2#!_A(x1,x2) = max{4, x1 - 73, x2 - 53} cons_2!_A(x1,x2) = max{4, x1 - 72, x2 - 16} partial status: pi(rev1_2#) = [2] pi(cons_2) = [2] The following rules are removed: p1 Then no dependency pair remains.