WORST_CASE(?,O(n^4)) * Step 1: DependencyPairs WORST_CASE(?,O(n^4)) + Considered Problem: - Strict TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'natsub('0(),'0()) -> '0() 'natsub('0(),'s(y)) -> '0() 'natsub('s(x),'0()) -> 's(x) 'natsub('s(x),'s(y)) -> 'natsub(x,y) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) eratos(dd(x,xs)) -> dd(x,eratos(filter(x,xs))) eratos(nil()) -> nil() filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3} / {'0/0,'divByZero/0 ,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add,'and,'div,'divsub,'eq,'equal,'mod,'mult,'natadd ,'natdiv,'natdiv','natmult,'natsub,'negative,'positive,'pred,'sub,'succ,eratos,filter ,filter'} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: DependencyPairs {dpKind_ = DT} + Details: We add the following dependency tuples: Strict DPs 'add#('0(),y) -> c_1() 'add#('neg('s('0())),y) -> c_2('pred#(y)) 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'add#('pos('s('0())),y) -> c_4('succ#(y)) 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'and#('false(),'false()) -> c_6() 'and#('false(),'true()) -> c_7() 'and#('true(),'false()) -> c_8() 'and#('true(),'true()) -> c_9() 'div#('0(),'0()) -> c_10() 'div#('0(),'neg(y)) -> c_11() 'div#('0(),'pos(y)) -> c_12() 'div#('neg(x),'0()) -> c_13() 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'0()) -> c_16() 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 'divsub#('0(),'0()) -> c_19() 'divsub#('0(),'s(y)) -> c_20() 'divsub#('s(x),'0()) -> c_21() 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('0(),'0()) -> c_23() 'eq#('0(),'neg(y)) -> c_24() 'eq#('0(),'pos(y)) -> c_25() 'eq#('0(),'s(y)) -> c_26() 'eq#('neg(x),'0()) -> c_27() 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('neg(x),'pos(y)) -> c_29() 'eq#('pos(x),'0()) -> c_30() 'eq#('pos(x),'neg(y)) -> c_31() 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'0()) -> c_33() 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 'eq#(dd(x'1,x'2),nil()) -> c_36() 'eq#(nil(),dd(y'1,y'2)) -> c_37() 'eq#(nil(),nil()) -> c_38() 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('0(),'0()) -> c_41() 'mult#('0(),'neg(y)) -> c_42() 'mult#('0(),'pos(y)) -> c_43() 'mult#('neg(x),'0()) -> c_44() 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'0()) -> c_47() 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('0(),y) -> c_50() 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('0(),'0()) -> c_52() 'natdiv#('0(),'s(y)) -> c_53() 'natdiv#('s(x),'0()) -> c_54() 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv#('underflow(),y) -> c_56() 'natdiv'#('0(),y) -> c_57() 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natdiv'#('underflow(),y) -> c_59() 'natmult#('0(),y) -> c_60() 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('0(),'0()) -> c_62() 'natsub#('0(),'s(y)) -> c_63() 'natsub#('s(x),'0()) -> c_64() 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'negative#('0()) -> c_66() 'negative#('neg(x)) -> c_67() 'negative#('pos(x)) -> c_68() 'negative#('s(x)) -> c_69() 'positive#('0()) -> c_70() 'positive#('neg(x)) -> c_71() 'positive#('pos(x)) -> c_72() 'positive#('s(x)) -> c_73() 'pred#('0()) -> c_74() 'pred#('neg('s(x))) -> c_75() 'pred#('pos('s('0()))) -> c_76() 'pred#('pos('s('s(x)))) -> c_77() 'sub#(x,'0()) -> c_78() 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) 'succ#('0()) -> c_81() 'succ#('neg('s('0()))) -> c_82() 'succ#('neg('s('s(x)))) -> c_83() 'succ#('pos('s(x))) -> c_84() eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) eratos#(nil()) -> c_86() filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) filter#(p,nil()) -> c_88() filter'#('false(),x,xs) -> c_89() filter'#('true(),x,xs) -> c_90() Weak DPs and mark the set of starting terms. * Step 2: PredecessorEstimation WORST_CASE(?,O(n^4)) + Considered Problem: - Strict DPs: 'add#('0(),y) -> c_1() 'add#('neg('s('0())),y) -> c_2('pred#(y)) 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'add#('pos('s('0())),y) -> c_4('succ#(y)) 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'and#('false(),'false()) -> c_6() 'and#('false(),'true()) -> c_7() 'and#('true(),'false()) -> c_8() 'and#('true(),'true()) -> c_9() 'div#('0(),'0()) -> c_10() 'div#('0(),'neg(y)) -> c_11() 'div#('0(),'pos(y)) -> c_12() 'div#('neg(x),'0()) -> c_13() 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'0()) -> c_16() 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 'divsub#('0(),'0()) -> c_19() 'divsub#('0(),'s(y)) -> c_20() 'divsub#('s(x),'0()) -> c_21() 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('0(),'0()) -> c_23() 'eq#('0(),'neg(y)) -> c_24() 'eq#('0(),'pos(y)) -> c_25() 'eq#('0(),'s(y)) -> c_26() 'eq#('neg(x),'0()) -> c_27() 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('neg(x),'pos(y)) -> c_29() 'eq#('pos(x),'0()) -> c_30() 'eq#('pos(x),'neg(y)) -> c_31() 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'0()) -> c_33() 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 'eq#(dd(x'1,x'2),nil()) -> c_36() 'eq#(nil(),dd(y'1,y'2)) -> c_37() 'eq#(nil(),nil()) -> c_38() 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('0(),'0()) -> c_41() 'mult#('0(),'neg(y)) -> c_42() 'mult#('0(),'pos(y)) -> c_43() 'mult#('neg(x),'0()) -> c_44() 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'0()) -> c_47() 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('0(),y) -> c_50() 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('0(),'0()) -> c_52() 'natdiv#('0(),'s(y)) -> c_53() 'natdiv#('s(x),'0()) -> c_54() 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv#('underflow(),y) -> c_56() 'natdiv'#('0(),y) -> c_57() 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natdiv'#('underflow(),y) -> c_59() 'natmult#('0(),y) -> c_60() 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('0(),'0()) -> c_62() 'natsub#('0(),'s(y)) -> c_63() 'natsub#('s(x),'0()) -> c_64() 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'negative#('0()) -> c_66() 'negative#('neg(x)) -> c_67() 'negative#('pos(x)) -> c_68() 'negative#('s(x)) -> c_69() 'positive#('0()) -> c_70() 'positive#('neg(x)) -> c_71() 'positive#('pos(x)) -> c_72() 'positive#('s(x)) -> c_73() 'pred#('0()) -> c_74() 'pred#('neg('s(x))) -> c_75() 'pred#('pos('s('0()))) -> c_76() 'pred#('pos('s('s(x)))) -> c_77() 'sub#(x,'0()) -> c_78() 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) 'succ#('0()) -> c_81() 'succ#('neg('s('0()))) -> c_82() 'succ#('neg('s('s(x)))) -> c_83() 'succ#('pos('s(x))) -> c_84() eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) eratos#(nil()) -> c_86() filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) filter#(p,nil()) -> c_88() filter'#('false(),x,xs) -> c_89() filter'#('true(),x,xs) -> c_90() - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'natsub('0(),'0()) -> '0() 'natsub('0(),'s(y)) -> '0() 'natsub('s(x),'0()) -> 's(x) 'natsub('s(x),'s(y)) -> 'natsub(x,y) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) eratos(dd(x,xs)) -> dd(x,eratos(filter(x,xs))) eratos(nil()) -> nil() filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/2,c_4/1,c_5/2 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/2,c_15/2,c_16/0,c_17/2,c_18/2,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/3,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/4,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: PredecessorEstimation {onSelection = all simple predecessor estimation selector} + Details: We estimate the number of application of {1,6,7,8,9,10,11,12,13,16,19,20,21,23,24,25,26,27,29,30,31,33,36,37,38,41,42,43,44,47,50,52,53,54,56,57,59 ,60,62,63,64,66,67,68,69,70,71,72,73,74,75,76,77,78,81,82,83,84,86,88,89,90} by application of Pre({1,6,7,8,9,10,11,12,13,16,19,20,21,23,24,25,26,27,29,30,31,33,36,37,38,41,42,43,44,47,50,52,53,54,56 ,57,59,60,62,63,64,66,67,68,69,70,71,72,73,74,75,76,77,78,81,82,83,84,86,88,89,90}) = {2,3,4,5,14,15,17,18 ,22,28,32,34,35,39,40,45,46,48,49,51,55,58,61,65,79,80,85,87}. Here rules are labelled as follows: 1: 'add#('0(),y) -> c_1() 2: 'add#('neg('s('0())),y) -> c_2('pred#(y)) 3: 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 4: 'add#('pos('s('0())),y) -> c_4('succ#(y)) 5: 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 6: 'and#('false(),'false()) -> c_6() 7: 'and#('false(),'true()) -> c_7() 8: 'and#('true(),'false()) -> c_8() 9: 'and#('true(),'true()) -> c_9() 10: 'div#('0(),'0()) -> c_10() 11: 'div#('0(),'neg(y)) -> c_11() 12: 'div#('0(),'pos(y)) -> c_12() 13: 'div#('neg(x),'0()) -> c_13() 14: 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 15: 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 16: 'div#('pos(x),'0()) -> c_16() 17: 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 18: 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 19: 'divsub#('0(),'0()) -> c_19() 20: 'divsub#('0(),'s(y)) -> c_20() 21: 'divsub#('s(x),'0()) -> c_21() 22: 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 23: 'eq#('0(),'0()) -> c_23() 24: 'eq#('0(),'neg(y)) -> c_24() 25: 'eq#('0(),'pos(y)) -> c_25() 26: 'eq#('0(),'s(y)) -> c_26() 27: 'eq#('neg(x),'0()) -> c_27() 28: 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 29: 'eq#('neg(x),'pos(y)) -> c_29() 30: 'eq#('pos(x),'0()) -> c_30() 31: 'eq#('pos(x),'neg(y)) -> c_31() 32: 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 33: 'eq#('s(x),'0()) -> c_33() 34: 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 35: 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 36: 'eq#(dd(x'1,x'2),nil()) -> c_36() 37: 'eq#(nil(),dd(y'1,y'2)) -> c_37() 38: 'eq#(nil(),nil()) -> c_38() 39: 'equal#(x,y) -> c_39('eq#(x,y)) 40: 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 41: 'mult#('0(),'0()) -> c_41() 42: 'mult#('0(),'neg(y)) -> c_42() 43: 'mult#('0(),'pos(y)) -> c_43() 44: 'mult#('neg(x),'0()) -> c_44() 45: 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 46: 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 47: 'mult#('pos(x),'0()) -> c_47() 48: 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 49: 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 50: 'natadd#('0(),y) -> c_50() 51: 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 52: 'natdiv#('0(),'0()) -> c_52() 53: 'natdiv#('0(),'s(y)) -> c_53() 54: 'natdiv#('s(x),'0()) -> c_54() 55: 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 56: 'natdiv#('underflow(),y) -> c_56() 57: 'natdiv'#('0(),y) -> c_57() 58: 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 59: 'natdiv'#('underflow(),y) -> c_59() 60: 'natmult#('0(),y) -> c_60() 61: 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 62: 'natsub#('0(),'0()) -> c_62() 63: 'natsub#('0(),'s(y)) -> c_63() 64: 'natsub#('s(x),'0()) -> c_64() 65: 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 66: 'negative#('0()) -> c_66() 67: 'negative#('neg(x)) -> c_67() 68: 'negative#('pos(x)) -> c_68() 69: 'negative#('s(x)) -> c_69() 70: 'positive#('0()) -> c_70() 71: 'positive#('neg(x)) -> c_71() 72: 'positive#('pos(x)) -> c_72() 73: 'positive#('s(x)) -> c_73() 74: 'pred#('0()) -> c_74() 75: 'pred#('neg('s(x))) -> c_75() 76: 'pred#('pos('s('0()))) -> c_76() 77: 'pred#('pos('s('s(x)))) -> c_77() 78: 'sub#(x,'0()) -> c_78() 79: 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 80: 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) 81: 'succ#('0()) -> c_81() 82: 'succ#('neg('s('0()))) -> c_82() 83: 'succ#('neg('s('s(x)))) -> c_83() 84: 'succ#('pos('s(x))) -> c_84() 85: eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) 86: eratos#(nil()) -> c_86() 87: filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) 88: filter#(p,nil()) -> c_88() 89: filter'#('false(),x,xs) -> c_89() 90: filter'#('true(),x,xs) -> c_90() * Step 3: PredecessorEstimation WORST_CASE(?,O(n^4)) + Considered Problem: - Strict DPs: 'add#('neg('s('0())),y) -> c_2('pred#(y)) 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'add#('pos('s('0())),y) -> c_4('succ#(y)) 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) - Weak DPs: 'add#('0(),y) -> c_1() 'and#('false(),'false()) -> c_6() 'and#('false(),'true()) -> c_7() 'and#('true(),'false()) -> c_8() 'and#('true(),'true()) -> c_9() 'div#('0(),'0()) -> c_10() 'div#('0(),'neg(y)) -> c_11() 'div#('0(),'pos(y)) -> c_12() 'div#('neg(x),'0()) -> c_13() 'div#('pos(x),'0()) -> c_16() 'divsub#('0(),'0()) -> c_19() 'divsub#('0(),'s(y)) -> c_20() 'divsub#('s(x),'0()) -> c_21() 'eq#('0(),'0()) -> c_23() 'eq#('0(),'neg(y)) -> c_24() 'eq#('0(),'pos(y)) -> c_25() 'eq#('0(),'s(y)) -> c_26() 'eq#('neg(x),'0()) -> c_27() 'eq#('neg(x),'pos(y)) -> c_29() 'eq#('pos(x),'0()) -> c_30() 'eq#('pos(x),'neg(y)) -> c_31() 'eq#('s(x),'0()) -> c_33() 'eq#(dd(x'1,x'2),nil()) -> c_36() 'eq#(nil(),dd(y'1,y'2)) -> c_37() 'eq#(nil(),nil()) -> c_38() 'mult#('0(),'0()) -> c_41() 'mult#('0(),'neg(y)) -> c_42() 'mult#('0(),'pos(y)) -> c_43() 'mult#('neg(x),'0()) -> c_44() 'mult#('pos(x),'0()) -> c_47() 'natadd#('0(),y) -> c_50() 'natdiv#('0(),'0()) -> c_52() 'natdiv#('0(),'s(y)) -> c_53() 'natdiv#('s(x),'0()) -> c_54() 'natdiv#('underflow(),y) -> c_56() 'natdiv'#('0(),y) -> c_57() 'natdiv'#('underflow(),y) -> c_59() 'natmult#('0(),y) -> c_60() 'natsub#('0(),'0()) -> c_62() 'natsub#('0(),'s(y)) -> c_63() 'natsub#('s(x),'0()) -> c_64() 'negative#('0()) -> c_66() 'negative#('neg(x)) -> c_67() 'negative#('pos(x)) -> c_68() 'negative#('s(x)) -> c_69() 'positive#('0()) -> c_70() 'positive#('neg(x)) -> c_71() 'positive#('pos(x)) -> c_72() 'positive#('s(x)) -> c_73() 'pred#('0()) -> c_74() 'pred#('neg('s(x))) -> c_75() 'pred#('pos('s('0()))) -> c_76() 'pred#('pos('s('s(x)))) -> c_77() 'sub#(x,'0()) -> c_78() 'succ#('0()) -> c_81() 'succ#('neg('s('0()))) -> c_82() 'succ#('neg('s('s(x)))) -> c_83() 'succ#('pos('s(x))) -> c_84() eratos#(nil()) -> c_86() filter#(p,nil()) -> c_88() filter'#('false(),x,xs) -> c_89() filter'#('true(),x,xs) -> c_90() - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'natsub('0(),'0()) -> '0() 'natsub('0(),'s(y)) -> '0() 'natsub('s(x),'0()) -> 's(x) 'natsub('s(x),'s(y)) -> 'natsub(x,y) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) eratos(dd(x,xs)) -> dd(x,eratos(filter(x,xs))) eratos(nil()) -> nil() filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/2,c_4/1,c_5/2 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/2,c_15/2,c_16/0,c_17/2,c_18/2,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/3,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/4,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: PredecessorEstimation {onSelection = all simple predecessor estimation selector} + Details: We estimate the number of application of {1,3} by application of Pre({1,3}) = {2,4,25,26}. Here rules are labelled as follows: 1: 'add#('neg('s('0())),y) -> c_2('pred#(y)) 2: 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 3: 'add#('pos('s('0())),y) -> c_4('succ#(y)) 4: 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 5: 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 6: 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 7: 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 8: 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 9: 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 10: 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 11: 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 12: 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 13: 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 14: 'equal#(x,y) -> c_39('eq#(x,y)) 15: 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 16: 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 17: 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 18: 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 19: 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 20: 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 21: 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 22: 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 23: 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 24: 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 25: 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 26: 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) 27: eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) 28: filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) 29: 'add#('0(),y) -> c_1() 30: 'and#('false(),'false()) -> c_6() 31: 'and#('false(),'true()) -> c_7() 32: 'and#('true(),'false()) -> c_8() 33: 'and#('true(),'true()) -> c_9() 34: 'div#('0(),'0()) -> c_10() 35: 'div#('0(),'neg(y)) -> c_11() 36: 'div#('0(),'pos(y)) -> c_12() 37: 'div#('neg(x),'0()) -> c_13() 38: 'div#('pos(x),'0()) -> c_16() 39: 'divsub#('0(),'0()) -> c_19() 40: 'divsub#('0(),'s(y)) -> c_20() 41: 'divsub#('s(x),'0()) -> c_21() 42: 'eq#('0(),'0()) -> c_23() 43: 'eq#('0(),'neg(y)) -> c_24() 44: 'eq#('0(),'pos(y)) -> c_25() 45: 'eq#('0(),'s(y)) -> c_26() 46: 'eq#('neg(x),'0()) -> c_27() 47: 'eq#('neg(x),'pos(y)) -> c_29() 48: 'eq#('pos(x),'0()) -> c_30() 49: 'eq#('pos(x),'neg(y)) -> c_31() 50: 'eq#('s(x),'0()) -> c_33() 51: 'eq#(dd(x'1,x'2),nil()) -> c_36() 52: 'eq#(nil(),dd(y'1,y'2)) -> c_37() 53: 'eq#(nil(),nil()) -> c_38() 54: 'mult#('0(),'0()) -> c_41() 55: 'mult#('0(),'neg(y)) -> c_42() 56: 'mult#('0(),'pos(y)) -> c_43() 57: 'mult#('neg(x),'0()) -> c_44() 58: 'mult#('pos(x),'0()) -> c_47() 59: 'natadd#('0(),y) -> c_50() 60: 'natdiv#('0(),'0()) -> c_52() 61: 'natdiv#('0(),'s(y)) -> c_53() 62: 'natdiv#('s(x),'0()) -> c_54() 63: 'natdiv#('underflow(),y) -> c_56() 64: 'natdiv'#('0(),y) -> c_57() 65: 'natdiv'#('underflow(),y) -> c_59() 66: 'natmult#('0(),y) -> c_60() 67: 'natsub#('0(),'0()) -> c_62() 68: 'natsub#('0(),'s(y)) -> c_63() 69: 'natsub#('s(x),'0()) -> c_64() 70: 'negative#('0()) -> c_66() 71: 'negative#('neg(x)) -> c_67() 72: 'negative#('pos(x)) -> c_68() 73: 'negative#('s(x)) -> c_69() 74: 'positive#('0()) -> c_70() 75: 'positive#('neg(x)) -> c_71() 76: 'positive#('pos(x)) -> c_72() 77: 'positive#('s(x)) -> c_73() 78: 'pred#('0()) -> c_74() 79: 'pred#('neg('s(x))) -> c_75() 80: 'pred#('pos('s('0()))) -> c_76() 81: 'pred#('pos('s('s(x)))) -> c_77() 82: 'sub#(x,'0()) -> c_78() 83: 'succ#('0()) -> c_81() 84: 'succ#('neg('s('0()))) -> c_82() 85: 'succ#('neg('s('s(x)))) -> c_83() 86: 'succ#('pos('s(x))) -> c_84() 87: eratos#(nil()) -> c_86() 88: filter#(p,nil()) -> c_88() 89: filter'#('false(),x,xs) -> c_89() 90: filter'#('true(),x,xs) -> c_90() * Step 4: RemoveWeakSuffixes WORST_CASE(?,O(n^4)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) - Weak DPs: 'add#('0(),y) -> c_1() 'add#('neg('s('0())),y) -> c_2('pred#(y)) 'add#('pos('s('0())),y) -> c_4('succ#(y)) 'and#('false(),'false()) -> c_6() 'and#('false(),'true()) -> c_7() 'and#('true(),'false()) -> c_8() 'and#('true(),'true()) -> c_9() 'div#('0(),'0()) -> c_10() 'div#('0(),'neg(y)) -> c_11() 'div#('0(),'pos(y)) -> c_12() 'div#('neg(x),'0()) -> c_13() 'div#('pos(x),'0()) -> c_16() 'divsub#('0(),'0()) -> c_19() 'divsub#('0(),'s(y)) -> c_20() 'divsub#('s(x),'0()) -> c_21() 'eq#('0(),'0()) -> c_23() 'eq#('0(),'neg(y)) -> c_24() 'eq#('0(),'pos(y)) -> c_25() 'eq#('0(),'s(y)) -> c_26() 'eq#('neg(x),'0()) -> c_27() 'eq#('neg(x),'pos(y)) -> c_29() 'eq#('pos(x),'0()) -> c_30() 'eq#('pos(x),'neg(y)) -> c_31() 'eq#('s(x),'0()) -> c_33() 'eq#(dd(x'1,x'2),nil()) -> c_36() 'eq#(nil(),dd(y'1,y'2)) -> c_37() 'eq#(nil(),nil()) -> c_38() 'mult#('0(),'0()) -> c_41() 'mult#('0(),'neg(y)) -> c_42() 'mult#('0(),'pos(y)) -> c_43() 'mult#('neg(x),'0()) -> c_44() 'mult#('pos(x),'0()) -> c_47() 'natadd#('0(),y) -> c_50() 'natdiv#('0(),'0()) -> c_52() 'natdiv#('0(),'s(y)) -> c_53() 'natdiv#('s(x),'0()) -> c_54() 'natdiv#('underflow(),y) -> c_56() 'natdiv'#('0(),y) -> c_57() 'natdiv'#('underflow(),y) -> c_59() 'natmult#('0(),y) -> c_60() 'natsub#('0(),'0()) -> c_62() 'natsub#('0(),'s(y)) -> c_63() 'natsub#('s(x),'0()) -> c_64() 'negative#('0()) -> c_66() 'negative#('neg(x)) -> c_67() 'negative#('pos(x)) -> c_68() 'negative#('s(x)) -> c_69() 'positive#('0()) -> c_70() 'positive#('neg(x)) -> c_71() 'positive#('pos(x)) -> c_72() 'positive#('s(x)) -> c_73() 'pred#('0()) -> c_74() 'pred#('neg('s(x))) -> c_75() 'pred#('pos('s('0()))) -> c_76() 'pred#('pos('s('s(x)))) -> c_77() 'sub#(x,'0()) -> c_78() 'succ#('0()) -> c_81() 'succ#('neg('s('0()))) -> c_82() 'succ#('neg('s('s(x)))) -> c_83() 'succ#('pos('s(x))) -> c_84() eratos#(nil()) -> c_86() filter#(p,nil()) -> c_88() filter'#('false(),x,xs) -> c_89() filter'#('true(),x,xs) -> c_90() - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'natsub('0(),'0()) -> '0() 'natsub('0(),'s(y)) -> '0() 'natsub('s(x),'0()) -> 's(x) 'natsub('s(x),'s(y)) -> 'natsub(x,y) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) eratos(dd(x,xs)) -> dd(x,eratos(filter(x,xs))) eratos(nil()) -> nil() filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/2,c_4/1,c_5/2 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/2,c_15/2,c_16/0,c_17/2,c_18/2,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/3,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/4,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) -->_2 'add#('pos('s('0())),y) -> c_4('succ#(y)):29 -->_2 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 -->_1 'pred#('pos('s('s(x)))) -> c_77():81 -->_1 'pred#('pos('s('0()))) -> c_76():80 -->_1 'pred#('neg('s(x))) -> c_75():79 -->_1 'pred#('0()) -> c_74():78 2:S:'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) -->_2 'add#('pos('s('0())),y) -> c_4('succ#(y)):29 -->_1 'succ#('pos('s(x))) -> c_84():86 -->_1 'succ#('neg('s('s(x)))) -> c_83():85 -->_1 'succ#('neg('s('0()))) -> c_82():84 -->_1 'succ#('0()) -> c_81():83 -->_2 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 3:S:'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 -->_1 'positive#('s(x)) -> c_73():77 -->_1 'positive#('pos(x)) -> c_72():76 -->_1 'positive#('neg(x)) -> c_71():75 -->_1 'positive#('0()) -> c_70():74 -->_2 'natdiv#('underflow(),y) -> c_56():63 -->_2 'natdiv#('s(x),'0()) -> c_54():62 -->_2 'natdiv#('0(),'s(y)) -> c_53():61 -->_2 'natdiv#('0(),'0()) -> c_52():60 4:S:'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 -->_1 'negative#('s(x)) -> c_69():73 -->_1 'negative#('pos(x)) -> c_68():72 -->_1 'negative#('neg(x)) -> c_67():71 -->_1 'negative#('0()) -> c_66():70 -->_2 'natdiv#('underflow(),y) -> c_56():63 -->_2 'natdiv#('s(x),'0()) -> c_54():62 -->_2 'natdiv#('0(),'s(y)) -> c_53():61 -->_2 'natdiv#('0(),'0()) -> c_52():60 5:S:'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 -->_1 'negative#('s(x)) -> c_69():73 -->_1 'negative#('pos(x)) -> c_68():72 -->_1 'negative#('neg(x)) -> c_67():71 -->_1 'negative#('0()) -> c_66():70 -->_2 'natdiv#('underflow(),y) -> c_56():63 -->_2 'natdiv#('s(x),'0()) -> c_54():62 -->_2 'natdiv#('0(),'s(y)) -> c_53():61 -->_2 'natdiv#('0(),'0()) -> c_52():60 6:S:'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 -->_1 'positive#('s(x)) -> c_73():77 -->_1 'positive#('pos(x)) -> c_72():76 -->_1 'positive#('neg(x)) -> c_71():75 -->_1 'positive#('0()) -> c_70():74 -->_2 'natdiv#('underflow(),y) -> c_56():63 -->_2 'natdiv#('s(x),'0()) -> c_54():62 -->_2 'natdiv#('0(),'s(y)) -> c_53():61 -->_2 'natdiv#('0(),'0()) -> c_52():60 7:S:'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) -->_1 'divsub#('s(x),'0()) -> c_21():41 -->_1 'divsub#('0(),'s(y)) -> c_20():40 -->_1 'divsub#('0(),'0()) -> c_19():39 -->_1 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)):7 8:S:'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#(nil(),nil()) -> c_38():53 -->_1 'eq#(nil(),dd(y'1,y'2)) -> c_37():52 -->_1 'eq#(dd(x'1,x'2),nil()) -> c_36():51 -->_1 'eq#('s(x),'0()) -> c_33():50 -->_1 'eq#('pos(x),'neg(y)) -> c_31():49 -->_1 'eq#('pos(x),'0()) -> c_30():48 -->_1 'eq#('neg(x),'pos(y)) -> c_29():47 -->_1 'eq#('neg(x),'0()) -> c_27():46 -->_1 'eq#('0(),'s(y)) -> c_26():45 -->_1 'eq#('0(),'pos(y)) -> c_25():44 -->_1 'eq#('0(),'neg(y)) -> c_24():43 -->_1 'eq#('0(),'0()) -> c_23():42 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 9:S:'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#(nil(),nil()) -> c_38():53 -->_1 'eq#(nil(),dd(y'1,y'2)) -> c_37():52 -->_1 'eq#(dd(x'1,x'2),nil()) -> c_36():51 -->_1 'eq#('s(x),'0()) -> c_33():50 -->_1 'eq#('pos(x),'neg(y)) -> c_31():49 -->_1 'eq#('pos(x),'0()) -> c_30():48 -->_1 'eq#('neg(x),'pos(y)) -> c_29():47 -->_1 'eq#('neg(x),'0()) -> c_27():46 -->_1 'eq#('0(),'s(y)) -> c_26():45 -->_1 'eq#('0(),'pos(y)) -> c_25():44 -->_1 'eq#('0(),'neg(y)) -> c_24():43 -->_1 'eq#('0(),'0()) -> c_23():42 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 10:S:'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#(nil(),nil()) -> c_38():53 -->_1 'eq#(nil(),dd(y'1,y'2)) -> c_37():52 -->_1 'eq#(dd(x'1,x'2),nil()) -> c_36():51 -->_1 'eq#('s(x),'0()) -> c_33():50 -->_1 'eq#('pos(x),'neg(y)) -> c_31():49 -->_1 'eq#('pos(x),'0()) -> c_30():48 -->_1 'eq#('neg(x),'pos(y)) -> c_29():47 -->_1 'eq#('neg(x),'0()) -> c_27():46 -->_1 'eq#('0(),'s(y)) -> c_26():45 -->_1 'eq#('0(),'pos(y)) -> c_25():44 -->_1 'eq#('0(),'neg(y)) -> c_24():43 -->_1 'eq#('0(),'0()) -> c_23():42 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 11:S:'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) -->_3 'eq#(nil(),nil()) -> c_38():53 -->_2 'eq#(nil(),nil()) -> c_38():53 -->_3 'eq#(nil(),dd(y'1,y'2)) -> c_37():52 -->_2 'eq#(nil(),dd(y'1,y'2)) -> c_37():52 -->_3 'eq#(dd(x'1,x'2),nil()) -> c_36():51 -->_2 'eq#(dd(x'1,x'2),nil()) -> c_36():51 -->_3 'eq#('s(x),'0()) -> c_33():50 -->_2 'eq#('s(x),'0()) -> c_33():50 -->_3 'eq#('pos(x),'neg(y)) -> c_31():49 -->_2 'eq#('pos(x),'neg(y)) -> c_31():49 -->_3 'eq#('pos(x),'0()) -> c_30():48 -->_2 'eq#('pos(x),'0()) -> c_30():48 -->_3 'eq#('neg(x),'pos(y)) -> c_29():47 -->_2 'eq#('neg(x),'pos(y)) -> c_29():47 -->_3 'eq#('neg(x),'0()) -> c_27():46 -->_2 'eq#('neg(x),'0()) -> c_27():46 -->_3 'eq#('0(),'s(y)) -> c_26():45 -->_2 'eq#('0(),'s(y)) -> c_26():45 -->_3 'eq#('0(),'pos(y)) -> c_25():44 -->_2 'eq#('0(),'pos(y)) -> c_25():44 -->_3 'eq#('0(),'neg(y)) -> c_24():43 -->_2 'eq#('0(),'neg(y)) -> c_24():43 -->_3 'eq#('0(),'0()) -> c_23():42 -->_2 'eq#('0(),'0()) -> c_23():42 -->_1 'and#('true(),'true()) -> c_9():33 -->_1 'and#('true(),'false()) -> c_8():32 -->_1 'and#('false(),'true()) -> c_7():31 -->_1 'and#('false(),'false()) -> c_6():30 -->_3 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_2 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_3 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_2 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_3 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_2 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_3 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 -->_2 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 12:S:'equal#(x,y) -> c_39('eq#(x,y)) -->_1 'eq#(nil(),nil()) -> c_38():53 -->_1 'eq#(nil(),dd(y'1,y'2)) -> c_37():52 -->_1 'eq#(dd(x'1,x'2),nil()) -> c_36():51 -->_1 'eq#('s(x),'0()) -> c_33():50 -->_1 'eq#('pos(x),'neg(y)) -> c_31():49 -->_1 'eq#('pos(x),'0()) -> c_30():48 -->_1 'eq#('neg(x),'pos(y)) -> c_29():47 -->_1 'eq#('neg(x),'0()) -> c_27():46 -->_1 'eq#('0(),'s(y)) -> c_26():45 -->_1 'eq#('0(),'pos(y)) -> c_25():44 -->_1 'eq#('0(),'neg(y)) -> c_24():43 -->_1 'eq#('0(),'0()) -> c_23():42 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 13:S:'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) -->_1 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))):24 -->_1 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))):23 -->_2 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)):17 -->_2 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)):16 -->_2 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)):15 -->_2 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)):14 -->_1 'sub#(x,'0()) -> c_78():82 -->_2 'mult#('pos(x),'0()) -> c_47():58 -->_2 'mult#('neg(x),'0()) -> c_44():57 -->_2 'mult#('0(),'pos(y)) -> c_43():56 -->_2 'mult#('0(),'neg(y)) -> c_42():55 -->_2 'mult#('0(),'0()) -> c_41():54 -->_3 'div#('pos(x),'0()) -> c_16():38 -->_3 'div#('neg(x),'0()) -> c_13():37 -->_3 'div#('0(),'pos(y)) -> c_12():36 -->_3 'div#('0(),'neg(y)) -> c_11():35 -->_3 'div#('0(),'0()) -> c_10():34 -->_3 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)):6 -->_3 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)):5 -->_3 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)):4 -->_3 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)):3 14:S:'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 -->_1 'natmult#('0(),y) -> c_60():66 15:S:'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 -->_1 'natmult#('0(),y) -> c_60():66 16:S:'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 -->_1 'natmult#('0(),y) -> c_60():66 17:S:'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 -->_1 'natmult#('0(),y) -> c_60():66 18:S:'natadd#('s(x),y) -> c_51('natadd#(x,y)) -->_1 'natadd#('0(),y) -> c_50():59 -->_1 'natadd#('s(x),y) -> c_51('natadd#(x,y)):18 19:S:'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) -->_1 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)):20 -->_1 'natdiv'#('underflow(),y) -> c_59():65 -->_1 'natdiv'#('0(),y) -> c_57():64 -->_2 'divsub#('s(x),'0()) -> c_21():41 -->_2 'divsub#('0(),'s(y)) -> c_20():40 -->_2 'divsub#('0(),'0()) -> c_19():39 -->_2 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)):7 20:S:'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) -->_1 'natdiv#('s(x),'0()) -> c_54():62 -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 21:S:'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) -->_2 'natmult#('0(),y) -> c_60():66 -->_1 'natadd#('0(),y) -> c_50():59 -->_2 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 -->_1 'natadd#('s(x),y) -> c_51('natadd#(x,y)):18 22:S:'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) -->_1 'natsub#('s(x),'0()) -> c_64():69 -->_1 'natsub#('0(),'s(y)) -> c_63():68 -->_1 'natsub#('0(),'0()) -> c_62():67 -->_1 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)):22 23:S:'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) -->_1 'add#('pos('s('0())),y) -> c_4('succ#(y)):29 -->_1 'add#('neg('s('0())),y) -> c_2('pred#(y)):28 -->_1 'add#('0(),y) -> c_1():27 -->_1 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):1 24:S:'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) -->_1 'add#('pos('s('0())),y) -> c_4('succ#(y)):29 -->_1 'add#('neg('s('0())),y) -> c_2('pred#(y)):28 -->_1 'add#('0(),y) -> c_1():27 -->_1 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):1 25:S:eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) -->_2 filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)):26 -->_2 filter#(p,nil()) -> c_88():88 -->_1 eratos#(nil()) -> c_86():87 -->_1 eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)):25 26:S:filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) -->_1 filter'#('true(),x,xs) -> c_90():90 -->_1 filter'#('false(),x,xs) -> c_89():89 -->_4 filter#(p,nil()) -> c_88():88 -->_4 filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)):26 -->_3 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)):13 -->_2 'equal#(x,y) -> c_39('eq#(x,y)):12 27:W:'add#('0(),y) -> c_1() 28:W:'add#('neg('s('0())),y) -> c_2('pred#(y)) -->_1 'pred#('pos('s('s(x)))) -> c_77():81 -->_1 'pred#('pos('s('0()))) -> c_76():80 -->_1 'pred#('neg('s(x))) -> c_75():79 -->_1 'pred#('0()) -> c_74():78 29:W:'add#('pos('s('0())),y) -> c_4('succ#(y)) -->_1 'succ#('pos('s(x))) -> c_84():86 -->_1 'succ#('neg('s('s(x)))) -> c_83():85 -->_1 'succ#('neg('s('0()))) -> c_82():84 -->_1 'succ#('0()) -> c_81():83 30:W:'and#('false(),'false()) -> c_6() 31:W:'and#('false(),'true()) -> c_7() 32:W:'and#('true(),'false()) -> c_8() 33:W:'and#('true(),'true()) -> c_9() 34:W:'div#('0(),'0()) -> c_10() 35:W:'div#('0(),'neg(y)) -> c_11() 36:W:'div#('0(),'pos(y)) -> c_12() 37:W:'div#('neg(x),'0()) -> c_13() 38:W:'div#('pos(x),'0()) -> c_16() 39:W:'divsub#('0(),'0()) -> c_19() 40:W:'divsub#('0(),'s(y)) -> c_20() 41:W:'divsub#('s(x),'0()) -> c_21() 42:W:'eq#('0(),'0()) -> c_23() 43:W:'eq#('0(),'neg(y)) -> c_24() 44:W:'eq#('0(),'pos(y)) -> c_25() 45:W:'eq#('0(),'s(y)) -> c_26() 46:W:'eq#('neg(x),'0()) -> c_27() 47:W:'eq#('neg(x),'pos(y)) -> c_29() 48:W:'eq#('pos(x),'0()) -> c_30() 49:W:'eq#('pos(x),'neg(y)) -> c_31() 50:W:'eq#('s(x),'0()) -> c_33() 51:W:'eq#(dd(x'1,x'2),nil()) -> c_36() 52:W:'eq#(nil(),dd(y'1,y'2)) -> c_37() 53:W:'eq#(nil(),nil()) -> c_38() 54:W:'mult#('0(),'0()) -> c_41() 55:W:'mult#('0(),'neg(y)) -> c_42() 56:W:'mult#('0(),'pos(y)) -> c_43() 57:W:'mult#('neg(x),'0()) -> c_44() 58:W:'mult#('pos(x),'0()) -> c_47() 59:W:'natadd#('0(),y) -> c_50() 60:W:'natdiv#('0(),'0()) -> c_52() 61:W:'natdiv#('0(),'s(y)) -> c_53() 62:W:'natdiv#('s(x),'0()) -> c_54() 63:W:'natdiv#('underflow(),y) -> c_56() 64:W:'natdiv'#('0(),y) -> c_57() 65:W:'natdiv'#('underflow(),y) -> c_59() 66:W:'natmult#('0(),y) -> c_60() 67:W:'natsub#('0(),'0()) -> c_62() 68:W:'natsub#('0(),'s(y)) -> c_63() 69:W:'natsub#('s(x),'0()) -> c_64() 70:W:'negative#('0()) -> c_66() 71:W:'negative#('neg(x)) -> c_67() 72:W:'negative#('pos(x)) -> c_68() 73:W:'negative#('s(x)) -> c_69() 74:W:'positive#('0()) -> c_70() 75:W:'positive#('neg(x)) -> c_71() 76:W:'positive#('pos(x)) -> c_72() 77:W:'positive#('s(x)) -> c_73() 78:W:'pred#('0()) -> c_74() 79:W:'pred#('neg('s(x))) -> c_75() 80:W:'pred#('pos('s('0()))) -> c_76() 81:W:'pred#('pos('s('s(x)))) -> c_77() 82:W:'sub#(x,'0()) -> c_78() 83:W:'succ#('0()) -> c_81() 84:W:'succ#('neg('s('0()))) -> c_82() 85:W:'succ#('neg('s('s(x)))) -> c_83() 86:W:'succ#('pos('s(x))) -> c_84() 87:W:eratos#(nil()) -> c_86() 88:W:filter#(p,nil()) -> c_88() 89:W:filter'#('false(),x,xs) -> c_89() 90:W:filter'#('true(),x,xs) -> c_90() The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 87: eratos#(nil()) -> c_86() 88: filter#(p,nil()) -> c_88() 89: filter'#('false(),x,xs) -> c_89() 90: filter'#('true(),x,xs) -> c_90() 67: 'natsub#('0(),'0()) -> c_62() 68: 'natsub#('0(),'s(y)) -> c_63() 69: 'natsub#('s(x),'0()) -> c_64() 34: 'div#('0(),'0()) -> c_10() 35: 'div#('0(),'neg(y)) -> c_11() 36: 'div#('0(),'pos(y)) -> c_12() 37: 'div#('neg(x),'0()) -> c_13() 38: 'div#('pos(x),'0()) -> c_16() 54: 'mult#('0(),'0()) -> c_41() 55: 'mult#('0(),'neg(y)) -> c_42() 56: 'mult#('0(),'pos(y)) -> c_43() 57: 'mult#('neg(x),'0()) -> c_44() 58: 'mult#('pos(x),'0()) -> c_47() 82: 'sub#(x,'0()) -> c_78() 59: 'natadd#('0(),y) -> c_50() 66: 'natmult#('0(),y) -> c_60() 27: 'add#('0(),y) -> c_1() 28: 'add#('neg('s('0())),y) -> c_2('pred#(y)) 30: 'and#('false(),'false()) -> c_6() 31: 'and#('false(),'true()) -> c_7() 32: 'and#('true(),'false()) -> c_8() 33: 'and#('true(),'true()) -> c_9() 42: 'eq#('0(),'0()) -> c_23() 43: 'eq#('0(),'neg(y)) -> c_24() 44: 'eq#('0(),'pos(y)) -> c_25() 45: 'eq#('0(),'s(y)) -> c_26() 46: 'eq#('neg(x),'0()) -> c_27() 47: 'eq#('neg(x),'pos(y)) -> c_29() 48: 'eq#('pos(x),'0()) -> c_30() 49: 'eq#('pos(x),'neg(y)) -> c_31() 50: 'eq#('s(x),'0()) -> c_33() 51: 'eq#(dd(x'1,x'2),nil()) -> c_36() 52: 'eq#(nil(),dd(y'1,y'2)) -> c_37() 53: 'eq#(nil(),nil()) -> c_38() 70: 'negative#('0()) -> c_66() 71: 'negative#('neg(x)) -> c_67() 72: 'negative#('pos(x)) -> c_68() 73: 'negative#('s(x)) -> c_69() 60: 'natdiv#('0(),'0()) -> c_52() 61: 'natdiv#('0(),'s(y)) -> c_53() 63: 'natdiv#('underflow(),y) -> c_56() 74: 'positive#('0()) -> c_70() 75: 'positive#('neg(x)) -> c_71() 76: 'positive#('pos(x)) -> c_72() 77: 'positive#('s(x)) -> c_73() 39: 'divsub#('0(),'0()) -> c_19() 40: 'divsub#('0(),'s(y)) -> c_20() 41: 'divsub#('s(x),'0()) -> c_21() 64: 'natdiv'#('0(),y) -> c_57() 65: 'natdiv'#('underflow(),y) -> c_59() 62: 'natdiv#('s(x),'0()) -> c_54() 78: 'pred#('0()) -> c_74() 79: 'pred#('neg('s(x))) -> c_75() 80: 'pred#('pos('s('0()))) -> c_76() 81: 'pred#('pos('s('s(x)))) -> c_77() 29: 'add#('pos('s('0())),y) -> c_4('succ#(y)) 83: 'succ#('0()) -> c_81() 84: 'succ#('neg('s('0()))) -> c_82() 85: 'succ#('neg('s('s(x)))) -> c_83() 86: 'succ#('pos('s(x))) -> c_84() * Step 5: SimplifyRHS WORST_CASE(?,O(n^4)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'natsub('0(),'0()) -> '0() 'natsub('0(),'s(y)) -> '0() 'natsub('s(x),'0()) -> 's(x) 'natsub('s(x),'s(y)) -> 'natsub(x,y) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) eratos(dd(x,xs)) -> dd(x,eratos(filter(x,xs))) eratos(nil()) -> nil() filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/2,c_4/1,c_5/2 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/2,c_15/2,c_16/0,c_17/2,c_18/2,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/3,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/4,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) -->_2 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 2:S:'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)) -->_2 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 3:S:'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 4:S:'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 5:S:'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 6:S:'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)) -->_2 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 7:S:'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) -->_1 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)):7 8:S:'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 9:S:'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 10:S:'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 11:S:'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)),'eq#(x'1,y'1),'eq#(x'2,y'2)) -->_3 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_2 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_3 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_2 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_3 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_2 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_3 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 -->_2 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 12:S:'equal#(x,y) -> c_39('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('and#('eq(x'1,y'1),'eq(x'2,y'2)) ,'eq#(x'1,y'1) ,'eq#(x'2,y'2)):11 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):10 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):9 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):8 13:S:'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) -->_1 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))):24 -->_1 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))):23 -->_2 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)):17 -->_2 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)):16 -->_2 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)):15 -->_2 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)):14 -->_3 'div#('pos(x),'pos(y)) -> c_18('positive#('natdiv(x,y)),'natdiv#(x,y)):6 -->_3 'div#('pos(x),'neg(y)) -> c_17('negative#('natdiv(x,y)),'natdiv#(x,y)):5 -->_3 'div#('neg(x),'pos(y)) -> c_15('negative#('natdiv(x,y)),'natdiv#(x,y)):4 -->_3 'div#('neg(x),'neg(y)) -> c_14('positive#('natdiv(x,y)),'natdiv#(x,y)):3 14:S:'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 15:S:'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 16:S:'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 17:S:'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 18:S:'natadd#('s(x),y) -> c_51('natadd#(x,y)) -->_1 'natadd#('s(x),y) -> c_51('natadd#(x,y)):18 19:S:'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) -->_1 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)):20 -->_2 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)):7 20:S:'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):19 21:S:'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) -->_2 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):21 -->_1 'natadd#('s(x),y) -> c_51('natadd#(x,y)):18 22:S:'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) -->_1 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)):22 23:S:'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) -->_1 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):1 24:S:'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) -->_1 'add#('pos('s('s(x))),y) -> c_5('succ#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('pred#('add('pos('s(x)),y)),'add#('pos('s(x)),y)):1 25:S:eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) -->_2 filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)):26 -->_1 eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)):25 26:S:filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)) -->_4 filter#(p,dd(x,xs)) -> c_87(filter'#('equal('mod(x,p),'0()),x,filter(p,xs)) ,'equal#('mod(x,p),'0()) ,'mod#(x,p) ,filter#(p,xs)):26 -->_3 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)):13 -->_2 'equal#(x,y) -> c_39('eq#(x,y)):12 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) * Step 6: UsableRules WORST_CASE(?,O(n^4)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'natsub('0(),'0()) -> '0() 'natsub('0(),'s(y)) -> '0() 'natsub('s(x),'0()) -> 's(x) 'natsub('s(x),'s(y)) -> 'natsub(x,y) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) eratos(dd(x,xs)) -> dd(x,eratos(filter(x,xs))) eratos(nil()) -> nil() filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: UsableRules + Details: We replace rewrite rules by usable rules: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) * Step 7: DecomposeDG WORST_CASE(?,O(n^4)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: DecomposeDG {onSelection = all below first cut in WDG, onUpper = Nothing, onLower = Nothing} + Details: We decompose the input problem according to the dependency graph into the upper component 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) and a lower component 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) Further, following extension rules are added to the lower component. 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) ** Step 7.a:1: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) -->_1 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)):1 2:S:eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)) -->_1 eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs)),filter#(x,xs)):2 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs))) ** Step 7.a:2: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs))) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/1,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_65) = {1}, uargs(c_85) = {1} Following symbols are considered usable: {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub# ,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [2] x2 + [0] p('and) = [2] x1 + [5] p('div) = [1] x1 + [1] x2 + [2] p('divByZero) = [0] p('divsub) = [7] p('eq) = [1] x2 + [5] p('equal) = [1] x1 + [2] p('false) = [2] p('mod) = [2] x2 + [0] p('mult) = [2] x1 + [3] p('natadd) = [1] x2 + [1] p('natdiv) = [1] x1 + [2] x2 + [1] p('natdiv') = [1] x1 + [4] p('natmult) = [2] x2 + [5] p('natsub) = [4] p('neg) = [1] x1 + [2] p('negative) = [7] p('pos) = [1] x1 + [6] p('positive) = [1] x1 + [1] p('pred) = [0] p('s) = [1] x1 + [4] p('sub) = [1] x2 + [5] p('succ) = [0] p('true) = [3] p('underflow) = [2] p(dd) = [1] p(eratos) = [0] p(filter) = [4] x1 + [2] x2 + [3] p(filter') = [2] x3 + [3] p(nil) = [4] p('add#) = [0] p('and#) = [1] x1 + [0] p('div#) = [1] x1 + [0] p('divsub#) = [1] x1 + [0] p('eq#) = [1] x1 + [0] p('equal#) = [0] p('mod#) = [1] x1 + [0] p('mult#) = [1] x1 + [0] p('natadd#) = [4] x1 + [2] x2 + [0] p('natdiv#) = [4] x2 + [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [2] x1 + [1] x2 + [0] p('negative#) = [1] x1 + [0] p('positive#) = [1] x1 + [0] p('pred#) = [1] x1 + [0] p('sub#) = [0] p('succ#) = [0] p(eratos#) = [0] p(filter#) = [1] x2 + [0] p(filter'#) = [0] p(c_1) = [0] p(c_2) = [0] p(c_3) = [2] x1 + [0] p(c_4) = [0] p(c_5) = [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [0] p(c_14) = [0] p(c_15) = [0] p(c_16) = [0] p(c_17) = [0] p(c_18) = [0] p(c_19) = [0] p(c_20) = [0] p(c_21) = [0] p(c_22) = [4] x1 + [0] p(c_23) = [0] p(c_24) = [0] p(c_25) = [0] p(c_26) = [0] p(c_27) = [0] p(c_28) = [1] x1 + [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [0] p(c_32) = [2] x1 + [0] p(c_33) = [0] p(c_34) = [0] p(c_35) = [4] x1 + [1] x2 + [0] p(c_36) = [0] p(c_37) = [0] p(c_38) = [0] p(c_39) = [2] x1 + [0] p(c_40) = [2] x2 + [0] p(c_41) = [0] p(c_42) = [2] p(c_43) = [0] p(c_44) = [0] p(c_45) = [1] x1 + [0] p(c_46) = [4] x1 + [0] p(c_47) = [0] p(c_48) = [0] p(c_49) = [0] p(c_50) = [0] p(c_51) = [0] p(c_52) = [0] p(c_53) = [0] p(c_54) = [0] p(c_55) = [0] p(c_56) = [0] p(c_57) = [0] p(c_58) = [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [1] x1 + [0] p(c_62) = [0] p(c_63) = [0] p(c_64) = [0] p(c_65) = [1] x1 + [0] p(c_66) = [0] p(c_67) = [0] p(c_68) = [0] p(c_69) = [0] p(c_70) = [0] p(c_71) = [0] p(c_72) = [0] p(c_73) = [0] p(c_74) = [0] p(c_75) = [0] p(c_76) = [0] p(c_77) = [0] p(c_78) = [0] p(c_79) = [2] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [0] p(c_82) = [0] p(c_83) = [0] p(c_84) = [0] p(c_85) = [4] x1 + [0] p(c_86) = [0] p(c_87) = [1] x2 + [0] p(c_88) = [0] p(c_89) = [0] p(c_90) = [0] Following rules are strictly oriented: 'natsub#('s(x),'s(y)) = [2] x + [1] y + [12] > [2] x + [1] y + [0] = c_65('natsub#(x,y)) Following rules are (at-least) weakly oriented: eratos#(dd(x,xs)) = [0] >= [0] = c_85(eratos#(filter(x,xs))) ** Step 7.a:3: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs))) - Weak DPs: 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/1,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_65) = {1}, uargs(c_85) = {1} Following symbols are considered usable: {filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult# ,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [3] x2 + [1] p('and) = [3] x1 + [2] p('div) = [3] x2 + [0] p('divByZero) = [0] p('divsub) = [6] p('eq) = [0] p('equal) = [1] x1 + [0] p('false) = [0] p('mod) = [1] p('mult) = [3] x2 + [1] p('natadd) = [1] x2 + [3] p('natdiv) = [2] x2 + [4] p('natdiv') = [1] x1 + [0] p('natmult) = [2] p('natsub) = [0] p('neg) = [3] p('negative) = [2] x1 + [7] p('pos) = [1] x1 + [4] p('positive) = [0] p('pred) = [3] p('s) = [4] p('sub) = [4] p('succ) = [1] p('true) = [3] p('underflow) = [0] p(dd) = [1] x2 + [1] p(eratos) = [0] p(filter) = [1] x2 + [0] p(filter') = [1] x3 + [1] p(nil) = [0] p('add#) = [1] x2 + [0] p('and#) = [1] x2 + [0] p('div#) = [4] x1 + [0] p('divsub#) = [4] x2 + [0] p('eq#) = [2] x1 + [1] x2 + [0] p('equal#) = [1] x1 + [1] p('mod#) = [1] x2 + [0] p('mult#) = [1] x1 + [1] x2 + [0] p('natadd#) = [1] x2 + [0] p('natdiv#) = [1] x2 + [0] p('natdiv'#) = [4] x1 + [2] x2 + [0] p('natmult#) = [1] x1 + [0] p('natsub#) = [0] p('negative#) = [1] x1 + [0] p('positive#) = [0] p('pred#) = [1] x1 + [0] p('sub#) = [1] x1 + [0] p('succ#) = [0] p(eratos#) = [1] x1 + [0] p(filter#) = [0] p(filter'#) = [2] x1 + [1] x3 + [0] p(c_1) = [0] p(c_2) = [0] p(c_3) = [0] p(c_4) = [0] p(c_5) = [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [0] p(c_14) = [0] p(c_15) = [0] p(c_16) = [0] p(c_17) = [1] x1 + [0] p(c_18) = [4] x1 + [0] p(c_19) = [0] p(c_20) = [0] p(c_21) = [0] p(c_22) = [0] p(c_23) = [0] p(c_24) = [0] p(c_25) = [0] p(c_26) = [0] p(c_27) = [0] p(c_28) = [1] x1 + [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [0] p(c_32) = [0] p(c_33) = [0] p(c_34) = [0] p(c_35) = [1] x2 + [0] p(c_36) = [0] p(c_37) = [0] p(c_38) = [0] p(c_39) = [4] x1 + [0] p(c_40) = [1] x3 + [0] p(c_41) = [0] p(c_42) = [0] p(c_43) = [0] p(c_44) = [0] p(c_45) = [1] x1 + [0] p(c_46) = [0] p(c_47) = [0] p(c_48) = [0] p(c_49) = [0] p(c_50) = [0] p(c_51) = [0] p(c_52) = [0] p(c_53) = [0] p(c_54) = [0] p(c_55) = [1] x2 + [0] p(c_56) = [0] p(c_57) = [0] p(c_58) = [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [0] p(c_62) = [0] p(c_63) = [0] p(c_64) = [0] p(c_65) = [2] x1 + [0] p(c_66) = [0] p(c_67) = [0] p(c_68) = [0] p(c_69) = [0] p(c_70) = [0] p(c_71) = [0] p(c_72) = [0] p(c_73) = [0] p(c_74) = [0] p(c_75) = [0] p(c_76) = [0] p(c_77) = [0] p(c_78) = [0] p(c_79) = [1] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [0] p(c_82) = [2] p(c_83) = [0] p(c_84) = [0] p(c_85) = [1] x1 + [0] p(c_86) = [0] p(c_87) = [4] x1 + [1] x2 + [0] p(c_88) = [0] p(c_89) = [0] p(c_90) = [0] Following rules are strictly oriented: eratos#(dd(x,xs)) = [1] xs + [1] > [1] xs + [0] = c_85(eratos#(filter(x,xs))) Following rules are (at-least) weakly oriented: 'natsub#('s(x),'s(y)) = [0] >= [0] = c_65('natsub#(x,y)) filter(p,dd(x,xs)) = [1] xs + [1] >= [1] xs + [1] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [0] >= [0] = nil() filter'('false(),x,xs) = [1] xs + [1] >= [1] xs + [1] = dd(x,xs) filter'('true(),x,xs) = [1] xs + [1] >= [1] xs + [0] = xs ** Step 7.a:4: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: 'natsub#('s(x),'s(y)) -> c_65('natsub#(x,y)) eratos#(dd(x,xs)) -> c_85(eratos#(filter(x,xs))) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/1,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). ** Step 7.b:1: DecomposeDG WORST_CASE(?,O(n^3)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) - Weak DPs: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: DecomposeDG {onSelection = all below first cut in WDG, onUpper = Nothing, onLower = Nothing} + Details: We decompose the input problem according to the dependency graph into the upper component 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) and a lower component 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) Further, following extension rules are added to the lower component. 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) *** Step 7.b:1.a:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) - Weak DPs: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) -->_3 filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)):1 2:W:'natsub#('s(x),'s(y)) -> 'natsub#(x,y) -->_1 'natsub#('s(x),'s(y)) -> 'natsub#(x,y):2 3:W:eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) -->_1 eratos#(dd(x,xs)) -> filter#(x,xs):4 -->_1 eratos#(dd(x,xs)) -> eratos#(filter(x,xs)):3 4:W:eratos#(dd(x,xs)) -> filter#(x,xs) -->_1 filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)):1 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 2: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) *** Step 7.b:1.a:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) - Weak DPs: eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)) -->_3 filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)):1 3:W:eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) -->_1 eratos#(dd(x,xs)) -> filter#(x,xs):4 -->_1 eratos#(dd(x,xs)) -> eratos#(filter(x,xs)):3 4:W:eratos#(dd(x,xs)) -> filter#(x,xs) -->_1 filter#(p,dd(x,xs)) -> c_87('equal#('mod(x,p),'0()),'mod#(x,p),filter#(p,xs)):1 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: filter#(p,dd(x,xs)) -> c_87(filter#(p,xs)) *** Step 7.b:1.a:3: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: filter#(p,dd(x,xs)) -> c_87(filter#(p,xs)) - Weak DPs: eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/1,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_87) = {1} Following symbols are considered usable: {filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult# ,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [0] p('and) = [1] p('div) = [3] x1 + [4] x2 + [0] p('divByZero) = [0] p('divsub) = [1] p('eq) = [0] p('equal) = [1] x2 + [4] p('false) = [0] p('mod) = [0] p('mult) = [1] x2 + [3] p('natadd) = [2] p('natdiv) = [2] x1 + [2] p('natdiv') = [2] x1 + [1] x2 + [7] p('natmult) = [0] p('natsub) = [0] p('neg) = [1] x1 + [1] p('negative) = [0] p('pos) = [1] x1 + [0] p('positive) = [4] p('pred) = [6] p('s) = [1] x1 + [4] p('sub) = [1] x1 + [2] x2 + [2] p('succ) = [0] p('true) = [0] p('underflow) = [0] p(dd) = [1] x2 + [1] p(eratos) = [0] p(filter) = [1] x2 + [0] p(filter') = [1] x3 + [1] p(nil) = [0] p('add#) = [0] p('and#) = [0] p('div#) = [0] p('divsub#) = [0] p('eq#) = [0] p('equal#) = [0] p('mod#) = [0] p('mult#) = [0] p('natadd#) = [0] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [0] p('negative#) = [0] p('positive#) = [0] p('pred#) = [0] p('sub#) = [0] p('succ#) = [0] p(eratos#) = [1] x1 + [0] p(filter#) = [1] x2 + [0] p(filter'#) = [0] p(c_1) = [0] p(c_2) = [0] p(c_3) = [0] p(c_4) = [0] p(c_5) = [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [0] p(c_14) = [0] p(c_15) = [0] p(c_16) = [0] p(c_17) = [0] p(c_18) = [0] p(c_19) = [0] p(c_20) = [0] p(c_21) = [0] p(c_22) = [0] p(c_23) = [0] p(c_24) = [0] p(c_25) = [0] p(c_26) = [0] p(c_27) = [0] p(c_28) = [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [0] p(c_32) = [0] p(c_33) = [0] p(c_34) = [0] p(c_35) = [0] p(c_36) = [0] p(c_37) = [0] p(c_38) = [0] p(c_39) = [0] p(c_40) = [0] p(c_41) = [0] p(c_42) = [0] p(c_43) = [0] p(c_44) = [0] p(c_45) = [0] p(c_46) = [0] p(c_47) = [0] p(c_48) = [0] p(c_49) = [0] p(c_50) = [0] p(c_51) = [0] p(c_52) = [0] p(c_53) = [0] p(c_54) = [0] p(c_55) = [0] p(c_56) = [0] p(c_57) = [0] p(c_58) = [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [0] p(c_62) = [0] p(c_63) = [0] p(c_64) = [0] p(c_65) = [0] p(c_66) = [0] p(c_67) = [0] p(c_68) = [0] p(c_69) = [0] p(c_70) = [0] p(c_71) = [0] p(c_72) = [0] p(c_73) = [0] p(c_74) = [0] p(c_75) = [0] p(c_76) = [0] p(c_77) = [0] p(c_78) = [0] p(c_79) = [0] p(c_80) = [0] p(c_81) = [0] p(c_82) = [0] p(c_83) = [0] p(c_84) = [0] p(c_85) = [0] p(c_86) = [0] p(c_87) = [1] x1 + [0] p(c_88) = [0] p(c_89) = [0] p(c_90) = [0] Following rules are strictly oriented: filter#(p,dd(x,xs)) = [1] xs + [1] > [1] xs + [0] = c_87(filter#(p,xs)) Following rules are (at-least) weakly oriented: eratos#(dd(x,xs)) = [1] xs + [1] >= [1] xs + [0] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [1] xs + [1] >= [1] xs + [0] = filter#(x,xs) filter(p,dd(x,xs)) = [1] xs + [1] >= [1] xs + [1] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [0] >= [0] = nil() filter'('false(),x,xs) = [1] xs + [1] >= [1] xs + [1] = dd(x,xs) filter'('true(),x,xs) = [1] xs + [1] >= [1] xs + [0] = xs *** Step 7.b:1.a:4: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> c_87(filter#(p,xs)) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/1,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). *** Step 7.b:1.b:1: DecomposeDG WORST_CASE(?,O(n^2)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) - Weak DPs: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: DecomposeDG {onSelection = all below first cut in WDG, onUpper = Nothing, onLower = Nothing} + Details: We decompose the input problem according to the dependency graph into the upper component 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) and a lower component 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) Further, following extension rules are added to the lower component. 'add#('neg('s('s(x))),y) -> 'add#('pos('s(x)),y) 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y) 'div#('neg(x),'neg(y)) -> 'natdiv#(x,y) 'div#('neg(x),'pos(y)) -> 'natdiv#(x,y) 'div#('pos(x),'neg(y)) -> 'natdiv#(x,y) 'div#('pos(x),'pos(y)) -> 'natdiv#(x,y) 'eq#('neg(x),'neg(y)) -> 'eq#(x,y) 'eq#('pos(x),'pos(y)) -> 'eq#(x,y) 'eq#('s(x),'s(y)) -> 'eq#(x,y) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2) 'equal#(x,y) -> 'eq#(x,y) 'mod#(x,y) -> 'div#(x,y) 'mod#(x,y) -> 'mult#(y,'div(x,y)) 'mod#(x,y) -> 'sub#(x,'mult(y,'div(x,y))) 'mult#('neg(x),'neg(y)) -> 'natmult#(x,y) 'mult#('neg(x),'pos(y)) -> 'natmult#(x,y) 'mult#('pos(x),'neg(y)) -> 'natmult#(x,y) 'mult#('pos(x),'pos(y)) -> 'natmult#(x,y) 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y) 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) -> 'natdiv#('s(x),y) 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) -> 'natmult#(x,y) 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) 'sub#(x,'neg(y)) -> 'add#(x,'pos(y)) 'sub#(x,'pos(y)) -> 'add#(x,'neg(y)) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) **** Step 7.b:1.b:1.a:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) - Weak DPs: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 2:S:'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 3:S:'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 4:S:'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 5:S:'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 6:S:'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 7:S:'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 8:S:'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 9:S:'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 10:S:'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) -->_2 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_2 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_2 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_2 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 11:S:'equal#(x,y) -> c_39('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 12:S:'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) -->_1 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))):21 -->_1 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))):20 -->_2 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)):16 -->_2 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)):15 -->_2 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)):14 -->_2 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)):13 -->_3 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)):6 -->_3 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)):5 -->_3 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)):4 -->_3 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)):3 13:S:'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 14:S:'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 15:S:'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 16:S:'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 17:S:'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) -->_1 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)):18 18:S:'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 19:S:'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) -->_2 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 20:S:'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)):1 21:S:'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)):1 22:W:'natsub#('s(x),'s(y)) -> 'natsub#(x,y) -->_1 'natsub#('s(x),'s(y)) -> 'natsub#(x,y):22 23:W:eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) -->_1 eratos#(dd(x,xs)) -> filter#(x,xs):24 -->_1 eratos#(dd(x,xs)) -> eratos#(filter(x,xs)):23 24:W:eratos#(dd(x,xs)) -> filter#(x,xs) -->_1 filter#(p,dd(x,xs)) -> filter#(p,xs):27 -->_1 filter#(p,dd(x,xs)) -> 'mod#(x,p):26 -->_1 filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()):25 25:W:filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) -->_1 'equal#(x,y) -> c_39('eq#(x,y)):11 26:W:filter#(p,dd(x,xs)) -> 'mod#(x,p) -->_1 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)):12 27:W:filter#(p,dd(x,xs)) -> filter#(p,xs) -->_1 filter#(p,dd(x,xs)) -> filter#(p,xs):27 -->_1 filter#(p,dd(x,xs)) -> 'mod#(x,p):26 -->_1 filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()):25 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 22: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) **** Step 7.b:1.b:1.a:2: SimplifyRHS WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) - Weak DPs: eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: SimplifyRHS + Details: Consider the dependency graph 1:S:'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 2:S:'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 3:S:'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 4:S:'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 5:S:'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 6:S:'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 7:S:'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 8:S:'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 9:S:'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 10:S:'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) -->_2 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_2 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_2 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_2 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 11:S:'equal#(x,y) -> c_39('eq#(x,y)) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)):10 -->_1 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)):9 -->_1 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)):8 -->_1 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)):7 12:S:'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) -->_1 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))):21 -->_1 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))):20 -->_2 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)):16 -->_2 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)):15 -->_2 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)):14 -->_2 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)):13 -->_3 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)):6 -->_3 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)):5 -->_3 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)):4 -->_3 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)):3 13:S:'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 14:S:'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 15:S:'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 16:S:'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) -->_1 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 17:S:'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)) -->_1 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)):18 18:S:'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) -->_1 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y)),'divsub#(x,y)):17 19:S:'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)) -->_2 'natmult#('s(x),y) -> c_61('natadd#(y,'natmult(x,y)),'natmult#(x,y)):19 20:S:'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)):1 21:S:'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) -->_1 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)):2 -->_1 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)):1 23:W:eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) -->_1 eratos#(dd(x,xs)) -> filter#(x,xs):24 -->_1 eratos#(dd(x,xs)) -> eratos#(filter(x,xs)):23 24:W:eratos#(dd(x,xs)) -> filter#(x,xs) -->_1 filter#(p,dd(x,xs)) -> filter#(p,xs):27 -->_1 filter#(p,dd(x,xs)) -> 'mod#(x,p):26 -->_1 filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()):25 25:W:filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) -->_1 'equal#(x,y) -> c_39('eq#(x,y)):11 26:W:filter#(p,dd(x,xs)) -> 'mod#(x,p) -->_1 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)):12 27:W:filter#(p,dd(x,xs)) -> filter#(p,xs) -->_1 filter#(p,dd(x,xs)) -> filter#(p,xs):27 -->_1 filter#(p,dd(x,xs)) -> 'mod#(x,p):26 -->_1 filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()):25 Due to missing edges in the depndency graph, the right-hand sides of following rules could be simplified: 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) **** Step 7.b:1.b:1.a:3: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) - Weak DPs: eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'div,'natdiv,'natdiv','negative,'positive,filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod# ,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos# ,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [5] p('and) = [3] x2 + [0] p('div) = [1] x2 + [1] p('divByZero) = [0] p('divsub) = [0] p('eq) = [3] x2 + [2] p('equal) = [1] x2 + [4] p('false) = [0] p('mod) = [1] p('mult) = [1] x2 + [0] p('natadd) = [7] x1 + [4] x2 + [2] p('natdiv) = [1] p('natdiv') = [0] p('natmult) = [2] x2 + [0] p('natsub) = [1] x2 + [0] p('neg) = [4] p('negative) = [4] p('pos) = [4] p('positive) = [1] x1 + [4] p('pred) = [0] p('s) = [0] p('sub) = [7] x1 + [2] p('succ) = [1] x1 + [4] p('true) = [2] p('underflow) = [1] p(dd) = [1] x1 + [1] x2 + [1] p(eratos) = [4] x1 + [2] p(filter) = [1] x1 + [1] x2 + [0] p(filter') = [1] x2 + [1] x3 + [1] p(nil) = [4] p('add#) = [0] p('and#) = [1] x1 + [1] x2 + [1] p('div#) = [2] x1 + [1] p('divsub#) = [4] p('eq#) = [0] p('equal#) = [2] p('mod#) = [5] x1 + [4] x2 + [6] p('mult#) = [1] x2 + [0] p('natadd#) = [1] x1 + [1] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [2] x2 + [1] p('negative#) = [2] x1 + [1] p('positive#) = [1] p('pred#) = [4] x1 + [4] p('sub#) = [0] p('succ#) = [1] x1 + [0] p(eratos#) = [5] x1 + [4] p(filter#) = [4] x1 + [5] x2 + [3] p(filter'#) = [2] x1 + [2] x3 + [0] p(c_1) = [0] p(c_2) = [1] p(c_3) = [1] x1 + [0] p(c_4) = [1] x1 + [0] p(c_5) = [2] x1 + [0] p(c_6) = [4] p(c_7) = [4] p(c_8) = [0] p(c_9) = [1] p(c_10) = [1] p(c_11) = [1] p(c_12) = [1] p(c_13) = [0] p(c_14) = [2] x1 + [3] p(c_15) = [2] x1 + [1] p(c_16) = [0] p(c_17) = [4] x1 + [4] p(c_18) = [4] x1 + [0] p(c_19) = [1] p(c_20) = [0] p(c_21) = [2] p(c_22) = [4] x1 + [1] p(c_23) = [1] p(c_24) = [2] p(c_25) = [0] p(c_26) = [0] p(c_27) = [0] p(c_28) = [2] x1 + [0] p(c_29) = [1] p(c_30) = [1] p(c_31) = [1] p(c_32) = [4] x1 + [0] p(c_33) = [1] p(c_34) = [2] x1 + [0] p(c_35) = [1] x1 + [1] x2 + [0] p(c_36) = [0] p(c_37) = [2] p(c_38) = [1] p(c_39) = [1] x1 + [2] p(c_40) = [4] x1 + [4] x2 + [2] x3 + [0] p(c_41) = [4] p(c_42) = [4] p(c_43) = [1] p(c_44) = [0] p(c_45) = [2] x1 + [0] p(c_46) = [2] x1 + [4] p(c_47) = [1] p(c_48) = [2] x1 + [4] p(c_49) = [1] x1 + [3] p(c_50) = [0] p(c_51) = [0] p(c_52) = [1] p(c_53) = [4] p(c_54) = [1] p(c_55) = [4] x1 + [0] p(c_56) = [1] p(c_57) = [4] p(c_58) = [4] x1 + [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [4] x1 + [0] p(c_62) = [0] p(c_63) = [0] p(c_64) = [0] p(c_65) = [1] x1 + [4] p(c_66) = [0] p(c_67) = [0] p(c_68) = [2] p(c_69) = [1] p(c_70) = [0] p(c_71) = [0] p(c_72) = [0] p(c_73) = [1] p(c_74) = [4] p(c_75) = [1] p(c_76) = [1] p(c_77) = [2] p(c_78) = [0] p(c_79) = [2] x1 + [0] p(c_80) = [4] x1 + [0] p(c_81) = [1] p(c_82) = [4] p(c_83) = [0] p(c_84) = [4] p(c_85) = [1] x1 + [1] x2 + [1] p(c_86) = [1] p(c_87) = [4] x3 + [0] p(c_88) = [1] p(c_89) = [0] p(c_90) = [0] Following rules are strictly oriented: 'div#('neg(x),'neg(y)) = [9] > [3] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [9] > [1] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [9] > [4] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [9] > [0] = c_18('natdiv#(x,y)) 'mult#('neg(x),'neg(y)) = [4] > [0] = c_45('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [4] > [3] = c_49('natmult#(x,y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [2] >= [2] = c_39('eq#(x,y)) 'mod#(x,y) = [5] x + [4] y + [6] >= [4] x + [4] y + [6] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'pos(y)) = [4] >= [4] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [4] >= [4] = c_48('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [5] x + [5] xs + [9] >= [5] x + [5] xs + [4] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [5] x + [5] xs + [9] >= [4] x + [5] xs + [3] = filter#(x,xs) filter#(p,dd(x,xs)) = [4] p + [5] x + [5] xs + [8] >= [2] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [4] p + [5] x + [5] xs + [8] >= [4] p + [5] x + [6] = 'mod#(x,p) filter#(p,dd(x,xs)) = [4] p + [5] x + [5] xs + [8] >= [4] p + [5] xs + [3] = filter#(p,xs) 'div('0(),'0()) = [1] >= [0] = 'divByZero() 'div('0(),'neg(y)) = [5] >= [0] = '0() 'div('0(),'pos(y)) = [5] >= [0] = '0() 'div('neg(x),'0()) = [1] >= [0] = 'divByZero() 'div('neg(x),'neg(y)) = [5] >= [5] = 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) = [5] >= [4] = 'negative('natdiv(x,y)) 'div('pos(x),'0()) = [1] >= [0] = 'divByZero() 'div('pos(x),'neg(y)) = [5] >= [4] = 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) = [5] >= [5] = 'positive('natdiv(x,y)) 'natdiv('0(),'0()) = [1] >= [0] = 'divByZero() 'natdiv('0(),'s(y)) = [1] >= [0] = '0() 'natdiv('s(x),'0()) = [1] >= [0] = 'divByZero() 'natdiv('s(x),'s(y)) = [1] >= [0] = 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) = [1] >= [0] = '0() 'natdiv'('0(),y) = [0] >= [0] = 's('0()) 'natdiv'('s(x),y) = [0] >= [0] = 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) = [0] >= [0] = '0() 'negative('0()) = [4] >= [0] = '0() 'negative('neg(x)) = [4] >= [4] = 'pos(x) 'negative('pos(x)) = [4] >= [4] = 'neg(x) 'negative('s(x)) = [4] >= [4] = 'neg('s(x)) 'positive('0()) = [4] >= [0] = '0() 'positive('neg(x)) = [8] >= [4] = 'neg(x) 'positive('pos(x)) = [8] >= [4] = 'pos(x) 'positive('s(x)) = [4] >= [4] = 'pos('s(x)) filter(p,dd(x,xs)) = [1] p + [1] x + [1] xs + [1] >= [1] p + [1] x + [1] xs + [1] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [1] p + [4] >= [4] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [1] >= [1] x + [1] xs + [1] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [1] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:4: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) - Weak DPs: 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub# ,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [4] x2 + [4] p('and) = [3] x1 + [5] p('div) = [0] p('divByZero) = [4] p('divsub) = [3] x1 + [4] p('eq) = [1] p('equal) = [4] x1 + [0] p('false) = [0] p('mod) = [1] x1 + [0] p('mult) = [0] p('natadd) = [1] x2 + [0] p('natdiv) = [3] x1 + [1] x2 + [3] p('natdiv') = [2] x1 + [2] p('natmult) = [4] x1 + [1] x2 + [0] p('natsub) = [1] x2 + [2] p('neg) = [0] p('negative) = [0] p('pos) = [1] x1 + [0] p('positive) = [4] x1 + [1] p('pred) = [0] p('s) = [0] p('sub) = [4] x1 + [1] x2 + [4] p('succ) = [3] p('true) = [3] p('underflow) = [2] p(dd) = [1] p(eratos) = [1] x1 + [2] p(filter) = [1] x2 + [1] p(filter') = [1] x1 + [3] x2 + [2] x3 + [0] p(nil) = [0] p('add#) = [0] p('and#) = [4] x1 + [1] x2 + [1] p('div#) = [0] p('divsub#) = [1] x1 + [2] p('eq#) = [0] p('equal#) = [4] p('mod#) = [7] p('mult#) = [2] p('natadd#) = [1] x1 + [1] x2 + [1] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [4] x2 + [0] p('negative#) = [0] p('positive#) = [1] p('pred#) = [0] p('sub#) = [3] p('succ#) = [1] x1 + [1] p(eratos#) = [7] p(filter#) = [7] p(filter'#) = [0] p(c_1) = [1] p(c_2) = [4] x1 + [0] p(c_3) = [4] x1 + [0] p(c_4) = [1] p(c_5) = [4] x1 + [0] p(c_6) = [0] p(c_7) = [4] p(c_8) = [1] p(c_9) = [0] p(c_10) = [2] p(c_11) = [2] p(c_12) = [1] p(c_13) = [4] p(c_14) = [2] x1 + [0] p(c_15) = [4] x1 + [0] p(c_16) = [1] p(c_17) = [1] x1 + [0] p(c_18) = [1] x1 + [0] p(c_19) = [2] p(c_20) = [1] p(c_21) = [0] p(c_22) = [1] x1 + [0] p(c_23) = [2] p(c_24) = [1] p(c_25) = [1] p(c_26) = [1] p(c_27) = [0] p(c_28) = [1] x1 + [0] p(c_29) = [4] p(c_30) = [0] p(c_31) = [1] p(c_32) = [4] x1 + [0] p(c_33) = [0] p(c_34) = [4] x1 + [0] p(c_35) = [1] x1 + [1] x2 + [0] p(c_36) = [0] p(c_37) = [2] p(c_38) = [2] p(c_39) = [1] x1 + [4] p(c_40) = [1] x1 + [2] x2 + [4] x3 + [0] p(c_41) = [0] p(c_42) = [4] p(c_43) = [2] p(c_44) = [1] p(c_45) = [1] x1 + [1] p(c_46) = [1] x1 + [2] p(c_47) = [1] p(c_48) = [4] x1 + [2] p(c_49) = [4] x1 + [1] p(c_50) = [0] p(c_51) = [2] p(c_52) = [0] p(c_53) = [2] p(c_54) = [4] p(c_55) = [2] x1 + [0] p(c_56) = [0] p(c_57) = [1] p(c_58) = [4] x1 + [0] p(c_59) = [1] p(c_60) = [2] p(c_61) = [4] x1 + [0] p(c_62) = [1] p(c_63) = [0] p(c_64) = [1] p(c_65) = [4] p(c_66) = [0] p(c_67) = [1] p(c_68) = [0] p(c_69) = [1] p(c_70) = [0] p(c_71) = [4] p(c_72) = [1] p(c_73) = [0] p(c_74) = [0] p(c_75) = [1] p(c_76) = [1] p(c_77) = [4] p(c_78) = [1] p(c_79) = [1] x1 + [3] p(c_80) = [4] x1 + [1] p(c_81) = [4] p(c_82) = [1] p(c_83) = [0] p(c_84) = [0] p(c_85) = [1] p(c_86) = [4] p(c_87) = [1] x3 + [4] p(c_88) = [0] p(c_89) = [0] p(c_90) = [4] Following rules are strictly oriented: 'sub#(x,'pos(y)) = [3] > [1] = c_80('add#(x,'neg(y))) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [4] >= [4] = c_39('eq#(x,y)) 'mod#(x,y) = [7] >= [7] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [2] >= [1] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [2] >= [2] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [2] >= [2] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [2] >= [1] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [3] >= [3] = c_79('add#(x,'pos(y))) eratos#(dd(x,xs)) = [7] >= [7] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [7] >= [7] = filter#(x,xs) filter#(p,dd(x,xs)) = [7] >= [4] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [7] >= [7] = 'mod#(x,p) filter#(p,dd(x,xs)) = [7] >= [7] = filter#(p,xs) **** Step 7.b:1.b:1.a:5: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) - Weak DPs: 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub# ,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [1] x2 + [5] p('and) = [3] x2 + [1] p('div) = [0] p('divByZero) = [2] p('divsub) = [0] p('eq) = [0] p('equal) = [0] p('false) = [4] p('mod) = [2] x2 + [1] p('mult) = [0] p('natadd) = [3] x2 + [0] p('natdiv) = [2] p('natdiv') = [1] x2 + [0] p('natmult) = [4] x1 + [4] x2 + [2] p('natsub) = [1] p('neg) = [0] p('negative) = [5] x1 + [2] p('pos) = [0] p('positive) = [2] x1 + [0] p('pred) = [1] x1 + [4] p('s) = [2] p('sub) = [5] x1 + [0] p('succ) = [2] x1 + [2] p('true) = [3] p('underflow) = [4] p(dd) = [1] p(eratos) = [1] x1 + [4] p(filter) = [6] x1 + [5] x2 + [4] p(filter') = [2] x1 + [7] x2 + [2] x3 + [2] p(nil) = [0] p('add#) = [0] p('and#) = [0] p('div#) = [0] p('divsub#) = [4] x2 + [0] p('eq#) = [0] p('equal#) = [4] p('mod#) = [5] p('mult#) = [0] p('natadd#) = [1] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [4] x2 + [0] p('negative#) = [1] p('positive#) = [1] p('pred#) = [0] p('sub#) = [0] p('succ#) = [0] p(eratos#) = [5] p(filter#) = [5] p(filter'#) = [1] x1 + [1] x3 + [0] p(c_1) = [0] p(c_2) = [0] p(c_3) = [4] x1 + [0] p(c_4) = [4] p(c_5) = [4] x1 + [0] p(c_6) = [0] p(c_7) = [1] p(c_8) = [2] p(c_9) = [1] p(c_10) = [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [1] p(c_14) = [4] x1 + [0] p(c_15) = [4] x1 + [0] p(c_16) = [2] p(c_17) = [2] x1 + [0] p(c_18) = [1] x1 + [0] p(c_19) = [4] p(c_20) = [1] p(c_21) = [1] p(c_22) = [2] p(c_23) = [0] p(c_24) = [0] p(c_25) = [0] p(c_26) = [4] p(c_27) = [1] p(c_28) = [4] x1 + [0] p(c_29) = [1] p(c_30) = [2] p(c_31) = [1] p(c_32) = [4] x1 + [0] p(c_33) = [0] p(c_34) = [1] x1 + [0] p(c_35) = [2] x1 + [1] x2 + [0] p(c_36) = [0] p(c_37) = [1] p(c_38) = [1] p(c_39) = [1] x1 + [3] p(c_40) = [4] x1 + [4] x2 + [2] x3 + [3] p(c_41) = [0] p(c_42) = [4] p(c_43) = [2] p(c_44) = [1] p(c_45) = [4] x1 + [0] p(c_46) = [1] x1 + [0] p(c_47) = [0] p(c_48) = [1] x1 + [0] p(c_49) = [1] x1 + [0] p(c_50) = [1] p(c_51) = [1] p(c_52) = [0] p(c_53) = [1] p(c_54) = [1] p(c_55) = [2] x1 + [0] p(c_56) = [1] p(c_57) = [0] p(c_58) = [2] x1 + [0] p(c_59) = [0] p(c_60) = [2] p(c_61) = [1] x1 + [0] p(c_62) = [2] p(c_63) = [1] p(c_64) = [1] p(c_65) = [1] p(c_66) = [0] p(c_67) = [0] p(c_68) = [1] p(c_69) = [1] p(c_70) = [1] p(c_71) = [0] p(c_72) = [0] p(c_73) = [1] p(c_74) = [0] p(c_75) = [1] p(c_76) = [1] p(c_77) = [1] p(c_78) = [2] p(c_79) = [2] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [0] p(c_82) = [0] p(c_83) = [0] p(c_84) = [0] p(c_85) = [2] p(c_86) = [4] p(c_87) = [2] x1 + [4] x2 + [0] p(c_88) = [0] p(c_89) = [1] p(c_90) = [1] Following rules are strictly oriented: 'equal#(x,y) = [4] > [3] = c_39('eq#(x,y)) 'mod#(x,y) = [5] > [3] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'mult#('neg(x),'neg(y)) = [0] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [0] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [0] >= [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [0] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [5] >= [5] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [5] >= [5] = filter#(x,xs) filter#(p,dd(x,xs)) = [5] >= [4] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [5] >= [5] = 'mod#(x,p) filter#(p,dd(x,xs)) = [5] >= [5] = filter#(p,xs) **** Step 7.b:1.b:1.a:6: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) - Weak DPs: 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult# ,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [2] p('and) = [3] x1 + [0] p('div) = [1] x2 + [0] p('divByZero) = [2] p('divsub) = [0] p('eq) = [2] p('equal) = [1] x2 + [0] p('false) = [0] p('mod) = [1] p('mult) = [1] x1 + [1] p('natadd) = [5] p('natdiv) = [2] x2 + [4] p('natdiv') = [6] p('natmult) = [2] x2 + [2] p('natsub) = [1] x1 + [1] x2 + [0] p('neg) = [1] x1 + [2] p('negative) = [0] p('pos) = [1] x1 + [5] p('positive) = [1] x1 + [0] p('pred) = [2] p('s) = [1] x1 + [3] p('sub) = [1] p('succ) = [0] p('true) = [5] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [1] p(eratos) = [1] x1 + [1] p(filter) = [1] x2 + [1] p(filter') = [1] x2 + [1] x3 + [1] p(nil) = [7] p('add#) = [1] x1 + [0] p('and#) = [2] x2 + [1] p('div#) = [0] p('divsub#) = [2] x1 + [0] p('eq#) = [0] p('equal#) = [1] x2 + [6] p('mod#) = [4] x1 + [4] x2 + [7] p('mult#) = [1] x1 + [0] p('natadd#) = [1] x2 + [0] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [0] p('negative#) = [1] p('positive#) = [1] p('pred#) = [1] p('sub#) = [4] x1 + [1] p('succ#) = [2] x1 + [2] p(eratos#) = [4] x1 + [5] p(filter#) = [4] x1 + [4] x2 + [5] p(filter'#) = [4] x2 + [1] x3 + [2] p(c_1) = [2] p(c_2) = [1] x1 + [2] p(c_3) = [1] x1 + [0] p(c_4) = [1] p(c_5) = [1] x1 + [1] p(c_6) = [1] p(c_7) = [1] p(c_8) = [1] p(c_9) = [0] p(c_10) = [0] p(c_11) = [0] p(c_12) = [1] p(c_13) = [1] p(c_14) = [1] x1 + [0] p(c_15) = [1] x1 + [0] p(c_16) = [2] p(c_17) = [4] x1 + [0] p(c_18) = [2] x1 + [0] p(c_19) = [1] p(c_20) = [0] p(c_21) = [0] p(c_22) = [0] p(c_23) = [2] p(c_24) = [1] p(c_25) = [1] p(c_26) = [0] p(c_27) = [4] p(c_28) = [1] x1 + [0] p(c_29) = [1] p(c_30) = [0] p(c_31) = [0] p(c_32) = [2] x1 + [0] p(c_33) = [0] p(c_34) = [4] x1 + [0] p(c_35) = [4] x1 + [1] x2 + [0] p(c_36) = [1] p(c_37) = [1] p(c_38) = [0] p(c_39) = [2] x1 + [6] p(c_40) = [1] x1 + [4] x2 + [4] x3 + [5] p(c_41) = [0] p(c_42) = [2] p(c_43) = [1] p(c_44) = [0] p(c_45) = [2] x1 + [2] p(c_46) = [2] x1 + [1] p(c_47) = [0] p(c_48) = [4] x1 + [1] p(c_49) = [1] x1 + [0] p(c_50) = [1] p(c_51) = [1] p(c_52) = [1] p(c_53) = [0] p(c_54) = [1] p(c_55) = [2] x1 + [0] p(c_56) = [1] p(c_57) = [1] p(c_58) = [4] x1 + [0] p(c_59) = [1] p(c_60) = [1] p(c_61) = [1] x1 + [0] p(c_62) = [1] p(c_63) = [2] p(c_64) = [0] p(c_65) = [1] p(c_66) = [0] p(c_67) = [0] p(c_68) = [1] p(c_69) = [1] p(c_70) = [1] p(c_71) = [1] p(c_72) = [1] p(c_73) = [4] p(c_74) = [0] p(c_75) = [0] p(c_76) = [0] p(c_77) = [0] p(c_78) = [2] p(c_79) = [4] x1 + [0] p(c_80) = [4] x1 + [1] p(c_81) = [1] p(c_82) = [2] p(c_83) = [2] p(c_84) = [2] p(c_85) = [1] x1 + [1] x2 + [0] p(c_86) = [0] p(c_87) = [2] x1 + [1] p(c_88) = [0] p(c_89) = [4] p(c_90) = [0] Following rules are strictly oriented: 'add#('pos('s('s(x))),y) = [1] x + [11] > [1] x + [9] = c_5('add#('pos('s(x)),y)) 'mult#('neg(x),'pos(y)) = [1] x + [2] > [1] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [1] x + [5] > [1] = c_48('natmult#(x,y)) 'sub#(x,'neg(y)) = [4] x + [1] > [4] x + [0] = c_79('add#(x,'pos(y))) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [1] x + [8] >= [1] x + [8] = c_3('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [1] y + [6] >= [6] = c_39('eq#(x,y)) 'mod#(x,y) = [4] x + [4] y + [7] >= [4] x + [4] y + [6] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [1] x + [2] >= [2] = c_45('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [1] x + [5] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'pos(y)) = [4] x + [1] >= [4] x + [1] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [4] x + [4] xs + [9] >= [4] xs + [9] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [4] x + [4] xs + [9] >= [4] x + [4] xs + [5] = filter#(x,xs) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [9] >= [6] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [9] >= [4] p + [4] x + [7] = 'mod#(x,p) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [9] >= [4] p + [4] xs + [5] = filter#(p,xs) filter(p,dd(x,xs)) = [1] x + [1] xs + [2] >= [1] x + [1] xs + [2] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [8] >= [7] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [1] >= [1] x + [1] xs + [1] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [1] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:7: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) - Weak DPs: 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'divsub,filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'# ,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [2] p('add) = [6] p('and) = [1] x1 + [4] p('div) = [3] x1 + [2] p('divByZero) = [1] p('divsub) = [1] x1 + [0] p('eq) = [6] x2 + [0] p('equal) = [2] x1 + [5] x2 + [0] p('false) = [0] p('mod) = [1] x1 + [1] p('mult) = [4] x2 + [0] p('natadd) = [2] x1 + [2] p('natdiv) = [4] x1 + [0] p('natdiv') = [4] x2 + [0] p('natmult) = [4] x1 + [1] p('natsub) = [1] x2 + [0] p('neg) = [1] x1 + [2] p('negative) = [2] p('pos) = [1] x1 + [0] p('positive) = [1] x1 + [2] p('pred) = [5] p('s) = [1] x1 + [0] p('sub) = [3] x1 + [4] p('succ) = [1] x1 + [1] p('true) = [2] p('underflow) = [2] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [0] p(filter) = [1] x1 + [1] x2 + [0] p(filter') = [1] x2 + [1] x3 + [0] p(nil) = [2] p('add#) = [1] x1 + [0] p('and#) = [2] x1 + [4] p('div#) = [4] x1 + [3] x2 + [0] p('divsub#) = [4] p('eq#) = [0] p('equal#) = [0] p('mod#) = [5] x1 + [5] x2 + [0] p('mult#) = [0] p('natadd#) = [1] x1 + [0] p('natdiv#) = [4] x1 + [3] x2 + [0] p('natdiv'#) = [4] x1 + [3] x2 + [0] p('natmult#) = [0] p('natsub#) = [1] x1 + [1] x2 + [0] p('negative#) = [0] p('positive#) = [1] x1 + [0] p('pred#) = [1] x1 + [4] p('sub#) = [1] x1 + [0] p('succ#) = [0] p(eratos#) = [5] x1 + [0] p(filter#) = [5] x1 + [5] x2 + [0] p(filter'#) = [4] x1 + [1] x2 + [1] x3 + [0] p(c_1) = [0] p(c_2) = [4] p(c_3) = [1] x1 + [0] p(c_4) = [1] x1 + [1] p(c_5) = [1] x1 + [0] p(c_6) = [1] p(c_7) = [4] p(c_8) = [0] p(c_9) = [4] p(c_10) = [1] p(c_11) = [1] p(c_12) = [0] p(c_13) = [1] p(c_14) = [1] x1 + [6] p(c_15) = [1] x1 + [1] p(c_16) = [1] p(c_17) = [1] x1 + [1] p(c_18) = [1] x1 + [0] p(c_19) = [1] p(c_20) = [0] p(c_21) = [0] p(c_22) = [1] p(c_23) = [4] p(c_24) = [1] p(c_25) = [1] p(c_26) = [0] p(c_27) = [2] p(c_28) = [1] x1 + [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [1] p(c_32) = [1] x1 + [0] p(c_33) = [0] p(c_34) = [4] x1 + [0] p(c_35) = [2] x1 + [1] x2 + [0] p(c_36) = [0] p(c_37) = [1] p(c_38) = [2] p(c_39) = [4] x1 + [0] p(c_40) = [1] x1 + [4] x2 + [1] x3 + [0] p(c_41) = [0] p(c_42) = [1] p(c_43) = [1] p(c_44) = [0] p(c_45) = [1] x1 + [0] p(c_46) = [2] x1 + [0] p(c_47) = [0] p(c_48) = [2] x1 + [0] p(c_49) = [4] x1 + [0] p(c_50) = [2] p(c_51) = [1] p(c_52) = [2] p(c_53) = [1] p(c_54) = [1] p(c_55) = [1] x1 + [0] p(c_56) = [1] p(c_57) = [4] p(c_58) = [1] x1 + [0] p(c_59) = [1] p(c_60) = [1] p(c_61) = [4] x1 + [0] p(c_62) = [2] p(c_63) = [1] p(c_64) = [1] p(c_65) = [0] p(c_66) = [0] p(c_67) = [4] p(c_68) = [2] p(c_69) = [1] p(c_70) = [4] p(c_71) = [4] p(c_72) = [4] p(c_73) = [0] p(c_74) = [2] p(c_75) = [1] p(c_76) = [0] p(c_77) = [2] p(c_78) = [2] p(c_79) = [1] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [1] p(c_82) = [2] p(c_83) = [0] p(c_84) = [1] p(c_85) = [1] x1 + [1] p(c_86) = [1] p(c_87) = [2] x2 + [4] p(c_88) = [1] p(c_89) = [4] p(c_90) = [1] Following rules are strictly oriented: 'add#('neg('s('s(x))),y) = [1] x + [2] > [1] x + [0] = c_3('add#('pos('s(x)),y)) Following rules are (at-least) weakly oriented: 'add#('pos('s('s(x))),y) = [1] x + [0] >= [1] x + [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [4] x + [3] y + [14] >= [4] x + [3] y + [6] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [4] x + [3] y + [8] >= [4] x + [3] y + [1] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [4] x + [3] y + [6] >= [4] x + [3] y + [1] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [4] x + [3] y + [0] >= [4] x + [3] y + [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [0] >= [0] = c_39('eq#(x,y)) 'mod#(x,y) = [5] x + [5] y + [0] >= [5] x + [3] y + [0] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [0] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [0] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [0] >= [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [0] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [4] x + [3] y + [0] >= [4] x + [3] y + [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [4] x + [3] y + [0] >= [4] x + [3] y + [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [1] x + [0] >= [1] x + [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [1] x + [0] >= [1] x + [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [5] x + [5] xs + [0] >= [5] x + [5] xs + [0] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [5] x + [5] xs + [0] >= [5] x + [5] xs + [0] = filter#(x,xs) filter#(p,dd(x,xs)) = [5] p + [5] x + [5] xs + [0] >= [0] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [5] p + [5] x + [5] xs + [0] >= [5] p + [5] x + [0] = 'mod#(x,p) filter#(p,dd(x,xs)) = [5] p + [5] x + [5] xs + [0] >= [5] p + [5] xs + [0] = filter#(p,xs) 'divsub('0(),'0()) = [2] >= [2] = '0() 'divsub('0(),'s(y)) = [2] >= [2] = 'underflow() 'divsub('s(x),'0()) = [1] x + [0] >= [1] x + [0] = 's(x) 'divsub('s(x),'s(y)) = [1] x + [0] >= [1] x + [0] = 'divsub(x,y) filter(p,dd(x,xs)) = [1] p + [1] x + [1] xs + [0] >= [1] p + [1] x + [1] xs + [0] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [1] p + [2] >= [2] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [0] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:8: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub# ,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [1] p('add) = [2] p('and) = [6] x2 + [2] p('div) = [0] p('divByZero) = [1] p('divsub) = [0] p('eq) = [0] p('equal) = [2] x2 + [0] p('false) = [2] p('mod) = [0] p('mult) = [0] p('natadd) = [4] x1 + [1] p('natdiv) = [4] x2 + [2] p('natdiv') = [2] x1 + [0] p('natmult) = [0] p('natsub) = [2] x1 + [0] p('neg) = [1] x1 + [0] p('negative) = [1] x1 + [0] p('pos) = [1] x1 + [4] p('positive) = [1] x1 + [4] p('pred) = [1] p('s) = [1] x1 + [0] p('sub) = [4] p('succ) = [0] p('true) = [2] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [1] x1 + [4] p(filter) = [0] p(filter') = [4] x1 + [2] x2 + [0] p(nil) = [0] p('add#) = [0] p('and#) = [0] p('div#) = [0] p('divsub#) = [0] p('eq#) = [1] x2 + [0] p('equal#) = [2] x2 + [0] p('mod#) = [2] p('mult#) = [1] p('natadd#) = [0] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [1] p('negative#) = [1] p('positive#) = [2] p('pred#) = [2] p('sub#) = [0] p('succ#) = [2] x1 + [1] p(eratos#) = [2] p(filter#) = [2] p(filter'#) = [1] p(c_1) = [0] p(c_2) = [4] p(c_3) = [1] x1 + [0] p(c_4) = [1] x1 + [4] p(c_5) = [1] x1 + [0] p(c_6) = [1] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [4] p(c_11) = [1] p(c_12) = [0] p(c_13) = [4] p(c_14) = [1] x1 + [0] p(c_15) = [2] x1 + [0] p(c_16) = [1] p(c_17) = [2] x1 + [0] p(c_18) = [4] x1 + [0] p(c_19) = [1] p(c_20) = [0] p(c_21) = [2] p(c_22) = [4] p(c_23) = [1] p(c_24) = [2] p(c_25) = [0] p(c_26) = [1] p(c_27) = [4] p(c_28) = [1] x1 + [0] p(c_29) = [0] p(c_30) = [1] p(c_31) = [0] p(c_32) = [1] x1 + [0] p(c_33) = [4] p(c_34) = [1] x1 + [0] p(c_35) = [1] x1 + [1] x2 + [0] p(c_36) = [1] p(c_37) = [2] p(c_38) = [1] p(c_39) = [1] x1 + [0] p(c_40) = [1] x1 + [2] x2 + [4] x3 + [0] p(c_41) = [1] p(c_42) = [2] p(c_43) = [1] p(c_44) = [2] p(c_45) = [4] x1 + [0] p(c_46) = [4] x1 + [1] p(c_47) = [2] p(c_48) = [4] x1 + [1] p(c_49) = [1] x1 + [1] p(c_50) = [1] p(c_51) = [4] p(c_52) = [1] p(c_53) = [1] p(c_54) = [1] p(c_55) = [4] x1 + [0] p(c_56) = [0] p(c_57) = [0] p(c_58) = [4] x1 + [0] p(c_59) = [1] p(c_60) = [0] p(c_61) = [4] x1 + [0] p(c_62) = [1] p(c_63) = [1] p(c_64) = [4] p(c_65) = [4] x1 + [0] p(c_66) = [1] p(c_67) = [1] p(c_68) = [1] p(c_69) = [0] p(c_70) = [0] p(c_71) = [1] p(c_72) = [4] p(c_73) = [1] p(c_74) = [0] p(c_75) = [1] p(c_76) = [1] p(c_77) = [1] p(c_78) = [4] p(c_79) = [4] x1 + [0] p(c_80) = [2] x1 + [0] p(c_81) = [0] p(c_82) = [1] p(c_83) = [4] p(c_84) = [1] p(c_85) = [1] x1 + [1] x2 + [1] p(c_86) = [1] p(c_87) = [1] x1 + [1] x2 + [4] p(c_88) = [1] p(c_89) = [1] p(c_90) = [0] Following rules are strictly oriented: 'eq#('pos(x),'pos(y)) = [1] y + [4] > [1] y + [0] = c_32('eq#(x,y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [1] y + [0] >= [1] y + [0] = c_28('eq#(x,y)) 'eq#('s(x),'s(y)) = [1] y + [0] >= [1] y + [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [1] y'1 + [1] y'2 + [0] >= [1] y'1 + [1] y'2 + [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [2] y + [0] >= [1] y + [0] = c_39('eq#(x,y)) 'mod#(x,y) = [2] >= [2] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [1] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [1] >= [1] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [1] >= [1] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [1] >= [1] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [2] >= [2] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [2] >= [2] = filter#(x,xs) filter#(p,dd(x,xs)) = [2] >= [2] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [2] >= [2] = 'mod#(x,p) filter#(p,dd(x,xs)) = [2] >= [2] = filter#(p,xs) **** Step 7.b:1.b:1.a:9: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult# ,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [1] p('add) = [0] p('and) = [0] p('div) = [0] p('divByZero) = [0] p('divsub) = [0] p('eq) = [3] x2 + [0] p('equal) = [0] p('false) = [0] p('mod) = [1] p('mult) = [0] p('natadd) = [4] x1 + [2] p('natdiv) = [7] x1 + [4] x2 + [3] p('natdiv') = [1] x1 + [0] p('natmult) = [0] p('natsub) = [2] x1 + [1] p('neg) = [1] x1 + [0] p('negative) = [0] p('pos) = [1] x1 + [0] p('positive) = [2] x1 + [0] p('pred) = [0] p('s) = [1] x1 + [0] p('sub) = [6] x1 + [2] x2 + [2] p('succ) = [1] p('true) = [0] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [4] p(eratos) = [1] p(filter) = [1] x1 + [1] x2 + [1] p(filter') = [1] x2 + [1] x3 + [4] p(nil) = [2] p('add#) = [0] p('and#) = [4] p('div#) = [0] p('divsub#) = [1] x1 + [4] x2 + [1] p('eq#) = [2] x2 + [0] p('equal#) = [2] x2 + [7] p('mod#) = [0] p('mult#) = [0] p('natadd#) = [1] x2 + [2] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [1] p('negative#) = [1] p('positive#) = [1] p('pred#) = [2] x1 + [0] p('sub#) = [0] p('succ#) = [4] x1 + [0] p(eratos#) = [2] x1 + [0] p(filter#) = [1] x2 + [5] p(filter'#) = [4] x2 + [2] x3 + [0] p(c_1) = [4] p(c_2) = [2] p(c_3) = [4] x1 + [0] p(c_4) = [1] x1 + [0] p(c_5) = [1] x1 + [0] p(c_6) = [1] p(c_7) = [0] p(c_8) = [0] p(c_9) = [4] p(c_10) = [0] p(c_11) = [1] p(c_12) = [0] p(c_13) = [0] p(c_14) = [4] x1 + [0] p(c_15) = [4] x1 + [0] p(c_16) = [4] p(c_17) = [4] x1 + [0] p(c_18) = [4] x1 + [0] p(c_19) = [0] p(c_20) = [4] p(c_21) = [2] p(c_22) = [0] p(c_23) = [0] p(c_24) = [0] p(c_25) = [0] p(c_26) = [1] p(c_27) = [1] p(c_28) = [1] x1 + [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [0] p(c_32) = [1] x1 + [0] p(c_33) = [1] p(c_34) = [1] x1 + [0] p(c_35) = [1] x1 + [1] x2 + [6] p(c_36) = [4] p(c_37) = [1] p(c_38) = [2] p(c_39) = [1] x1 + [2] p(c_40) = [2] x1 + [4] x2 + [4] x3 + [0] p(c_41) = [0] p(c_42) = [1] p(c_43) = [0] p(c_44) = [1] p(c_45) = [2] x1 + [0] p(c_46) = [1] x1 + [0] p(c_47) = [1] p(c_48) = [2] x1 + [0] p(c_49) = [1] x1 + [0] p(c_50) = [1] p(c_51) = [1] x1 + [0] p(c_52) = [1] p(c_53) = [1] p(c_54) = [0] p(c_55) = [4] x1 + [0] p(c_56) = [2] p(c_57) = [0] p(c_58) = [4] x1 + [0] p(c_59) = [4] p(c_60) = [0] p(c_61) = [4] x1 + [0] p(c_62) = [1] p(c_63) = [1] p(c_64) = [0] p(c_65) = [2] p(c_66) = [1] p(c_67) = [0] p(c_68) = [1] p(c_69) = [1] p(c_70) = [1] p(c_71) = [1] p(c_72) = [0] p(c_73) = [1] p(c_74) = [0] p(c_75) = [1] p(c_76) = [1] p(c_77) = [0] p(c_78) = [1] p(c_79) = [1] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [0] p(c_82) = [2] p(c_83) = [1] p(c_84) = [2] p(c_85) = [0] p(c_86) = [1] p(c_87) = [4] x1 + [0] p(c_88) = [2] p(c_89) = [0] p(c_90) = [0] Following rules are strictly oriented: 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [2] y'1 + [2] y'2 + [8] > [2] y'1 + [2] y'2 + [6] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [2] y + [0] >= [2] y + [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [2] y + [0] >= [2] y + [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [2] y + [0] >= [2] y + [0] = c_34('eq#(x,y)) 'equal#(x,y) = [2] y + [7] >= [2] y + [2] = c_39('eq#(x,y)) 'mod#(x,y) = [0] >= [0] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [0] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [0] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [0] >= [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [0] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [2] x + [2] xs + [8] >= [2] x + [2] xs + [2] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [2] x + [2] xs + [8] >= [1] xs + [5] = filter#(x,xs) filter#(p,dd(x,xs)) = [1] x + [1] xs + [9] >= [9] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [1] x + [1] xs + [9] >= [0] = 'mod#(x,p) filter#(p,dd(x,xs)) = [1] x + [1] xs + [9] >= [1] xs + [5] = filter#(p,xs) filter(p,dd(x,xs)) = [1] p + [1] x + [1] xs + [5] >= [1] p + [1] x + [1] xs + [5] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [1] p + [3] >= [2] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [4] >= [1] x + [1] xs + [4] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [4] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:10: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub# ,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [0] p('and) = [1] x1 + [1] x2 + [0] p('div) = [0] p('divByZero) = [2] p('divsub) = [0] p('eq) = [0] p('equal) = [1] x1 + [6] p('false) = [7] p('mod) = [2] p('mult) = [3] x1 + [0] p('natadd) = [1] x2 + [1] p('natdiv) = [1] x2 + [0] p('natdiv') = [2] p('natmult) = [1] x1 + [5] x2 + [4] p('natsub) = [4] p('neg) = [1] x1 + [0] p('negative) = [4] x1 + [4] p('pos) = [1] x1 + [0] p('positive) = [1] p('pred) = [0] p('s) = [1] x1 + [2] p('sub) = [0] p('succ) = [4] p('true) = [1] p('underflow) = [1] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [1] p(filter) = [3] p(filter') = [3] x2 + [3] p(nil) = [0] p('add#) = [0] p('and#) = [4] x1 + [1] x2 + [4] p('div#) = [1] p('divsub#) = [2] x2 + [4] p('eq#) = [4] x2 + [0] p('equal#) = [6] x2 + [5] p('mod#) = [1] p('mult#) = [0] p('natadd#) = [4] x1 + [0] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [1] p('negative#) = [1] x1 + [0] p('positive#) = [1] x1 + [1] p('pred#) = [2] x1 + [1] p('sub#) = [0] p('succ#) = [1] x1 + [0] p(eratos#) = [5] p(filter#) = [5] p(filter'#) = [4] x1 + [2] x2 + [2] x3 + [0] p(c_1) = [4] p(c_2) = [1] p(c_3) = [2] x1 + [0] p(c_4) = [2] x1 + [0] p(c_5) = [1] x1 + [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [1] p(c_9) = [1] p(c_10) = [0] p(c_11) = [1] p(c_12) = [0] p(c_13) = [4] p(c_14) = [4] x1 + [1] p(c_15) = [2] x1 + [1] p(c_16) = [1] p(c_17) = [1] x1 + [1] p(c_18) = [1] x1 + [0] p(c_19) = [0] p(c_20) = [1] p(c_21) = [4] p(c_22) = [1] x1 + [1] p(c_23) = [2] p(c_24) = [2] p(c_25) = [0] p(c_26) = [1] p(c_27) = [2] p(c_28) = [1] x1 + [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [1] p(c_32) = [1] x1 + [0] p(c_33) = [2] p(c_34) = [1] x1 + [6] p(c_35) = [1] x1 + [1] x2 + [0] p(c_36) = [1] p(c_37) = [0] p(c_38) = [1] p(c_39) = [1] x1 + [0] p(c_40) = [4] x1 + [4] x2 + [1] x3 + [0] p(c_41) = [1] p(c_42) = [0] p(c_43) = [1] p(c_44) = [0] p(c_45) = [4] x1 + [0] p(c_46) = [4] x1 + [0] p(c_47) = [0] p(c_48) = [1] x1 + [0] p(c_49) = [2] x1 + [0] p(c_50) = [1] p(c_51) = [0] p(c_52) = [1] p(c_53) = [1] p(c_54) = [1] p(c_55) = [4] x1 + [0] p(c_56) = [1] p(c_57) = [1] p(c_58) = [4] x1 + [0] p(c_59) = [1] p(c_60) = [1] p(c_61) = [2] x1 + [0] p(c_62) = [4] p(c_63) = [0] p(c_64) = [0] p(c_65) = [1] p(c_66) = [2] p(c_67) = [4] p(c_68) = [4] p(c_69) = [1] p(c_70) = [2] p(c_71) = [1] p(c_72) = [1] p(c_73) = [0] p(c_74) = [0] p(c_75) = [0] p(c_76) = [2] p(c_77) = [2] p(c_78) = [0] p(c_79) = [1] x1 + [0] p(c_80) = [2] x1 + [0] p(c_81) = [1] p(c_82) = [2] p(c_83) = [1] p(c_84) = [4] p(c_85) = [1] x2 + [4] p(c_86) = [2] p(c_87) = [1] x1 + [1] x2 + [1] p(c_88) = [0] p(c_89) = [4] p(c_90) = [0] Following rules are strictly oriented: 'eq#('s(x),'s(y)) = [4] y + [8] > [4] y + [6] = c_34('eq#(x,y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [1] >= [1] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [1] >= [1] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [1] >= [1] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [1] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [4] y + [0] >= [4] y + [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [4] y + [0] >= [4] y + [0] = c_32('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [4] y'1 + [4] y'2 + [0] >= [4] y'1 + [4] y'2 + [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [6] y + [5] >= [4] y + [0] = c_39('eq#(x,y)) 'mod#(x,y) = [1] >= [1] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [0] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [0] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [0] >= [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [0] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [5] >= [5] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [5] >= [5] = filter#(x,xs) filter#(p,dd(x,xs)) = [5] >= [5] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [5] >= [1] = 'mod#(x,p) filter#(p,dd(x,xs)) = [5] >= [5] = filter#(p,xs) **** Step 7.b:1.b:1.a:11: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub# ,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [1] p('and) = [1] x1 + [2] x2 + [3] p('div) = [1] p('divByZero) = [0] p('divsub) = [0] p('eq) = [1] p('equal) = [2] x1 + [1] x2 + [1] p('false) = [0] p('mod) = [7] p('mult) = [1] x2 + [5] p('natadd) = [4] x1 + [0] p('natdiv) = [0] p('natdiv') = [0] p('natmult) = [1] x1 + [1] x2 + [4] p('natsub) = [4] x1 + [0] p('neg) = [1] x1 + [1] p('negative) = [6] p('pos) = [1] x1 + [5] p('positive) = [1] p('pred) = [0] p('s) = [1] x1 + [0] p('sub) = [4] x1 + [6] p('succ) = [1] x1 + [5] p('true) = [1] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [1] p(filter) = [2] p(filter') = [7] x2 + [2] x3 + [6] p(nil) = [1] p('add#) = [0] p('and#) = [2] x2 + [2] p('div#) = [0] p('divsub#) = [2] x1 + [0] p('eq#) = [2] x2 + [0] p('equal#) = [4] x2 + [2] p('mod#) = [3] p('mult#) = [0] p('natadd#) = [1] x1 + [0] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [0] p('natsub#) = [2] p('negative#) = [0] p('positive#) = [0] p('pred#) = [4] x1 + [0] p('sub#) = [3] p('succ#) = [2] p(eratos#) = [3] p(filter#) = [3] p(filter'#) = [1] x2 + [1] x3 + [1] p(c_1) = [1] p(c_2) = [1] x1 + [1] p(c_3) = [1] x1 + [0] p(c_4) = [0] p(c_5) = [4] x1 + [0] p(c_6) = [4] p(c_7) = [1] p(c_8) = [1] p(c_9) = [1] p(c_10) = [0] p(c_11) = [1] p(c_12) = [0] p(c_13) = [0] p(c_14) = [4] x1 + [0] p(c_15) = [2] x1 + [0] p(c_16) = [0] p(c_17) = [2] x1 + [0] p(c_18) = [4] x1 + [0] p(c_19) = [1] p(c_20) = [2] p(c_21) = [4] p(c_22) = [2] p(c_23) = [4] p(c_24) = [0] p(c_25) = [0] p(c_26) = [0] p(c_27) = [1] p(c_28) = [1] x1 + [0] p(c_29) = [1] p(c_30) = [0] p(c_31) = [1] p(c_32) = [1] x1 + [0] p(c_33) = [0] p(c_34) = [1] x1 + [0] p(c_35) = [1] x1 + [1] x2 + [0] p(c_36) = [1] p(c_37) = [0] p(c_38) = [1] p(c_39) = [2] x1 + [2] p(c_40) = [1] x1 + [4] x2 + [4] x3 + [0] p(c_41) = [1] p(c_42) = [0] p(c_43) = [0] p(c_44) = [0] p(c_45) = [4] x1 + [0] p(c_46) = [4] x1 + [0] p(c_47) = [1] p(c_48) = [2] x1 + [0] p(c_49) = [2] x1 + [0] p(c_50) = [4] p(c_51) = [0] p(c_52) = [2] p(c_53) = [0] p(c_54) = [1] p(c_55) = [2] x1 + [0] p(c_56) = [1] p(c_57) = [1] p(c_58) = [2] x1 + [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [2] x1 + [0] p(c_62) = [4] p(c_63) = [0] p(c_64) = [0] p(c_65) = [1] x1 + [0] p(c_66) = [1] p(c_67) = [0] p(c_68) = [0] p(c_69) = [0] p(c_70) = [2] p(c_71) = [4] p(c_72) = [4] p(c_73) = [0] p(c_74) = [1] p(c_75) = [0] p(c_76) = [1] p(c_77) = [1] p(c_78) = [1] p(c_79) = [4] x1 + [3] p(c_80) = [2] x1 + [3] p(c_81) = [1] p(c_82) = [1] p(c_83) = [1] p(c_84) = [2] p(c_85) = [1] p(c_86) = [1] p(c_87) = [4] x1 + [1] x2 + [1] x3 + [1] p(c_88) = [0] p(c_89) = [0] p(c_90) = [0] Following rules are strictly oriented: 'eq#('neg(x),'neg(y)) = [2] y + [2] > [2] y + [0] = c_28('eq#(x,y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('pos(x),'pos(y)) = [2] y + [10] >= [2] y + [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [2] y + [0] >= [2] y + [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [2] y'1 + [2] y'2 + [0] >= [2] y'1 + [2] y'2 + [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [4] y + [2] >= [4] y + [2] = c_39('eq#(x,y)) 'mod#(x,y) = [3] >= [3] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [0] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [0] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [0] >= [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [0] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [3] >= [3] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [3] >= [3] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [3] >= [3] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [3] >= [3] = filter#(x,xs) filter#(p,dd(x,xs)) = [3] >= [2] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [3] >= [3] = 'mod#(x,p) filter#(p,dd(x,xs)) = [3] >= [3] = filter#(p,xs) **** Step 7.b:1.b:1.a:12: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult# ,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [4] p('and) = [4] x2 + [4] p('div) = [4] x1 + [5] x2 + [2] p('divByZero) = [0] p('divsub) = [0] p('eq) = [1] x1 + [1] x2 + [2] p('equal) = [0] p('false) = [0] p('mod) = [1] x2 + [0] p('mult) = [1] x1 + [1] x2 + [0] p('natadd) = [2] x1 + [2] x2 + [4] p('natdiv) = [1] x1 + [6] p('natdiv') = [2] x2 + [2] p('natmult) = [1] x2 + [2] p('natsub) = [1] x2 + [0] p('neg) = [1] x1 + [0] p('negative) = [1] p('pos) = [1] x1 + [0] p('positive) = [2] p('pred) = [2] p('s) = [1] x1 + [4] p('sub) = [1] x1 + [2] x2 + [4] p('succ) = [4] p('true) = [1] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [1] p(filter) = [1] x2 + [0] p(filter') = [1] x2 + [1] x3 + [0] p(nil) = [1] p('add#) = [0] p('and#) = [1] x1 + [0] p('div#) = [4] x2 + [0] p('divsub#) = [1] p('eq#) = [0] p('equal#) = [2] x2 + [0] p('mod#) = [4] x1 + [5] x2 + [0] p('mult#) = [1] x1 + [0] p('natadd#) = [4] x1 + [1] x2 + [0] p('natdiv#) = [0] p('natdiv'#) = [0] p('natmult#) = [1] x1 + [0] p('natsub#) = [1] x1 + [4] x2 + [4] p('negative#) = [0] p('positive#) = [4] p('pred#) = [0] p('sub#) = [1] x1 + [0] p('succ#) = [2] p(eratos#) = [5] x1 + [0] p(filter#) = [5] x1 + [4] x2 + [0] p(filter'#) = [0] p(c_1) = [0] p(c_2) = [4] p(c_3) = [1] x1 + [0] p(c_4) = [0] p(c_5) = [4] x1 + [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [2] p(c_10) = [0] p(c_11) = [4] p(c_12) = [0] p(c_13) = [1] p(c_14) = [4] x1 + [0] p(c_15) = [2] x1 + [0] p(c_16) = [1] p(c_17) = [2] x1 + [0] p(c_18) = [1] x1 + [0] p(c_19) = [0] p(c_20) = [0] p(c_21) = [1] p(c_22) = [1] p(c_23) = [1] p(c_24) = [1] p(c_25) = [0] p(c_26) = [0] p(c_27) = [2] p(c_28) = [1] x1 + [0] p(c_29) = [2] p(c_30) = [4] p(c_31) = [0] p(c_32) = [4] x1 + [0] p(c_33) = [0] p(c_34) = [1] x1 + [0] p(c_35) = [4] x1 + [1] x2 + [0] p(c_36) = [2] p(c_37) = [0] p(c_38) = [0] p(c_39) = [4] x1 + [0] p(c_40) = [4] x1 + [1] x2 + [1] x3 + [0] p(c_41) = [2] p(c_42) = [4] p(c_43) = [4] p(c_44) = [1] p(c_45) = [1] x1 + [0] p(c_46) = [1] x1 + [0] p(c_47) = [0] p(c_48) = [1] x1 + [0] p(c_49) = [1] x1 + [0] p(c_50) = [4] p(c_51) = [0] p(c_52) = [2] p(c_53) = [1] p(c_54) = [0] p(c_55) = [2] x1 + [0] p(c_56) = [1] p(c_57) = [0] p(c_58) = [4] x1 + [0] p(c_59) = [1] p(c_60) = [1] p(c_61) = [1] x1 + [0] p(c_62) = [0] p(c_63) = [1] p(c_64) = [0] p(c_65) = [0] p(c_66) = [1] p(c_67) = [1] p(c_68) = [0] p(c_69) = [4] p(c_70) = [0] p(c_71) = [1] p(c_72) = [2] p(c_73) = [0] p(c_74) = [2] p(c_75) = [0] p(c_76) = [1] p(c_77) = [0] p(c_78) = [4] p(c_79) = [4] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [1] p(c_82) = [0] p(c_83) = [4] p(c_84) = [0] p(c_85) = [0] p(c_86) = [0] p(c_87) = [1] x2 + [0] p(c_88) = [1] p(c_89) = [1] p(c_90) = [2] Following rules are strictly oriented: 'natmult#('s(x),y) = [1] x + [4] > [1] x + [0] = c_61('natmult#(x,y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [4] y + [0] >= [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [4] y + [0] >= [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [4] y + [0] >= [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [4] y + [0] >= [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [2] y + [0] >= [0] = c_39('eq#(x,y)) 'mod#(x,y) = [4] x + [5] y + [0] >= [4] x + [5] y + [0] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [1] x + [0] >= [1] x + [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [1] x + [0] >= [1] x + [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [1] x + [0] >= [1] x + [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [1] x + [0] >= [1] x + [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [0] >= [0] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) = [0] >= [0] = c_58('natdiv#('s(x),y)) 'sub#(x,'neg(y)) = [1] x + [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [1] x + [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [5] x + [5] xs + [0] >= [5] xs + [0] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [5] x + [5] xs + [0] >= [5] x + [4] xs + [0] = filter#(x,xs) filter#(p,dd(x,xs)) = [5] p + [4] x + [4] xs + [0] >= [0] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [5] p + [4] x + [4] xs + [0] >= [5] p + [4] x + [0] = 'mod#(x,p) filter#(p,dd(x,xs)) = [5] p + [4] x + [4] xs + [0] >= [5] p + [4] xs + [0] = filter#(p,xs) filter(p,dd(x,xs)) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [1] >= [1] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [0] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:13: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'divsub,filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'# ,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [1] x1 + [4] x2 + [0] p('and) = [1] x2 + [0] p('div) = [4] x1 + [0] p('divByZero) = [0] p('divsub) = [1] x1 + [0] p('eq) = [1] p('equal) = [3] x1 + [2] p('false) = [4] p('mod) = [2] x1 + [1] p('mult) = [2] x1 + [1] x2 + [5] p('natadd) = [5] x1 + [4] p('natdiv) = [2] x1 + [1] x2 + [1] p('natdiv') = [4] x2 + [2] p('natmult) = [0] p('natsub) = [1] p('neg) = [1] x1 + [3] p('negative) = [1] p('pos) = [1] x1 + [0] p('positive) = [0] p('pred) = [2] p('s) = [1] x1 + [2] p('sub) = [2] x1 + [6] p('succ) = [1] x1 + [0] p('true) = [0] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [2] p(eratos) = [1] x1 + [0] p(filter) = [1] x2 + [0] p(filter') = [1] x2 + [1] x3 + [2] p(nil) = [0] p('add#) = [0] p('and#) = [1] x1 + [1] p('div#) = [1] x1 + [4] x2 + [0] p('divsub#) = [2] x1 + [0] p('eq#) = [0] p('equal#) = [0] p('mod#) = [3] x1 + [5] x2 + [0] p('mult#) = [0] p('natadd#) = [0] p('natdiv#) = [1] x1 + [0] p('natdiv'#) = [1] x1 + [0] p('natmult#) = [0] p('natsub#) = [1] x1 + [1] x2 + [0] p('negative#) = [1] x1 + [1] p('positive#) = [1] x1 + [4] p('pred#) = [0] p('sub#) = [1] x1 + [0] p('succ#) = [0] p(eratos#) = [5] x1 + [0] p(filter#) = [5] x1 + [4] x2 + [1] p(filter'#) = [0] p(c_1) = [1] p(c_2) = [0] p(c_3) = [4] x1 + [0] p(c_4) = [2] x1 + [2] p(c_5) = [1] x1 + [0] p(c_6) = [1] p(c_7) = [2] p(c_8) = [2] p(c_9) = [1] p(c_10) = [0] p(c_11) = [1] p(c_12) = [2] p(c_13) = [4] p(c_14) = [1] x1 + [0] p(c_15) = [1] x1 + [0] p(c_16) = [0] p(c_17) = [1] x1 + [6] p(c_18) = [1] x1 + [0] p(c_19) = [0] p(c_20) = [1] p(c_21) = [0] p(c_22) = [4] x1 + [0] p(c_23) = [1] p(c_24) = [1] p(c_25) = [4] p(c_26) = [0] p(c_27) = [4] p(c_28) = [2] x1 + [0] p(c_29) = [4] p(c_30) = [4] p(c_31) = [1] p(c_32) = [4] x1 + [0] p(c_33) = [2] p(c_34) = [1] x1 + [0] p(c_35) = [1] x1 + [2] x2 + [0] p(c_36) = [2] p(c_37) = [1] p(c_38) = [1] p(c_39) = [4] x1 + [0] p(c_40) = [2] x1 + [2] x2 + [1] x3 + [0] p(c_41) = [0] p(c_42) = [0] p(c_43) = [1] p(c_44) = [2] p(c_45) = [1] x1 + [0] p(c_46) = [1] x1 + [0] p(c_47) = [4] p(c_48) = [2] x1 + [0] p(c_49) = [1] x1 + [0] p(c_50) = [0] p(c_51) = [1] x1 + [1] p(c_52) = [0] p(c_53) = [0] p(c_54) = [0] p(c_55) = [1] x1 + [0] p(c_56) = [1] p(c_57) = [0] p(c_58) = [1] x1 + [0] p(c_59) = [0] p(c_60) = [4] p(c_61) = [4] x1 + [0] p(c_62) = [1] p(c_63) = [0] p(c_64) = [0] p(c_65) = [4] x1 + [0] p(c_66) = [0] p(c_67) = [1] p(c_68) = [1] p(c_69) = [0] p(c_70) = [4] p(c_71) = [1] p(c_72) = [1] p(c_73) = [4] p(c_74) = [1] p(c_75) = [0] p(c_76) = [1] p(c_77) = [0] p(c_78) = [1] p(c_79) = [4] x1 + [0] p(c_80) = [1] x1 + [0] p(c_81) = [1] p(c_82) = [1] p(c_83) = [2] p(c_84) = [0] p(c_85) = [1] x2 + [0] p(c_86) = [1] p(c_87) = [1] x1 + [4] x2 + [4] x3 + [4] p(c_88) = [1] p(c_89) = [1] p(c_90) = [4] Following rules are strictly oriented: 'natdiv#('s(x),'s(y)) = [1] x + [2] > [1] x + [0] = c_55('natdiv'#('divsub(x,y),'s(y))) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [1] x + [4] y + [15] >= [1] x + [0] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [1] x + [4] y + [3] >= [1] x + [0] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [1] x + [4] y + [12] >= [1] x + [6] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [1] x + [4] y + [0] >= [1] x + [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [0] >= [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [0] >= [0] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [0] >= [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [0] >= [0] = c_39('eq#(x,y)) 'mod#(x,y) = [3] x + [5] y + [0] >= [3] x + [4] y + [0] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [0] >= [0] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [0] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [0] >= [0] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [0] >= [0] = c_49('natmult#(x,y)) 'natdiv'#('s(x),y) = [1] x + [2] >= [1] x + [2] = c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [1] x + [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [1] x + [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [5] x + [5] xs + [10] >= [5] xs + [0] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [5] x + [5] xs + [10] >= [5] x + [4] xs + [1] = filter#(x,xs) filter#(p,dd(x,xs)) = [5] p + [4] x + [4] xs + [9] >= [0] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [5] p + [4] x + [4] xs + [9] >= [5] p + [3] x + [0] = 'mod#(x,p) filter#(p,dd(x,xs)) = [5] p + [4] x + [4] xs + [9] >= [5] p + [4] xs + [1] = filter#(p,xs) 'divsub('0(),'0()) = [0] >= [0] = '0() 'divsub('0(),'s(y)) = [0] >= [0] = 'underflow() 'divsub('s(x),'0()) = [1] x + [2] >= [1] x + [2] = 's(x) 'divsub('s(x),'s(y)) = [1] x + [2] >= [1] x + [0] = 'divsub(x,y) filter(p,dd(x,xs)) = [1] x + [1] xs + [2] >= [1] x + [1] xs + [2] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [0] >= [0] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [2] >= [1] x + [1] xs + [2] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [2] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:14: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_3) = {1}, uargs(c_5) = {1}, uargs(c_14) = {1}, uargs(c_15) = {1}, uargs(c_17) = {1}, uargs(c_18) = {1}, uargs(c_28) = {1}, uargs(c_32) = {1}, uargs(c_34) = {1}, uargs(c_35) = {1,2}, uargs(c_39) = {1}, uargs(c_40) = {1,2,3}, uargs(c_45) = {1}, uargs(c_46) = {1}, uargs(c_48) = {1}, uargs(c_49) = {1}, uargs(c_55) = {1}, uargs(c_58) = {1}, uargs(c_61) = {1}, uargs(c_79) = {1}, uargs(c_80) = {1} Following symbols are considered usable: {'divsub,filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'# ,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [1] x1 + [4] x2 + [6] p('and) = [1] x1 + [3] p('div) = [0] p('divByZero) = [0] p('divsub) = [1] x1 + [0] p('eq) = [5] x1 + [4] p('equal) = [1] p('false) = [5] p('mod) = [2] p('mult) = [4] x1 + [0] p('natadd) = [3] x1 + [1] p('natdiv) = [6] x2 + [4] p('natdiv') = [2] x2 + [2] p('natmult) = [4] p('natsub) = [4] x1 + [1] x2 + [0] p('neg) = [1] x1 + [1] p('negative) = [4] p('pos) = [1] x1 + [1] p('positive) = [2] x1 + [0] p('pred) = [2] p('s) = [1] x1 + [1] p('sub) = [4] x1 + [4] p('succ) = [4] p('true) = [1] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [4] p(filter) = [1] x2 + [0] p(filter') = [1] x2 + [1] x3 + [0] p(nil) = [0] p('add#) = [0] p('and#) = [0] p('div#) = [4] x1 + [4] x2 + [0] p('divsub#) = [0] p('eq#) = [2] x2 + [0] p('equal#) = [6] x2 + [0] p('mod#) = [4] x1 + [4] x2 + [4] p('mult#) = [1] p('natadd#) = [2] x1 + [1] p('natdiv#) = [4] x1 + [4] x2 + [0] p('natdiv'#) = [4] x1 + [4] x2 + [1] p('natmult#) = [0] p('natsub#) = [1] x2 + [0] p('negative#) = [1] x1 + [2] p('positive#) = [1] x1 + [2] p('pred#) = [2] x1 + [0] p('sub#) = [0] p('succ#) = [1] x1 + [1] p(eratos#) = [4] x1 + [4] p(filter#) = [4] x1 + [4] x2 + [4] p(filter'#) = [1] x3 + [1] p(c_1) = [0] p(c_2) = [1] x1 + [0] p(c_3) = [2] x1 + [0] p(c_4) = [1] x1 + [2] p(c_5) = [2] x1 + [0] p(c_6) = [1] p(c_7) = [0] p(c_8) = [0] p(c_9) = [4] p(c_10) = [1] p(c_11) = [1] p(c_12) = [1] p(c_13) = [0] p(c_14) = [1] x1 + [1] p(c_15) = [1] x1 + [2] p(c_16) = [1] p(c_17) = [1] x1 + [0] p(c_18) = [1] x1 + [0] p(c_19) = [1] p(c_20) = [1] p(c_21) = [1] p(c_22) = [1] p(c_23) = [1] p(c_24) = [1] p(c_25) = [0] p(c_26) = [1] p(c_27) = [1] p(c_28) = [1] x1 + [0] p(c_29) = [1] p(c_30) = [2] p(c_31) = [2] p(c_32) = [1] x1 + [2] p(c_33) = [0] p(c_34) = [1] x1 + [0] p(c_35) = [1] x1 + [1] x2 + [0] p(c_36) = [1] p(c_37) = [0] p(c_38) = [2] p(c_39) = [2] x1 + [0] p(c_40) = [4] x1 + [2] x2 + [1] x3 + [2] p(c_41) = [4] p(c_42) = [0] p(c_43) = [0] p(c_44) = [0] p(c_45) = [1] x1 + [1] p(c_46) = [1] x1 + [0] p(c_47) = [0] p(c_48) = [4] x1 + [1] p(c_49) = [1] x1 + [0] p(c_50) = [4] p(c_51) = [1] x1 + [1] p(c_52) = [1] p(c_53) = [0] p(c_54) = [0] p(c_55) = [1] x1 + [3] p(c_56) = [4] p(c_57) = [4] p(c_58) = [1] x1 + [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [1] x1 + [0] p(c_62) = [2] p(c_63) = [1] p(c_64) = [4] p(c_65) = [0] p(c_66) = [0] p(c_67) = [1] p(c_68) = [1] p(c_69) = [0] p(c_70) = [0] p(c_71) = [2] p(c_72) = [1] p(c_73) = [0] p(c_74) = [4] p(c_75) = [0] p(c_76) = [1] p(c_77) = [0] p(c_78) = [0] p(c_79) = [4] x1 + [0] p(c_80) = [4] x1 + [0] p(c_81) = [1] p(c_82) = [0] p(c_83) = [0] p(c_84) = [4] p(c_85) = [0] p(c_86) = [4] p(c_87) = [1] x1 + [4] x2 + [1] x3 + [4] p(c_88) = [0] p(c_89) = [0] p(c_90) = [1] Following rules are strictly oriented: 'natdiv'#('s(x),y) = [4] x + [4] y + [5] > [4] x + [4] y + [4] = c_58('natdiv#('s(x),y)) Following rules are (at-least) weakly oriented: 'add#('neg('s('s(x))),y) = [0] >= [0] = c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) = [0] >= [0] = c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) = [4] x + [4] y + [8] >= [4] x + [4] y + [1] = c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) = [4] x + [4] y + [8] >= [4] x + [4] y + [2] = c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) = [4] x + [4] y + [8] >= [4] x + [4] y + [0] = c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) = [4] x + [4] y + [8] >= [4] x + [4] y + [0] = c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) = [2] y + [2] >= [2] y + [0] = c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) = [2] y + [2] >= [2] y + [2] = c_32('eq#(x,y)) 'eq#('s(x),'s(y)) = [2] y + [2] >= [2] y + [0] = c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) = [2] y'1 + [2] y'2 + [0] >= [2] y'1 + [2] y'2 + [0] = c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) = [6] y + [0] >= [4] y + [0] = c_39('eq#(x,y)) 'mod#(x,y) = [4] x + [4] y + [4] >= [4] x + [4] y + [4] = c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) = [1] >= [1] = c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) = [1] >= [0] = c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) = [1] >= [1] = c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) = [1] >= [0] = c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) = [4] x + [4] y + [8] >= [4] x + [4] y + [8] = c_55('natdiv'#('divsub(x,y),'s(y))) 'natmult#('s(x),y) = [0] >= [0] = c_61('natmult#(x,y)) 'sub#(x,'neg(y)) = [0] >= [0] = c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) = [0] >= [0] = c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) = [4] x + [4] xs + [4] >= [4] xs + [4] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [4] x + [4] xs + [4] >= [4] x + [4] xs + [4] = filter#(x,xs) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [4] >= [0] = 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [4] >= [4] p + [4] x + [4] = 'mod#(x,p) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [4] >= [4] p + [4] xs + [4] = filter#(p,xs) 'divsub('0(),'0()) = [0] >= [0] = '0() 'divsub('0(),'s(y)) = [0] >= [0] = 'underflow() 'divsub('s(x),'0()) = [1] x + [1] >= [1] x + [1] = 's(x) 'divsub('s(x),'s(y)) = [1] x + [1] >= [1] x + [0] = 'divsub(x,y) filter(p,dd(x,xs)) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [0] >= [0] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [0] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.a:15: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: 'add#('neg('s('s(x))),y) -> c_3('add#('pos('s(x)),y)) 'add#('pos('s('s(x))),y) -> c_5('add#('pos('s(x)),y)) 'div#('neg(x),'neg(y)) -> c_14('natdiv#(x,y)) 'div#('neg(x),'pos(y)) -> c_15('natdiv#(x,y)) 'div#('pos(x),'neg(y)) -> c_17('natdiv#(x,y)) 'div#('pos(x),'pos(y)) -> c_18('natdiv#(x,y)) 'eq#('neg(x),'neg(y)) -> c_28('eq#(x,y)) 'eq#('pos(x),'pos(y)) -> c_32('eq#(x,y)) 'eq#('s(x),'s(y)) -> c_34('eq#(x,y)) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> c_35('eq#(x'1,y'1),'eq#(x'2,y'2)) 'equal#(x,y) -> c_39('eq#(x,y)) 'mod#(x,y) -> c_40('sub#(x,'mult(y,'div(x,y))),'mult#(y,'div(x,y)),'div#(x,y)) 'mult#('neg(x),'neg(y)) -> c_45('natmult#(x,y)) 'mult#('neg(x),'pos(y)) -> c_46('natmult#(x,y)) 'mult#('pos(x),'neg(y)) -> c_48('natmult#(x,y)) 'mult#('pos(x),'pos(y)) -> c_49('natmult#(x,y)) 'natdiv#('s(x),'s(y)) -> c_55('natdiv'#('divsub(x,y),'s(y))) 'natdiv'#('s(x),y) -> c_58('natdiv#('s(x),y)) 'natmult#('s(x),y) -> c_61('natmult#(x,y)) 'sub#(x,'neg(y)) -> c_79('add#(x,'pos(y))) 'sub#(x,'pos(y)) -> c_80('add#(x,'neg(y))) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/1,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/1,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). **** Step 7.b:1.b:1.b:1: RemoveWeakSuffixes WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) - Weak DPs: 'add#('neg('s('s(x))),y) -> 'add#('pos('s(x)),y) 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y) 'div#('neg(x),'neg(y)) -> 'natdiv#(x,y) 'div#('neg(x),'pos(y)) -> 'natdiv#(x,y) 'div#('pos(x),'neg(y)) -> 'natdiv#(x,y) 'div#('pos(x),'pos(y)) -> 'natdiv#(x,y) 'eq#('neg(x),'neg(y)) -> 'eq#(x,y) 'eq#('pos(x),'pos(y)) -> 'eq#(x,y) 'eq#('s(x),'s(y)) -> 'eq#(x,y) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1) 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2) 'equal#(x,y) -> 'eq#(x,y) 'mod#(x,y) -> 'div#(x,y) 'mod#(x,y) -> 'mult#(y,'div(x,y)) 'mod#(x,y) -> 'sub#(x,'mult(y,'div(x,y))) 'mult#('neg(x),'neg(y)) -> 'natmult#(x,y) 'mult#('neg(x),'pos(y)) -> 'natmult#(x,y) 'mult#('pos(x),'neg(y)) -> 'natmult#(x,y) 'mult#('pos(x),'pos(y)) -> 'natmult#(x,y) 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y) 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) -> 'natdiv#('s(x),y) 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) -> 'natmult#(x,y) 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) 'sub#(x,'neg(y)) -> 'add#(x,'pos(y)) 'sub#(x,'pos(y)) -> 'add#(x,'neg(y)) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: RemoveWeakSuffixes + Details: Consider the dependency graph 1:S:'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) -->_1 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)):1 2:S:'natadd#('s(x),y) -> c_51('natadd#(x,y)) -->_1 'natadd#('s(x),y) -> c_51('natadd#(x,y)):2 3:W:'add#('neg('s('s(x))),y) -> 'add#('pos('s(x)),y) -->_1 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y):4 4:W:'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y) -->_1 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y):4 5:W:'div#('neg(x),'neg(y)) -> 'natdiv#(x,y) -->_1 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)):23 -->_1 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y):22 6:W:'div#('neg(x),'pos(y)) -> 'natdiv#(x,y) -->_1 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)):23 -->_1 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y):22 7:W:'div#('pos(x),'neg(y)) -> 'natdiv#(x,y) -->_1 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)):23 -->_1 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y):22 8:W:'div#('pos(x),'pos(y)) -> 'natdiv#(x,y) -->_1 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)):23 -->_1 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y):22 9:W:'eq#('neg(x),'neg(y)) -> 'eq#(x,y) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2):13 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1):12 -->_1 'eq#('s(x),'s(y)) -> 'eq#(x,y):11 -->_1 'eq#('pos(x),'pos(y)) -> 'eq#(x,y):10 -->_1 'eq#('neg(x),'neg(y)) -> 'eq#(x,y):9 10:W:'eq#('pos(x),'pos(y)) -> 'eq#(x,y) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2):13 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1):12 -->_1 'eq#('s(x),'s(y)) -> 'eq#(x,y):11 -->_1 'eq#('pos(x),'pos(y)) -> 'eq#(x,y):10 -->_1 'eq#('neg(x),'neg(y)) -> 'eq#(x,y):9 11:W:'eq#('s(x),'s(y)) -> 'eq#(x,y) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2):13 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1):12 -->_1 'eq#('s(x),'s(y)) -> 'eq#(x,y):11 -->_1 'eq#('pos(x),'pos(y)) -> 'eq#(x,y):10 -->_1 'eq#('neg(x),'neg(y)) -> 'eq#(x,y):9 12:W:'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2):13 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1):12 -->_1 'eq#('s(x),'s(y)) -> 'eq#(x,y):11 -->_1 'eq#('pos(x),'pos(y)) -> 'eq#(x,y):10 -->_1 'eq#('neg(x),'neg(y)) -> 'eq#(x,y):9 13:W:'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2):13 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1):12 -->_1 'eq#('s(x),'s(y)) -> 'eq#(x,y):11 -->_1 'eq#('pos(x),'pos(y)) -> 'eq#(x,y):10 -->_1 'eq#('neg(x),'neg(y)) -> 'eq#(x,y):9 14:W:'equal#(x,y) -> 'eq#(x,y) -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2):13 -->_1 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1):12 -->_1 'eq#('s(x),'s(y)) -> 'eq#(x,y):11 -->_1 'eq#('pos(x),'pos(y)) -> 'eq#(x,y):10 -->_1 'eq#('neg(x),'neg(y)) -> 'eq#(x,y):9 15:W:'mod#(x,y) -> 'div#(x,y) -->_1 'div#('pos(x),'pos(y)) -> 'natdiv#(x,y):8 -->_1 'div#('pos(x),'neg(y)) -> 'natdiv#(x,y):7 -->_1 'div#('neg(x),'pos(y)) -> 'natdiv#(x,y):6 -->_1 'div#('neg(x),'neg(y)) -> 'natdiv#(x,y):5 16:W:'mod#(x,y) -> 'mult#(y,'div(x,y)) -->_1 'mult#('pos(x),'pos(y)) -> 'natmult#(x,y):21 -->_1 'mult#('pos(x),'neg(y)) -> 'natmult#(x,y):20 -->_1 'mult#('neg(x),'pos(y)) -> 'natmult#(x,y):19 -->_1 'mult#('neg(x),'neg(y)) -> 'natmult#(x,y):18 17:W:'mod#(x,y) -> 'sub#(x,'mult(y,'div(x,y))) -->_1 'sub#(x,'pos(y)) -> 'add#(x,'neg(y)):29 -->_1 'sub#(x,'neg(y)) -> 'add#(x,'pos(y)):28 18:W:'mult#('neg(x),'neg(y)) -> 'natmult#(x,y) -->_1 'natmult#('s(x),y) -> 'natmult#(x,y):26 -->_1 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)):25 19:W:'mult#('neg(x),'pos(y)) -> 'natmult#(x,y) -->_1 'natmult#('s(x),y) -> 'natmult#(x,y):26 -->_1 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)):25 20:W:'mult#('pos(x),'neg(y)) -> 'natmult#(x,y) -->_1 'natmult#('s(x),y) -> 'natmult#(x,y):26 -->_1 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)):25 21:W:'mult#('pos(x),'pos(y)) -> 'natmult#(x,y) -->_1 'natmult#('s(x),y) -> 'natmult#(x,y):26 -->_1 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)):25 22:W:'natdiv#('s(x),'s(y)) -> 'divsub#(x,y) -->_1 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)):1 23:W:'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)) -->_1 'natdiv'#('s(x),y) -> 'natdiv#('s(x),y):24 24:W:'natdiv'#('s(x),y) -> 'natdiv#('s(x),y) -->_1 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)):23 -->_1 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y):22 25:W:'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)) -->_1 'natadd#('s(x),y) -> c_51('natadd#(x,y)):2 26:W:'natmult#('s(x),y) -> 'natmult#(x,y) -->_1 'natmult#('s(x),y) -> 'natmult#(x,y):26 -->_1 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)):25 27:W:'natsub#('s(x),'s(y)) -> 'natsub#(x,y) -->_1 'natsub#('s(x),'s(y)) -> 'natsub#(x,y):27 28:W:'sub#(x,'neg(y)) -> 'add#(x,'pos(y)) -->_1 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y):4 -->_1 'add#('neg('s('s(x))),y) -> 'add#('pos('s(x)),y):3 29:W:'sub#(x,'pos(y)) -> 'add#(x,'neg(y)) -->_1 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y):4 -->_1 'add#('neg('s('s(x))),y) -> 'add#('pos('s(x)),y):3 30:W:eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) -->_1 eratos#(dd(x,xs)) -> filter#(x,xs):31 -->_1 eratos#(dd(x,xs)) -> eratos#(filter(x,xs)):30 31:W:eratos#(dd(x,xs)) -> filter#(x,xs) -->_1 filter#(p,dd(x,xs)) -> filter#(p,xs):34 -->_1 filter#(p,dd(x,xs)) -> 'mod#(x,p):33 -->_1 filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()):32 32:W:filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) -->_1 'equal#(x,y) -> 'eq#(x,y):14 33:W:filter#(p,dd(x,xs)) -> 'mod#(x,p) -->_1 'mod#(x,y) -> 'sub#(x,'mult(y,'div(x,y))):17 -->_1 'mod#(x,y) -> 'mult#(y,'div(x,y)):16 -->_1 'mod#(x,y) -> 'div#(x,y):15 34:W:filter#(p,dd(x,xs)) -> filter#(p,xs) -->_1 filter#(p,dd(x,xs)) -> filter#(p,xs):34 -->_1 filter#(p,dd(x,xs)) -> 'mod#(x,p):33 -->_1 filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()):32 The following weak DPs constitute a sub-graph of the DG that is closed under successors. The DPs are removed. 32: filter#(p,dd(x,xs)) -> 'equal#('mod(x,p),'0()) 27: 'natsub#('s(x),'s(y)) -> 'natsub#(x,y) 17: 'mod#(x,y) -> 'sub#(x,'mult(y,'div(x,y))) 28: 'sub#(x,'neg(y)) -> 'add#(x,'pos(y)) 29: 'sub#(x,'pos(y)) -> 'add#(x,'neg(y)) 14: 'equal#(x,y) -> 'eq#(x,y) 9: 'eq#('neg(x),'neg(y)) -> 'eq#(x,y) 13: 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'2,y'2) 12: 'eq#(dd(x'1,x'2),dd(y'1,y'2)) -> 'eq#(x'1,y'1) 11: 'eq#('s(x),'s(y)) -> 'eq#(x,y) 10: 'eq#('pos(x),'pos(y)) -> 'eq#(x,y) 3: 'add#('neg('s('s(x))),y) -> 'add#('pos('s(x)),y) 4: 'add#('pos('s('s(x))),y) -> 'add#('pos('s(x)),y) **** Step 7.b:1.b:1.b:2: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) - Weak DPs: 'div#('neg(x),'neg(y)) -> 'natdiv#(x,y) 'div#('neg(x),'pos(y)) -> 'natdiv#(x,y) 'div#('pos(x),'neg(y)) -> 'natdiv#(x,y) 'div#('pos(x),'pos(y)) -> 'natdiv#(x,y) 'mod#(x,y) -> 'div#(x,y) 'mod#(x,y) -> 'mult#(y,'div(x,y)) 'mult#('neg(x),'neg(y)) -> 'natmult#(x,y) 'mult#('neg(x),'pos(y)) -> 'natmult#(x,y) 'mult#('pos(x),'neg(y)) -> 'natmult#(x,y) 'mult#('pos(x),'pos(y)) -> 'natmult#(x,y) 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y) 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) -> 'natdiv#('s(x),y) 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) -> 'natmult#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_22) = {1}, uargs(c_51) = {1} Following symbols are considered usable: {'divsub,filter,filter','add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'# ,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [1] p('add) = [2] x2 + [7] p('and) = [3] x1 + [1] p('div) = [2] x2 + [1] p('divByZero) = [0] p('divsub) = [1] x1 + [1] p('eq) = [2] x2 + [0] p('equal) = [2] x1 + [4] x2 + [4] p('false) = [1] p('mod) = [4] x2 + [1] p('mult) = [6] x2 + [0] p('natadd) = [1] x2 + [0] p('natdiv) = [0] p('natdiv') = [0] p('natmult) = [2] p('natsub) = [0] p('neg) = [1] x1 + [2] p('negative) = [0] p('pos) = [1] x1 + [2] p('positive) = [0] p('pred) = [3] p('s) = [1] x1 + [1] p('sub) = [0] p('succ) = [1] x1 + [0] p('true) = [0] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [0] p(eratos) = [0] p(filter) = [1] x2 + [0] p(filter') = [1] x2 + [1] x3 + [0] p(nil) = [4] p('add#) = [0] p('and#) = [0] p('div#) = [4] x1 + [1] x2 + [0] p('divsub#) = [4] x1 + [0] p('eq#) = [0] p('equal#) = [0] p('mod#) = [4] x1 + [4] x2 + [1] p('mult#) = [1] p('natadd#) = [0] p('natdiv#) = [4] x1 + [4] p('natdiv'#) = [4] x1 + [4] p('natmult#) = [1] p('natsub#) = [0] p('negative#) = [0] p('positive#) = [0] p('pred#) = [0] p('sub#) = [0] p('succ#) = [0] p(eratos#) = [4] x1 + [1] p(filter#) = [4] x1 + [4] x2 + [1] p(filter'#) = [0] p(c_1) = [0] p(c_2) = [0] p(c_3) = [0] p(c_4) = [0] p(c_5) = [1] x1 + [0] p(c_6) = [0] p(c_7) = [0] p(c_8) = [0] p(c_9) = [0] p(c_10) = [0] p(c_11) = [0] p(c_12) = [0] p(c_13) = [0] p(c_14) = [0] p(c_15) = [0] p(c_16) = [0] p(c_17) = [0] p(c_18) = [0] p(c_19) = [0] p(c_20) = [0] p(c_21) = [0] p(c_22) = [1] x1 + [0] p(c_23) = [0] p(c_24) = [0] p(c_25) = [0] p(c_26) = [0] p(c_27) = [0] p(c_28) = [0] p(c_29) = [0] p(c_30) = [0] p(c_31) = [0] p(c_32) = [0] p(c_33) = [0] p(c_34) = [0] p(c_35) = [0] p(c_36) = [0] p(c_37) = [0] p(c_38) = [0] p(c_39) = [0] p(c_40) = [0] p(c_41) = [0] p(c_42) = [0] p(c_43) = [0] p(c_44) = [0] p(c_45) = [0] p(c_46) = [0] p(c_47) = [0] p(c_48) = [0] p(c_49) = [0] p(c_50) = [0] p(c_51) = [1] x1 + [0] p(c_52) = [0] p(c_53) = [0] p(c_54) = [0] p(c_55) = [0] p(c_56) = [0] p(c_57) = [0] p(c_58) = [0] p(c_59) = [0] p(c_60) = [0] p(c_61) = [0] p(c_62) = [0] p(c_63) = [0] p(c_64) = [0] p(c_65) = [0] p(c_66) = [0] p(c_67) = [0] p(c_68) = [2] p(c_69) = [0] p(c_70) = [0] p(c_71) = [0] p(c_72) = [0] p(c_73) = [0] p(c_74) = [0] p(c_75) = [0] p(c_76) = [0] p(c_77) = [0] p(c_78) = [0] p(c_79) = [0] p(c_80) = [0] p(c_81) = [0] p(c_82) = [0] p(c_83) = [0] p(c_84) = [0] p(c_85) = [0] p(c_86) = [0] p(c_87) = [0] p(c_88) = [0] p(c_89) = [1] p(c_90) = [0] Following rules are strictly oriented: 'divsub#('s(x),'s(y)) = [4] x + [4] > [4] x + [0] = c_22('divsub#(x,y)) Following rules are (at-least) weakly oriented: 'div#('neg(x),'neg(y)) = [4] x + [1] y + [10] >= [4] x + [4] = 'natdiv#(x,y) 'div#('neg(x),'pos(y)) = [4] x + [1] y + [10] >= [4] x + [4] = 'natdiv#(x,y) 'div#('pos(x),'neg(y)) = [4] x + [1] y + [10] >= [4] x + [4] = 'natdiv#(x,y) 'div#('pos(x),'pos(y)) = [4] x + [1] y + [10] >= [4] x + [4] = 'natdiv#(x,y) 'mod#(x,y) = [4] x + [4] y + [1] >= [4] x + [1] y + [0] = 'div#(x,y) 'mod#(x,y) = [4] x + [4] y + [1] >= [1] = 'mult#(y,'div(x,y)) 'mult#('neg(x),'neg(y)) = [1] >= [1] = 'natmult#(x,y) 'mult#('neg(x),'pos(y)) = [1] >= [1] = 'natmult#(x,y) 'mult#('pos(x),'neg(y)) = [1] >= [1] = 'natmult#(x,y) 'mult#('pos(x),'pos(y)) = [1] >= [1] = 'natmult#(x,y) 'natadd#('s(x),y) = [0] >= [0] = c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) = [4] x + [8] >= [4] x + [0] = 'divsub#(x,y) 'natdiv#('s(x),'s(y)) = [4] x + [8] >= [4] x + [8] = 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) = [4] x + [8] >= [4] x + [8] = 'natdiv#('s(x),y) 'natmult#('s(x),y) = [1] >= [0] = 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) = [1] >= [1] = 'natmult#(x,y) eratos#(dd(x,xs)) = [4] x + [4] xs + [1] >= [4] xs + [1] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [4] x + [4] xs + [1] >= [4] x + [4] xs + [1] = filter#(x,xs) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [1] >= [4] p + [4] x + [1] = 'mod#(x,p) filter#(p,dd(x,xs)) = [4] p + [4] x + [4] xs + [1] >= [4] p + [4] xs + [1] = filter#(p,xs) 'divsub('0(),'0()) = [2] >= [1] = '0() 'divsub('0(),'s(y)) = [2] >= [0] = 'underflow() 'divsub('s(x),'0()) = [1] x + [2] >= [1] x + [1] = 's(x) 'divsub('s(x),'s(y)) = [1] x + [2] >= [1] x + [1] = 'divsub(x,y) filter(p,dd(x,xs)) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [4] >= [4] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [0] >= [1] x + [1] xs + [0] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [0] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.b:3: NaturalMI WORST_CASE(?,O(n^1)) + Considered Problem: - Strict DPs: 'natadd#('s(x),y) -> c_51('natadd#(x,y)) - Weak DPs: 'div#('neg(x),'neg(y)) -> 'natdiv#(x,y) 'div#('neg(x),'pos(y)) -> 'natdiv#(x,y) 'div#('pos(x),'neg(y)) -> 'natdiv#(x,y) 'div#('pos(x),'pos(y)) -> 'natdiv#(x,y) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'mod#(x,y) -> 'div#(x,y) 'mod#(x,y) -> 'mult#(y,'div(x,y)) 'mult#('neg(x),'neg(y)) -> 'natmult#(x,y) 'mult#('neg(x),'pos(y)) -> 'natmult#(x,y) 'mult#('pos(x),'neg(y)) -> 'natmult#(x,y) 'mult#('pos(x),'pos(y)) -> 'natmult#(x,y) 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y) 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) -> 'natdiv#('s(x),y) 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) -> 'natmult#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: NaturalMI {miDimension = 1, miDegree = 1, miKind = Algebraic, uargs = UArgs, urules = URules, selector = Just any strict-rules} + Details: We apply a matrix interpretation of kind constructor based matrix interpretation: The following argument positions are considered usable: uargs(c_22) = {1}, uargs(c_51) = {1} Following symbols are considered usable: {'and,'div,'divsub,'eq,'equal,'natdiv,'natdiv','negative,'positive,filter,filter','add#,'and#,'div# ,'divsub#,'eq#,'equal#,'mod#,'mult#,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive# ,'pred#,'sub#,'succ#,eratos#,filter#,filter'#} TcT has computed the following interpretation: p('0) = [0] p('add) = [1] p('and) = [0] p('div) = [2] x1 + [0] p('divByZero) = [0] p('divsub) = [1] x1 + [0] p('eq) = [0] p('equal) = [2] x2 + [0] p('false) = [0] p('mod) = [1] x1 + [0] p('mult) = [4] x1 + [2] x2 + [3] p('natadd) = [4] x2 + [2] p('natdiv) = [1] x1 + [1] p('natdiv') = [1] x1 + [2] p('natmult) = [2] p('natsub) = [1] p('neg) = [1] x1 + [2] p('negative) = [1] x1 + [2] p('pos) = [1] x1 + [2] p('positive) = [2] x1 + [2] p('pred) = [2] x1 + [0] p('s) = [1] x1 + [1] p('sub) = [2] x2 + [2] p('succ) = [0] p('true) = [0] p('underflow) = [0] p(dd) = [1] x1 + [1] x2 + [1] p(eratos) = [0] p(filter) = [1] x2 + [0] p(filter') = [2] x1 + [1] x2 + [1] x3 + [1] p(nil) = [0] p('add#) = [1] x1 + [1] p('and#) = [1] p('div#) = [2] x1 + [2] x2 + [4] p('divsub#) = [2] x2 + [0] p('eq#) = [4] p('equal#) = [4] p('mod#) = [2] x1 + [2] x2 + [4] p('mult#) = [2] x1 + [1] x2 + [3] p('natadd#) = [1] x1 + [2] p('natdiv#) = [2] x2 + [0] p('natdiv'#) = [2] x2 + [0] p('natmult#) = [2] x1 + [1] x2 + [0] p('natsub#) = [2] x1 + [2] p('negative#) = [1] p('positive#) = [2] x1 + [1] p('pred#) = [0] p('sub#) = [1] x1 + [1] p('succ#) = [1] x1 + [1] p(eratos#) = [3] x1 + [0] p(filter#) = [2] x1 + [3] x2 + [2] p(filter'#) = [1] x1 + [2] p(c_1) = [4] p(c_2) = [1] x1 + [4] p(c_3) = [1] p(c_4) = [4] x1 + [0] p(c_5) = [1] x1 + [1] p(c_6) = [1] p(c_7) = [4] p(c_8) = [0] p(c_9) = [2] p(c_10) = [4] p(c_11) = [0] p(c_12) = [4] p(c_13) = [0] p(c_14) = [4] p(c_15) = [2] p(c_16) = [0] p(c_17) = [0] p(c_18) = [0] p(c_19) = [1] p(c_20) = [0] p(c_21) = [0] p(c_22) = [1] x1 + [2] p(c_23) = [0] p(c_24) = [0] p(c_25) = [4] p(c_26) = [0] p(c_27) = [1] p(c_28) = [2] x1 + [1] p(c_29) = [0] p(c_30) = [1] p(c_31) = [2] p(c_32) = [0] p(c_33) = [0] p(c_34) = [1] p(c_35) = [0] p(c_36) = [4] p(c_37) = [0] p(c_38) = [1] p(c_39) = [2] p(c_40) = [4] x1 + [0] p(c_41) = [0] p(c_42) = [2] p(c_43) = [1] p(c_44) = [1] p(c_45) = [4] x1 + [4] p(c_46) = [1] p(c_47) = [1] p(c_48) = [1] p(c_49) = [1] p(c_50) = [0] p(c_51) = [1] x1 + [0] p(c_52) = [1] p(c_53) = [2] p(c_54) = [0] p(c_55) = [2] p(c_56) = [1] p(c_57) = [1] p(c_58) = [1] x1 + [1] p(c_59) = [0] p(c_60) = [4] p(c_61) = [0] p(c_62) = [1] p(c_63) = [4] p(c_64) = [0] p(c_65) = [1] x1 + [1] p(c_66) = [2] p(c_67) = [1] p(c_68) = [0] p(c_69) = [2] p(c_70) = [0] p(c_71) = [0] p(c_72) = [2] p(c_73) = [0] p(c_74) = [2] p(c_75) = [2] p(c_76) = [0] p(c_77) = [1] p(c_78) = [0] p(c_79) = [1] p(c_80) = [0] p(c_81) = [4] p(c_82) = [0] p(c_83) = [2] p(c_84) = [0] p(c_85) = [1] x2 + [4] p(c_86) = [0] p(c_87) = [1] x1 + [0] p(c_88) = [1] p(c_89) = [1] p(c_90) = [1] Following rules are strictly oriented: 'natadd#('s(x),y) = [1] x + [3] > [1] x + [2] = c_51('natadd#(x,y)) Following rules are (at-least) weakly oriented: 'div#('neg(x),'neg(y)) = [2] x + [2] y + [12] >= [2] y + [0] = 'natdiv#(x,y) 'div#('neg(x),'pos(y)) = [2] x + [2] y + [12] >= [2] y + [0] = 'natdiv#(x,y) 'div#('pos(x),'neg(y)) = [2] x + [2] y + [12] >= [2] y + [0] = 'natdiv#(x,y) 'div#('pos(x),'pos(y)) = [2] x + [2] y + [12] >= [2] y + [0] = 'natdiv#(x,y) 'divsub#('s(x),'s(y)) = [2] y + [2] >= [2] y + [2] = c_22('divsub#(x,y)) 'mod#(x,y) = [2] x + [2] y + [4] >= [2] x + [2] y + [4] = 'div#(x,y) 'mod#(x,y) = [2] x + [2] y + [4] >= [2] x + [2] y + [3] = 'mult#(y,'div(x,y)) 'mult#('neg(x),'neg(y)) = [2] x + [1] y + [9] >= [2] x + [1] y + [0] = 'natmult#(x,y) 'mult#('neg(x),'pos(y)) = [2] x + [1] y + [9] >= [2] x + [1] y + [0] = 'natmult#(x,y) 'mult#('pos(x),'neg(y)) = [2] x + [1] y + [9] >= [2] x + [1] y + [0] = 'natmult#(x,y) 'mult#('pos(x),'pos(y)) = [2] x + [1] y + [9] >= [2] x + [1] y + [0] = 'natmult#(x,y) 'natdiv#('s(x),'s(y)) = [2] y + [2] >= [2] y + [0] = 'divsub#(x,y) 'natdiv#('s(x),'s(y)) = [2] y + [2] >= [2] y + [2] = 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) = [2] y + [0] >= [2] y + [0] = 'natdiv#('s(x),y) 'natmult#('s(x),y) = [2] x + [1] y + [2] >= [1] y + [2] = 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) = [2] x + [1] y + [2] >= [2] x + [1] y + [0] = 'natmult#(x,y) eratos#(dd(x,xs)) = [3] x + [3] xs + [3] >= [3] xs + [0] = eratos#(filter(x,xs)) eratos#(dd(x,xs)) = [3] x + [3] xs + [3] >= [2] x + [3] xs + [2] = filter#(x,xs) filter#(p,dd(x,xs)) = [2] p + [3] x + [3] xs + [5] >= [2] p + [2] x + [4] = 'mod#(x,p) filter#(p,dd(x,xs)) = [2] p + [3] x + [3] xs + [5] >= [2] p + [3] xs + [2] = filter#(p,xs) 'and('false(),'false()) = [0] >= [0] = 'false() 'and('false(),'true()) = [0] >= [0] = 'false() 'and('true(),'false()) = [0] >= [0] = 'false() 'and('true(),'true()) = [0] >= [0] = 'true() 'div('0(),'0()) = [0] >= [0] = 'divByZero() 'div('0(),'neg(y)) = [0] >= [0] = '0() 'div('0(),'pos(y)) = [0] >= [0] = '0() 'div('neg(x),'0()) = [2] x + [4] >= [0] = 'divByZero() 'div('neg(x),'neg(y)) = [2] x + [4] >= [2] x + [4] = 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) = [2] x + [4] >= [1] x + [3] = 'negative('natdiv(x,y)) 'div('pos(x),'0()) = [2] x + [4] >= [0] = 'divByZero() 'div('pos(x),'neg(y)) = [2] x + [4] >= [1] x + [3] = 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) = [2] x + [4] >= [2] x + [4] = 'positive('natdiv(x,y)) 'divsub('0(),'0()) = [0] >= [0] = '0() 'divsub('0(),'s(y)) = [0] >= [0] = 'underflow() 'divsub('s(x),'0()) = [1] x + [1] >= [1] x + [1] = 's(x) 'divsub('s(x),'s(y)) = [1] x + [1] >= [1] x + [0] = 'divsub(x,y) 'eq('0(),'0()) = [0] >= [0] = 'true() 'eq('0(),'neg(y)) = [0] >= [0] = 'false() 'eq('0(),'pos(y)) = [0] >= [0] = 'false() 'eq('0(),'s(y)) = [0] >= [0] = 'false() 'eq('neg(x),'0()) = [0] >= [0] = 'false() 'eq('neg(x),'neg(y)) = [0] >= [0] = 'eq(x,y) 'eq('neg(x),'pos(y)) = [0] >= [0] = 'false() 'eq('pos(x),'0()) = [0] >= [0] = 'false() 'eq('pos(x),'neg(y)) = [0] >= [0] = 'false() 'eq('pos(x),'pos(y)) = [0] >= [0] = 'eq(x,y) 'eq('s(x),'0()) = [0] >= [0] = 'false() 'eq('s(x),'s(y)) = [0] >= [0] = 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) = [0] >= [0] = 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) = [0] >= [0] = 'false() 'eq(nil(),dd(y'1,y'2)) = [0] >= [0] = 'false() 'eq(nil(),nil()) = [0] >= [0] = 'true() 'equal(x,y) = [2] y + [0] >= [0] = 'eq(x,y) 'natdiv('0(),'0()) = [1] >= [0] = 'divByZero() 'natdiv('0(),'s(y)) = [1] >= [0] = '0() 'natdiv('s(x),'0()) = [1] x + [2] >= [0] = 'divByZero() 'natdiv('s(x),'s(y)) = [1] x + [2] >= [1] x + [2] = 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) = [1] >= [0] = '0() 'natdiv'('0(),y) = [2] >= [1] = 's('0()) 'natdiv'('s(x),y) = [1] x + [3] >= [1] x + [3] = 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) = [2] >= [0] = '0() 'negative('0()) = [2] >= [0] = '0() 'negative('neg(x)) = [1] x + [4] >= [1] x + [2] = 'pos(x) 'negative('pos(x)) = [1] x + [4] >= [1] x + [2] = 'neg(x) 'negative('s(x)) = [1] x + [3] >= [1] x + [3] = 'neg('s(x)) 'positive('0()) = [2] >= [0] = '0() 'positive('neg(x)) = [2] x + [6] >= [1] x + [2] = 'neg(x) 'positive('pos(x)) = [2] x + [6] >= [1] x + [2] = 'pos(x) 'positive('s(x)) = [2] x + [4] >= [1] x + [3] = 'pos('s(x)) filter(p,dd(x,xs)) = [1] x + [1] xs + [1] >= [1] x + [1] xs + [1] = filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) = [0] >= [0] = nil() filter'('false(),x,xs) = [1] x + [1] xs + [1] >= [1] x + [1] xs + [1] = dd(x,xs) filter'('true(),x,xs) = [1] x + [1] xs + [1] >= [1] xs + [0] = xs **** Step 7.b:1.b:1.b:4: EmptyProcessor WORST_CASE(?,O(1)) + Considered Problem: - Weak DPs: 'div#('neg(x),'neg(y)) -> 'natdiv#(x,y) 'div#('neg(x),'pos(y)) -> 'natdiv#(x,y) 'div#('pos(x),'neg(y)) -> 'natdiv#(x,y) 'div#('pos(x),'pos(y)) -> 'natdiv#(x,y) 'divsub#('s(x),'s(y)) -> c_22('divsub#(x,y)) 'mod#(x,y) -> 'div#(x,y) 'mod#(x,y) -> 'mult#(y,'div(x,y)) 'mult#('neg(x),'neg(y)) -> 'natmult#(x,y) 'mult#('neg(x),'pos(y)) -> 'natmult#(x,y) 'mult#('pos(x),'neg(y)) -> 'natmult#(x,y) 'mult#('pos(x),'pos(y)) -> 'natmult#(x,y) 'natadd#('s(x),y) -> c_51('natadd#(x,y)) 'natdiv#('s(x),'s(y)) -> 'divsub#(x,y) 'natdiv#('s(x),'s(y)) -> 'natdiv'#('divsub(x,y),'s(y)) 'natdiv'#('s(x),y) -> 'natdiv#('s(x),y) 'natmult#('s(x),y) -> 'natadd#(y,'natmult(x,y)) 'natmult#('s(x),y) -> 'natmult#(x,y) eratos#(dd(x,xs)) -> eratos#(filter(x,xs)) eratos#(dd(x,xs)) -> filter#(x,xs) filter#(p,dd(x,xs)) -> 'mod#(x,p) filter#(p,dd(x,xs)) -> filter#(p,xs) - Weak TRS: 'add('0(),y) -> y 'add('neg('s('0())),y) -> 'pred(y) 'add('neg('s('s(x))),y) -> 'pred('add('pos('s(x)),y)) 'add('pos('s('0())),y) -> 'succ(y) 'add('pos('s('s(x))),y) -> 'succ('add('pos('s(x)),y)) 'and('false(),'false()) -> 'false() 'and('false(),'true()) -> 'false() 'and('true(),'false()) -> 'false() 'and('true(),'true()) -> 'true() 'div('0(),'0()) -> 'divByZero() 'div('0(),'neg(y)) -> '0() 'div('0(),'pos(y)) -> '0() 'div('neg(x),'0()) -> 'divByZero() 'div('neg(x),'neg(y)) -> 'positive('natdiv(x,y)) 'div('neg(x),'pos(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'0()) -> 'divByZero() 'div('pos(x),'neg(y)) -> 'negative('natdiv(x,y)) 'div('pos(x),'pos(y)) -> 'positive('natdiv(x,y)) 'divsub('0(),'0()) -> '0() 'divsub('0(),'s(y)) -> 'underflow() 'divsub('s(x),'0()) -> 's(x) 'divsub('s(x),'s(y)) -> 'divsub(x,y) 'eq('0(),'0()) -> 'true() 'eq('0(),'neg(y)) -> 'false() 'eq('0(),'pos(y)) -> 'false() 'eq('0(),'s(y)) -> 'false() 'eq('neg(x),'0()) -> 'false() 'eq('neg(x),'neg(y)) -> 'eq(x,y) 'eq('neg(x),'pos(y)) -> 'false() 'eq('pos(x),'0()) -> 'false() 'eq('pos(x),'neg(y)) -> 'false() 'eq('pos(x),'pos(y)) -> 'eq(x,y) 'eq('s(x),'0()) -> 'false() 'eq('s(x),'s(y)) -> 'eq(x,y) 'eq(dd(x'1,x'2),dd(y'1,y'2)) -> 'and('eq(x'1,y'1),'eq(x'2,y'2)) 'eq(dd(x'1,x'2),nil()) -> 'false() 'eq(nil(),dd(y'1,y'2)) -> 'false() 'eq(nil(),nil()) -> 'true() 'equal(x,y) -> 'eq(x,y) 'mod(x,y) -> 'sub(x,'mult(y,'div(x,y))) 'mult('0(),'0()) -> '0() 'mult('0(),'neg(y)) -> '0() 'mult('0(),'pos(y)) -> '0() 'mult('neg(x),'0()) -> '0() 'mult('neg(x),'neg(y)) -> 'pos('natmult(x,y)) 'mult('neg(x),'pos(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'0()) -> '0() 'mult('pos(x),'neg(y)) -> 'neg('natmult(x,y)) 'mult('pos(x),'pos(y)) -> 'pos('natmult(x,y)) 'natadd('0(),y) -> y 'natadd('s(x),y) -> 's('natadd(x,y)) 'natdiv('0(),'0()) -> 'divByZero() 'natdiv('0(),'s(y)) -> '0() 'natdiv('s(x),'0()) -> 'divByZero() 'natdiv('s(x),'s(y)) -> 'natdiv'('divsub(x,y),'s(y)) 'natdiv('underflow(),y) -> '0() 'natdiv'('0(),y) -> 's('0()) 'natdiv'('s(x),y) -> 's('natdiv('s(x),y)) 'natdiv'('underflow(),y) -> '0() 'natmult('0(),y) -> '0() 'natmult('s(x),y) -> 'natadd(y,'natmult(x,y)) 'negative('0()) -> '0() 'negative('neg(x)) -> 'pos(x) 'negative('pos(x)) -> 'neg(x) 'negative('s(x)) -> 'neg('s(x)) 'positive('0()) -> '0() 'positive('neg(x)) -> 'neg(x) 'positive('pos(x)) -> 'pos(x) 'positive('s(x)) -> 'pos('s(x)) 'pred('0()) -> 'neg('s('0())) 'pred('neg('s(x))) -> 'neg('s('s(x))) 'pred('pos('s('0()))) -> '0() 'pred('pos('s('s(x)))) -> 'pos('s(x)) 'sub(x,'0()) -> x 'sub(x,'neg(y)) -> 'add(x,'pos(y)) 'sub(x,'pos(y)) -> 'add(x,'neg(y)) 'succ('0()) -> 'pos('s('0())) 'succ('neg('s('0()))) -> '0() 'succ('neg('s('s(x)))) -> 'neg('s(x)) 'succ('pos('s(x))) -> 'pos('s('s(x))) filter(p,dd(x,xs)) -> filter'('equal('mod(x,p),'0()),x,filter(p,xs)) filter(p,nil()) -> nil() filter'('false(),x,xs) -> dd(x,xs) filter'('true(),x,xs) -> xs - Signature: {'add/2,'and/2,'div/2,'divsub/2,'eq/2,'equal/2,'mod/2,'mult/2,'natadd/2,'natdiv/2,'natdiv'/2,'natmult/2 ,'natsub/2,'negative/1,'positive/1,'pred/1,'sub/2,'succ/1,eratos/1,filter/2,filter'/3,'add#/2,'and#/2 ,'div#/2,'divsub#/2,'eq#/2,'equal#/2,'mod#/2,'mult#/2,'natadd#/2,'natdiv#/2,'natdiv'#/2,'natmult#/2 ,'natsub#/2,'negative#/1,'positive#/1,'pred#/1,'sub#/2,'succ#/1,eratos#/1,filter#/2,filter'#/3} / {'0/0 ,'divByZero/0,'false/0,'neg/1,'pos/1,'s/1,'true/0,'underflow/0,dd/2,nil/0,c_1/0,c_2/1,c_3/1,c_4/1,c_5/1 ,c_6/0,c_7/0,c_8/0,c_9/0,c_10/0,c_11/0,c_12/0,c_13/0,c_14/1,c_15/1,c_16/0,c_17/1,c_18/1,c_19/0,c_20/0,c_21/0 ,c_22/1,c_23/0,c_24/0,c_25/0,c_26/0,c_27/0,c_28/1,c_29/0,c_30/0,c_31/0,c_32/1,c_33/0,c_34/1,c_35/2,c_36/0 ,c_37/0,c_38/0,c_39/1,c_40/3,c_41/0,c_42/0,c_43/0,c_44/0,c_45/1,c_46/1,c_47/0,c_48/1,c_49/1,c_50/0,c_51/1 ,c_52/0,c_53/0,c_54/0,c_55/2,c_56/0,c_57/0,c_58/1,c_59/0,c_60/0,c_61/2,c_62/0,c_63/0,c_64/0,c_65/1,c_66/0 ,c_67/0,c_68/0,c_69/0,c_70/0,c_71/0,c_72/0,c_73/0,c_74/0,c_75/0,c_76/0,c_77/0,c_78/0,c_79/1,c_80/1,c_81/0 ,c_82/0,c_83/0,c_84/0,c_85/2,c_86/0,c_87/3,c_88/0,c_89/0,c_90/0} - Obligation: innermost runtime complexity wrt. defined symbols {'add#,'and#,'div#,'divsub#,'eq#,'equal#,'mod#,'mult# ,'natadd#,'natdiv#,'natdiv'#,'natmult#,'natsub#,'negative#,'positive#,'pred#,'sub#,'succ#,eratos#,filter# ,filter'#} and constructors {'0,'divByZero,'false,'neg,'pos,'s,'true,'underflow,dd,nil} + Applied Processor: EmptyProcessor + Details: The problem is already closed. The intended complexity is O(1). WORST_CASE(?,O(n^4))