* Step 1: Sum WORST_CASE(Omega(n^1),?)
+ Considered Problem:
- Strict TRS:
gcd(x,y) -> if1(ge(x,y),x,y)
ge(x,0()) -> true()
ge(0(),s(x)) -> false()
ge(s(x),s(y)) -> ge(x,y)
gt(0(),y) -> false()
gt(s(x),0()) -> true()
gt(s(x),s(y)) -> gt(x,y)
if(false(),x,y) -> 0()
if(true(),x,y) -> s(minus(x,y))
if1(false(),x,y) -> gcd(y,x)
if1(true(),x,y) -> if2(gt(y,0()),x,y)
if2(false(),x,y) -> x
if2(true(),x,y) -> gcd(minus(x,y),y)
minus(s(x),y) -> if(gt(s(x),y),x,y)
- Signature:
{gcd/2,ge/2,gt/2,if/3,if1/3,if2/3,minus/2} / {0/0,false/0,s/1,true/0}
- Obligation:
innermost runtime complexity wrt. defined symbols {gcd,ge,gt,if,if1,if2,minus} and constructors {0,false,s
,true}
+ Applied Processor:
Sum {left = someStrategy, right = someStrategy}
+ Details:
()
* Step 2: DecreasingLoops WORST_CASE(Omega(n^1),?)
+ Considered Problem:
- Strict TRS:
gcd(x,y) -> if1(ge(x,y),x,y)
ge(x,0()) -> true()
ge(0(),s(x)) -> false()
ge(s(x),s(y)) -> ge(x,y)
gt(0(),y) -> false()
gt(s(x),0()) -> true()
gt(s(x),s(y)) -> gt(x,y)
if(false(),x,y) -> 0()
if(true(),x,y) -> s(minus(x,y))
if1(false(),x,y) -> gcd(y,x)
if1(true(),x,y) -> if2(gt(y,0()),x,y)
if2(false(),x,y) -> x
if2(true(),x,y) -> gcd(minus(x,y),y)
minus(s(x),y) -> if(gt(s(x),y),x,y)
- Signature:
{gcd/2,ge/2,gt/2,if/3,if1/3,if2/3,minus/2} / {0/0,false/0,s/1,true/0}
- Obligation:
innermost runtime complexity wrt. defined symbols {gcd,ge,gt,if,if1,if2,minus} and constructors {0,false,s
,true}
+ Applied Processor:
DecreasingLoops {bound = AnyLoop, narrow = 10}
+ Details:
The system has following decreasing Loops:
ge(x,y){x -> s(x),y -> s(y)} =
ge(s(x),s(y)) ->^+ ge(x,y)
= C[ge(x,y) = ge(x,y){}]
WORST_CASE(Omega(n^1),?)