```* Step 1: ToInnermost WORST_CASE(?,O(n^1))
+ Considered Problem:
- Strict TRS:
g(f(x),y) -> f(h(x,y))
h(x,y) -> g(x,f(y))
- Signature:
{g/2,h/2} / {f/1}
- Obligation:
runtime complexity wrt. defined symbols {g,h} and constructors {f}
+ Applied Processor:
ToInnermost
+ Details:
switch to innermost, as the system is overlay and right linear and does not contain weak rules
* Step 2: WeightGap WORST_CASE(?,O(n^1))
+ Considered Problem:
- Strict TRS:
g(f(x),y) -> f(h(x,y))
h(x,y) -> g(x,f(y))
- Signature:
{g/2,h/2} / {f/1}
- Obligation:
innermost runtime complexity wrt. defined symbols {g,h} and constructors {f}
+ 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(f) = {1}

Following symbols are considered usable:
all
TcT has computed the following interpretation:
p(f) = [1] x1 + [5]
p(g) = [4] x1 + [1] x2 + [0]
p(h) = [4] x1 + [1] x2 + [14]

Following rules are strictly oriented:
g(f(x),y) = [4] x + [1] y + [20]
> [4] x + [1] y + [19]
= f(h(x,y))

h(x,y) = [4] x + [1] y + [14]
> [4] x + [1] y + [5]
= g(x,f(y))

Following rules are (at-least) weakly oriented:

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:
g(f(x),y) -> f(h(x,y))
h(x,y) -> g(x,f(y))
- Signature:
{g/2,h/2} / {f/1}
- Obligation:
innermost runtime complexity wrt. defined symbols {g,h} and constructors {f}
+ Applied Processor:
EmptyProcessor
+ Details:
The problem is already closed. The intended complexity is O(1).

WORST_CASE(?,O(n^1))
```