* Step 1: Sum WORST_CASE(Omega(n^1),O(n^2)) + Considered Problem: - Strict TRS: domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: Sum {left = someStrategy, right = someStrategy} + Details: () ** Step 1.a:1: DecreasingLoops WORST_CASE(Omega(n^1),?) + Considered Problem: - Strict TRS: domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: DecreasingLoops {bound = AnyLoop, narrow = 10} + Details: The system has following decreasing Loops: prefix(y,u){y -> Cons(x,y),u -> Cons(z,u)} = prefix(Cons(x,y),Cons(z,u)) ->^+ and(!EQ(x,z),prefix(y,u)) = C[prefix(y,u) = prefix(y,u){}] ** Step 1.b:1: WeightGap WORST_CASE(?,O(n^2)) + Considered Problem: - Strict TRS: domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny} + Details: The weightgap principle applies using the following nonconstant growth matrix-interpretation: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(Cons) = {2}, uargs(and) = {1,2}, uargs(domatch[Ite]) = {1}, uargs(eqNatList[Ite]) = {1} Following symbols are considered usable: all TcT has computed the following interpretation: p(!EQ) = [4] p(0) = [4] p(Cons) = [1] x2 + [1] p(False) = [0] p(Nil) = [2] p(S) = [0] p(True) = [4] p(and) = [1] x1 + [1] x2 + [1] p(domatch) = [1] x2 + [2] x3 + [0] p(domatch[Ite]) = [1] x1 + [1] x3 + [7] p(eqNatList) = [4] x2 + [0] p(eqNatList[Ite]) = [1] x1 + [4] x3 + [1] p(notEmpty) = [1] x1 + [0] p(prefix) = [4] p(strmatch) = [2] x1 + [2] x2 + [1] Following rules are strictly oriented: eqNatList(Cons(x,xs),Nil()) = [8] > [0] = False() eqNatList(Nil(),Cons(y,ys)) = [4] ys + [4] > [0] = False() eqNatList(Nil(),Nil()) = [8] > [4] = True() notEmpty(Nil()) = [2] > [0] = False() prefix(Cons(x,xs),Nil()) = [4] > [0] = False() Following rules are (at-least) weakly oriented: !EQ(0(),0()) = [4] >= [4] = True() !EQ(0(),S(y)) = [4] >= [0] = False() !EQ(S(x),0()) = [4] >= [0] = False() !EQ(S(x),S(y)) = [4] >= [4] = !EQ(x,y) and(False(),False()) = [1] >= [0] = False() and(False(),True()) = [5] >= [0] = False() and(True(),False()) = [5] >= [0] = False() and(True(),True()) = [9] >= [4] = True() domatch(patcs,Cons(x,xs),n) = [2] n + [1] xs + [1] >= [1] xs + [12] = domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) = [2] n + [2] >= [2] = Nil() domatch(Nil(),Nil(),n) = [2] n + [2] >= [3] = Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) = [1] xs + [8] >= [1] xs + [8] = domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) = [1] xs + [12] >= [1] xs + [9] = Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) = [4] ys + [4] >= [4] ys + [5] = eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList[Ite](False(),y,ys,x,xs) = [4] ys + [1] >= [0] = False() eqNatList[Ite](True(),y,ys,x,xs) = [4] ys + [5] >= [4] ys + [0] = eqNatList(xs,ys) notEmpty(Cons(x,xs)) = [1] xs + [1] >= [4] = True() prefix(Cons(x',xs'),Cons(x,xs)) = [4] >= [9] = and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) = [4] >= [4] = True() strmatch(patstr,str) = [2] patstr + [2] str + [1] >= [1] str + [4] = domatch(patstr,str,Nil()) Further, it can be verified that all rules not oriented are covered by the weightgap condition. ** Step 1.b:2: WeightGap WORST_CASE(?,O(n^2)) + Considered Problem: - Strict TRS: domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) notEmpty(Cons(x,xs)) -> True() prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny} + Details: The weightgap principle applies using the following nonconstant growth matrix-interpretation: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(Cons) = {2}, uargs(and) = {1,2}, uargs(domatch[Ite]) = {1}, uargs(eqNatList[Ite]) = {1} Following symbols are considered usable: all TcT has computed the following interpretation: p(!EQ) = [0] p(0) = [0] p(Cons) = [1] x2 + [0] p(False) = [0] p(Nil) = [2] p(S) = [1] x1 + [0] p(True) = [0] p(and) = [1] x1 + [1] x2 + [0] p(domatch) = [2] x1 + [3] x2 + [3] p(domatch[Ite]) = [1] x1 + [2] x2 + [3] x3 + [3] p(eqNatList) = [4] x1 + [1] p(eqNatList[Ite]) = [1] x1 + [4] x5 + [6] p(notEmpty) = [1] p(prefix) = [5] p(strmatch) = [4] x1 + [4] x2 + [0] Following rules are strictly oriented: domatch(Cons(x,xs),Nil(),n) = [2] xs + [9] > [2] = Nil() domatch(Nil(),Nil(),n) = [13] > [2] = Cons(n,Nil()) notEmpty(Cons(x,xs)) = [1] > [0] = True() prefix(Nil(),cs) = [5] > [0] = True() Following rules are (at-least) weakly oriented: !EQ(0(),0()) = [0] >= [0] = True() !EQ(0(),S(y)) = [0] >= [0] = False() !EQ(S(x),0()) = [0] >= [0] = False() !EQ(S(x),S(y)) = [0] >= [0] = !EQ(x,y) and(False(),False()) = [0] >= [0] = False() and(False(),True()) = [0] >= [0] = False() and(True(),False()) = [0] >= [0] = False() and(True(),True()) = [0] >= [0] = True() domatch(patcs,Cons(x,xs),n) = [2] patcs + [3] xs + [3] >= [2] patcs + [3] xs + [8] = domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch[Ite](False(),patcs,Cons(x,xs),n) = [2] patcs + [3] xs + [3] >= [2] patcs + [3] xs + [3] = domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) = [2] patcs + [3] xs + [3] >= [2] patcs + [3] xs + [3] = Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) = [4] xs + [1] >= [4] xs + [6] = eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) = [4] xs + [1] >= [0] = False() eqNatList(Nil(),Cons(y,ys)) = [9] >= [0] = False() eqNatList(Nil(),Nil()) = [9] >= [0] = True() eqNatList[Ite](False(),y,ys,x,xs) = [4] xs + [6] >= [0] = False() eqNatList[Ite](True(),y,ys,x,xs) = [4] xs + [6] >= [4] xs + [1] = eqNatList(xs,ys) notEmpty(Nil()) = [1] >= [0] = False() prefix(Cons(x,xs),Nil()) = [5] >= [0] = False() prefix(Cons(x',xs'),Cons(x,xs)) = [5] >= [5] = and(!EQ(x',x),prefix(xs',xs)) strmatch(patstr,str) = [4] patstr + [4] str + [0] >= [2] patstr + [3] str + [3] = domatch(patstr,str,Nil()) Further, it can be verified that all rules not oriented are covered by the weightgap condition. ** Step 1.b:3: WeightGap WORST_CASE(?,O(n^2)) + Considered Problem: - Strict TRS: domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Nil(),cs) -> True() - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny} + Details: The weightgap principle applies using the following nonconstant growth matrix-interpretation: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(Cons) = {2}, uargs(and) = {1,2}, uargs(domatch[Ite]) = {1}, uargs(eqNatList[Ite]) = {1} Following symbols are considered usable: all TcT has computed the following interpretation: p(!EQ) = [0] p(0) = [0] p(Cons) = [1] x2 + [1] p(False) = [0] p(Nil) = [1] p(S) = [1] x1 + [0] p(True) = [0] p(and) = [1] x1 + [1] x2 + [2] p(domatch) = [4] x1 + [0] p(domatch[Ite]) = [1] x1 + [4] x2 + [1] p(eqNatList) = [4] x1 + [3] x2 + [0] p(eqNatList[Ite]) = [1] x1 + [3] x3 + [4] x5 + [1] p(notEmpty) = [0] p(prefix) = [5] p(strmatch) = [4] x1 + [1] x2 + [4] Following rules are strictly oriented: eqNatList(Cons(x,xs),Cons(y,ys)) = [4] xs + [3] ys + [7] > [4] xs + [3] ys + [1] = eqNatList[Ite](!EQ(x,y),y,ys,x,xs) strmatch(patstr,str) = [4] patstr + [1] str + [4] > [4] patstr + [0] = domatch(patstr,str,Nil()) Following rules are (at-least) weakly oriented: !EQ(0(),0()) = [0] >= [0] = True() !EQ(0(),S(y)) = [0] >= [0] = False() !EQ(S(x),0()) = [0] >= [0] = False() !EQ(S(x),S(y)) = [0] >= [0] = !EQ(x,y) and(False(),False()) = [2] >= [0] = False() and(False(),True()) = [2] >= [0] = False() and(True(),False()) = [2] >= [0] = False() and(True(),True()) = [2] >= [0] = True() domatch(patcs,Cons(x,xs),n) = [4] patcs + [0] >= [4] patcs + [6] = domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) = [4] xs + [4] >= [1] = Nil() domatch(Nil(),Nil(),n) = [4] >= [2] = Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) = [4] patcs + [1] >= [4] patcs + [0] = domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) = [4] patcs + [1] >= [4] patcs + [1] = Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Nil()) = [4] xs + [7] >= [0] = False() eqNatList(Nil(),Cons(y,ys)) = [3] ys + [7] >= [0] = False() eqNatList(Nil(),Nil()) = [7] >= [0] = True() eqNatList[Ite](False(),y,ys,x,xs) = [4] xs + [3] ys + [1] >= [0] = False() eqNatList[Ite](True(),y,ys,x,xs) = [4] xs + [3] ys + [1] >= [4] xs + [3] ys + [0] = eqNatList(xs,ys) notEmpty(Cons(x,xs)) = [0] >= [0] = True() notEmpty(Nil()) = [0] >= [0] = False() prefix(Cons(x,xs),Nil()) = [5] >= [0] = False() prefix(Cons(x',xs'),Cons(x,xs)) = [5] >= [7] = and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) = [5] >= [0] = True() Further, it can be verified that all rules not oriented are covered by the weightgap condition. ** Step 1.b:4: WeightGap WORST_CASE(?,O(n^2)) + Considered Problem: - Strict TRS: domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny} + Details: The weightgap principle applies using the following nonconstant growth matrix-interpretation: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(Cons) = {2}, uargs(and) = {1,2}, uargs(domatch[Ite]) = {1}, uargs(eqNatList[Ite]) = {1} Following symbols are considered usable: all TcT has computed the following interpretation: p(!EQ) = [5] p(0) = [2] p(Cons) = [1] x2 + [2] p(False) = [0] p(Nil) = [1] p(S) = [0] p(True) = [0] p(and) = [1] x1 + [1] x2 + [4] p(domatch) = [2] x2 + [1] p(domatch[Ite]) = [1] x1 + [2] x3 + [0] p(eqNatList) = [1] x1 + [2] x2 + [3] p(eqNatList[Ite]) = [1] x1 + [2] x3 + [1] x5 + [4] p(notEmpty) = [0] p(prefix) = [0] p(strmatch) = [1] x1 + [4] x2 + [3] Following rules are strictly oriented: domatch(patcs,Cons(x,xs),n) = [2] xs + [5] > [2] xs + [4] = domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) Following rules are (at-least) weakly oriented: !EQ(0(),0()) = [5] >= [0] = True() !EQ(0(),S(y)) = [5] >= [0] = False() !EQ(S(x),0()) = [5] >= [0] = False() !EQ(S(x),S(y)) = [5] >= [5] = !EQ(x,y) and(False(),False()) = [4] >= [0] = False() and(False(),True()) = [4] >= [0] = False() and(True(),False()) = [4] >= [0] = False() and(True(),True()) = [4] >= [0] = True() domatch(Cons(x,xs),Nil(),n) = [3] >= [1] = Nil() domatch(Nil(),Nil(),n) = [3] >= [3] = Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) = [2] xs + [4] >= [2] xs + [1] = domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) = [2] xs + [4] >= [2] xs + [3] = Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) = [1] xs + [2] ys + [9] >= [1] xs + [2] ys + [9] = eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) = [1] xs + [7] >= [0] = False() eqNatList(Nil(),Cons(y,ys)) = [2] ys + [8] >= [0] = False() eqNatList(Nil(),Nil()) = [6] >= [0] = True() eqNatList[Ite](False(),y,ys,x,xs) = [1] xs + [2] ys + [4] >= [0] = False() eqNatList[Ite](True(),y,ys,x,xs) = [1] xs + [2] ys + [4] >= [1] xs + [2] ys + [3] = eqNatList(xs,ys) notEmpty(Cons(x,xs)) = [0] >= [0] = True() notEmpty(Nil()) = [0] >= [0] = False() prefix(Cons(x,xs),Nil()) = [0] >= [0] = False() prefix(Cons(x',xs'),Cons(x,xs)) = [0] >= [9] = and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) = [0] >= [0] = True() strmatch(patstr,str) = [1] patstr + [4] str + [3] >= [2] str + [1] = domatch(patstr,str,Nil()) Further, it can be verified that all rules not oriented are covered by the weightgap condition. ** Step 1.b:5: MI WORST_CASE(?,O(n^2)) + Considered Problem: - Strict TRS: prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: MI {miKind = MaximalMatrix (UpperTriangular (Multiplicity Nothing)), miDimension = 2, miUArgs = UArgs, miURules = URules, miSelector = Just any strict-rules} + Details: We apply a matrix interpretation of kind MaximalMatrix (UpperTriangular (Multiplicity Nothing)): The following argument positions are considered usable: uargs(Cons) = {2}, uargs(and) = {1,2}, uargs(domatch[Ite]) = {1}, uargs(eqNatList[Ite]) = {1} Following symbols are considered usable: {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite],notEmpty,prefix,strmatch} TcT has computed the following interpretation: p(!EQ) = [0] [1] p(0) = [1] [4] p(Cons) = [1 2] x_2 + [2] [0 1] [1] p(False) = [0] [0] p(Nil) = [2] [0] p(S) = [1 1] x_1 + [4] [0 0] [4] p(True) = [0] [0] p(and) = [4 0] x_1 + [1 0] x_2 + [0] [0 0] [0 0] [0] p(domatch) = [2 0] x_1 + [4 5] x_2 + [0 1] x_3 + [2] [0 0] [0 1] [0 0] [1] p(domatch[Ite]) = [2 0] x_1 + [2 0] x_2 + [4 0] x_3 + [0] [0 0] [0 0] [0 1] [1] p(eqNatList) = [0 0] x_1 + [4 0] x_2 + [0] [4 0] [3 1] [0] p(eqNatList[Ite]) = [1 1] x_1 + [4 1] x_3 + [0 0] x_5 + [7] [0 4] [3 4] [4 0] [6] p(notEmpty) = [1 2] x_1 + [4] [3 2] [1] p(prefix) = [0 1] x_2 + [0] [0 0] [4] p(strmatch) = [4 0] x_1 + [5 6] x_2 + [2] [0 0] [1 4] [1] Following rules are strictly oriented: prefix(Cons(x',xs'),Cons(x,xs)) = [0 1] xs + [1] [0 0] [4] > [0 1] xs + [0] [0 0] [0] = and(!EQ(x',x),prefix(xs',xs)) Following rules are (at-least) weakly oriented: !EQ(0(),0()) = [0] [1] >= [0] [0] = True() !EQ(0(),S(y)) = [0] [1] >= [0] [0] = False() !EQ(S(x),0()) = [0] [1] >= [0] [0] = False() !EQ(S(x),S(y)) = [0] [1] >= [0] [1] = !EQ(x,y) and(False(),False()) = [0] [0] >= [0] [0] = False() and(False(),True()) = [0] [0] >= [0] [0] = False() and(True(),False()) = [0] [0] >= [0] [0] = False() and(True(),True()) = [0] [0] >= [0] [0] = True() domatch(patcs,Cons(x,xs),n) = [0 1] n + [2 0] patcs + [4 13] xs + [15] [0 0] [0 0] [0 1] [2] >= [2 0] patcs + [4 10] xs + [10] [0 0] [0 1] [2] = domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) = [0 1] n + [2 4] xs + [14] [0 0] [0 0] [1] >= [2] [0] = Nil() domatch(Nil(),Nil(),n) = [0 1] n + [14] [0 0] [1] >= [4] [1] = Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) = [2 0] patcs + [4 8] xs + [8] [0 0] [0 1] [2] >= [2 0] patcs + [4 5] xs + [4] [0 0] [0 1] [1] = domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) = [2 0] patcs + [4 8] xs + [8] [0 0] [0 1] [2] >= [2 0] patcs + [4 7] xs + [8] [0 0] [0 1] [2] = Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) = [0 0] xs + [4 8] ys + [8] [4 8] [3 7] [15] >= [0 0] xs + [4 1] ys + [8] [4 0] [3 4] [10] = eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) = [0 0] xs + [8] [4 8] [14] >= [0] [0] = False() eqNatList(Nil(),Cons(y,ys)) = [4 8] ys + [8] [3 7] [15] >= [0] [0] = False() eqNatList(Nil(),Nil()) = [8] [14] >= [0] [0] = True() eqNatList[Ite](False(),y,ys,x,xs) = [0 0] xs + [4 1] ys + [7] [4 0] [3 4] [6] >= [0] [0] = False() eqNatList[Ite](True(),y,ys,x,xs) = [0 0] xs + [4 1] ys + [7] [4 0] [3 4] [6] >= [0 0] xs + [4 0] ys + [0] [4 0] [3 1] [0] = eqNatList(xs,ys) notEmpty(Cons(x,xs)) = [1 4] xs + [8] [3 8] [9] >= [0] [0] = True() notEmpty(Nil()) = [6] [7] >= [0] [0] = False() prefix(Cons(x,xs),Nil()) = [0] [4] >= [0] [0] = False() prefix(Nil(),cs) = [0 1] cs + [0] [0 0] [4] >= [0] [0] = True() strmatch(patstr,str) = [4 0] patstr + [5 6] str + [2] [0 0] [1 4] [1] >= [2 0] patstr + [4 5] str + [2] [0 0] [0 1] [1] = domatch(patstr,str,Nil()) ** Step 1.b:6: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak TRS: !EQ(0(),0()) -> True() !EQ(0(),S(y)) -> False() !EQ(S(x),0()) -> False() !EQ(S(x),S(y)) -> !EQ(x,y) and(False(),False()) -> False() and(False(),True()) -> False() and(True(),False()) -> False() and(True(),True()) -> True() domatch(patcs,Cons(x,xs),n) -> domatch[Ite](prefix(patcs,Cons(x,xs)),patcs,Cons(x,xs),n) domatch(Cons(x,xs),Nil(),n) -> Nil() domatch(Nil(),Nil(),n) -> Cons(n,Nil()) domatch[Ite](False(),patcs,Cons(x,xs),n) -> domatch(patcs,xs,Cons(n,Cons(Nil(),Nil()))) domatch[Ite](True(),patcs,Cons(x,xs),n) -> Cons(n,domatch(patcs,xs,Cons(n,Cons(Nil(),Nil())))) eqNatList(Cons(x,xs),Cons(y,ys)) -> eqNatList[Ite](!EQ(x,y),y,ys,x,xs) eqNatList(Cons(x,xs),Nil()) -> False() eqNatList(Nil(),Cons(y,ys)) -> False() eqNatList(Nil(),Nil()) -> True() eqNatList[Ite](False(),y,ys,x,xs) -> False() eqNatList[Ite](True(),y,ys,x,xs) -> eqNatList(xs,ys) notEmpty(Cons(x,xs)) -> True() notEmpty(Nil()) -> False() prefix(Cons(x,xs),Nil()) -> False() prefix(Cons(x',xs'),Cons(x,xs)) -> and(!EQ(x',x),prefix(xs',xs)) prefix(Nil(),cs) -> True() strmatch(patstr,str) -> domatch(patstr,str,Nil()) - Signature: {!EQ/2,and/2,domatch/3,domatch[Ite]/4,eqNatList/2,eqNatList[Ite]/5,notEmpty/1,prefix/2,strmatch/2} / {0/0 ,Cons/2,False/0,Nil/0,S/1,True/0} - Obligation: innermost runtime complexity wrt. defined symbols {!EQ,and,domatch,domatch[Ite],eqNatList,eqNatList[Ite] ,notEmpty,prefix,strmatch} and constructors {0,Cons,False,Nil,S,True} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). WORST_CASE(Omega(n^1),O(n^2))