* Step 1: WeightGap WORST_CASE(?,O(n^1))
+ Considered Problem:
- Strict TRS:
+(x,0()) -> x
+(x,s(y)) -> s(+(x,y))
+(s(x),y) -> s(+(x,y))
double(x) -> +(x,x)
double(0()) -> 0()
double(s(x)) -> s(s(double(x)))
- Signature:
{+/2,double/1} / {0/0,s/1}
- Obligation:
innermost runtime complexity wrt. defined symbols {+,double} and constructors {0,s}
+ Applied Processor:
WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny}
+ Details:
The weightgap principle applies using the following nonconstant growth matrix-interpretation:
We apply a matrix interpretation of kind constructor based matrix interpretation:
The following argument positions are considered usable:
uargs(s) = {1}
Following symbols are considered usable:
all
TcT has computed the following interpretation:
p(+) = [6] x1 + [0]
p(0) = [1]
p(double) = [6] x1 + [8]
p(s) = [1] x1 + [3]
Following rules are strictly oriented:
+(s(x),y) = [6] x + [18]
> [6] x + [3]
= s(+(x,y))
double(x) = [6] x + [8]
> [6] x + [0]
= +(x,x)
double(0()) = [14]
> [1]
= 0()
double(s(x)) = [6] x + [26]
> [6] x + [14]
= s(s(double(x)))
Following rules are (at-least) weakly oriented:
+(x,0()) = [6] x + [0]
>= [1] x + [0]
= x
+(x,s(y)) = [6] x + [0]
>= [6] x + [3]
= s(+(x,y))
Further, it can be verified that all rules not oriented are covered by the weightgap condition.
* Step 2: WeightGap WORST_CASE(?,O(n^1))
+ Considered Problem:
- Strict TRS:
+(x,0()) -> x
+(x,s(y)) -> s(+(x,y))
- Weak TRS:
+(s(x),y) -> s(+(x,y))
double(x) -> +(x,x)
double(0()) -> 0()
double(s(x)) -> s(s(double(x)))
- Signature:
{+/2,double/1} / {0/0,s/1}
- Obligation:
innermost runtime complexity wrt. defined symbols {+,double} and constructors {0,s}
+ Applied Processor:
WeightGap {wgDimension = 1, wgDegree = 1, wgKind = Algebraic, wgUArgs = UArgs, wgOn = WgOnAny}
+ Details:
The weightgap principle applies using the following nonconstant growth matrix-interpretation:
We apply a matrix interpretation of kind constructor based matrix interpretation:
The following argument positions are considered usable:
uargs(s) = {1}
Following symbols are considered usable:
all
TcT has computed the following interpretation:
p(+) = [3] x1 + [2] x2 + [7]
p(0) = [1]
p(double) = [5] x1 + [9]
p(s) = [1] x1 + [1]
Following rules are strictly oriented:
+(x,0()) = [3] x + [9]
> [1] x + [0]
= x
+(x,s(y)) = [3] x + [2] y + [9]
> [3] x + [2] y + [8]
= s(+(x,y))
Following rules are (at-least) weakly oriented:
+(s(x),y) = [3] x + [2] y + [10]
>= [3] x + [2] y + [8]
= s(+(x,y))
double(x) = [5] x + [9]
>= [5] x + [7]
= +(x,x)
double(0()) = [14]
>= [1]
= 0()
double(s(x)) = [5] x + [14]
>= [5] x + [11]
= s(s(double(x)))
Further, it can be verified that all rules not oriented are covered by the weightgap condition.
* Step 3: EmptyProcessor WORST_CASE(?,O(1))
+ Considered Problem:
- Weak TRS:
+(x,0()) -> x
+(x,s(y)) -> s(+(x,y))
+(s(x),y) -> s(+(x,y))
double(x) -> +(x,x)
double(0()) -> 0()
double(s(x)) -> s(s(double(x)))
- Signature:
{+/2,double/1} / {0/0,s/1}
- Obligation:
innermost runtime complexity wrt. defined symbols {+,double} and constructors {0,s}
+ Applied Processor:
EmptyProcessor
+ Details:
The problem is already closed. The intended complexity is O(1).
WORST_CASE(?,O(n^1))