YES Problem: is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() hd(cons(x,l)) -> x tl(cons(x,l)) -> l append(l1,l2) -> ifappend(l1,l2,is_empty(l1)) ifappend(l1,l2,true()) -> l2 ifappend(l1,l2,false()) -> cons(hd(l1),append(tl(l1),l2)) Proof: DP Processor: DPs: append#(l1,l2) -> is_empty#(l1) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) ifappend#(l1,l2,false()) -> tl#(l1) ifappend#(l1,l2,false()) -> append#(tl(l1),l2) ifappend#(l1,l2,false()) -> hd#(l1) TRS: is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() hd(cons(x,l)) -> x tl(cons(x,l)) -> l append(l1,l2) -> ifappend(l1,l2,is_empty(l1)) ifappend(l1,l2,true()) -> l2 ifappend(l1,l2,false()) -> cons(hd(l1),append(tl(l1),l2)) TDG Processor: DPs: append#(l1,l2) -> is_empty#(l1) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) ifappend#(l1,l2,false()) -> tl#(l1) ifappend#(l1,l2,false()) -> append#(tl(l1),l2) ifappend#(l1,l2,false()) -> hd#(l1) TRS: is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() hd(cons(x,l)) -> x tl(cons(x,l)) -> l append(l1,l2) -> ifappend(l1,l2,is_empty(l1)) ifappend(l1,l2,true()) -> l2 ifappend(l1,l2,false()) -> cons(hd(l1),append(tl(l1),l2)) graph: ifappend#(l1,l2,false()) -> append#(tl(l1),l2) -> append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) ifappend#(l1,l2,false()) -> append#(tl(l1),l2) -> append#(l1,l2) -> is_empty#(l1) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) -> ifappend#(l1,l2,false()) -> hd#(l1) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) -> ifappend#(l1,l2,false()) -> append#(tl(l1),l2) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) -> ifappend#(l1,l2,false()) -> tl#(l1) SCC Processor: #sccs: 1 #rules: 2 #arcs: 5/25 DPs: ifappend#(l1,l2,false()) -> append#(tl(l1),l2) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) TRS: is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() hd(cons(x,l)) -> x tl(cons(x,l)) -> l append(l1,l2) -> ifappend(l1,l2,is_empty(l1)) ifappend(l1,l2,true()) -> l2 ifappend(l1,l2,false()) -> cons(hd(l1),append(tl(l1),l2)) Usable Rule Processor: DPs: ifappend#(l1,l2,false()) -> append#(tl(l1),l2) append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) TRS: tl(cons(x,l)) -> l is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() Arctic Interpretation Processor: dimension: 1 usable rules: tl(cons(x,l)) -> l is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() interpretation: [ifappend#](x0, x1, x2) = x0 + 1x2 + 0, [append#](x0, x1) = 1x0 + 1, [tl](x0) = -9x0 + 0, [false] = 3, [cons](x0, x1) = x0 + 10x1 + 5, [true] = 0, [is_empty](x0) = x0 + 0, [nil] = 0 orientation: ifappend#(l1,l2,false()) = l1 + 4 >= -8l1 + 1 = append#(tl(l1),l2) append#(l1,l2) = 1l1 + 1 >= 1l1 + 1 = ifappend#(l1,l2,is_empty(l1)) tl(cons(x,l)) = 1l + -9x + 0 >= l = l is_empty(nil()) = 0 >= 0 = true() is_empty(cons(x,l)) = 10l + x + 5 >= 3 = false() problem: DPs: append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) TRS: tl(cons(x,l)) -> l is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() Restore Modifier: DPs: append#(l1,l2) -> ifappend#(l1,l2,is_empty(l1)) TRS: is_empty(nil()) -> true() is_empty(cons(x,l)) -> false() hd(cons(x,l)) -> x tl(cons(x,l)) -> l append(l1,l2) -> ifappend(l1,l2,is_empty(l1)) ifappend(l1,l2,true()) -> l2 ifappend(l1,l2,false()) -> cons(hd(l1),append(tl(l1),l2)) SCC Processor: #sccs: 0 #rules: 0 #arcs: 2/1