Runtime Complexity TRS:
The TRS R consists of the following rules:

fac(0) → 1
fac(s(x)) → *(s(x), fac(x))
floop(0, y) → y
floop(s(x), y) → floop(x, *(s(x), y))
*(x, 0) → 0
*(x, s(y)) → +(*(x, y), x)
+(x, 0) → x
+(x, s(y)) → s(+(x, y))
1s(0)
fac(0) → s(0)

Rewrite Strategy: INNERMOST


Renamed function symbols to avoid clashes with predefined symbol.


Runtime Complexity TRS:
The TRS R consists of the following rules:


fac'(0') → 1'
fac'(s'(x)) → *'(s'(x), fac'(x))
floop'(0', y) → y
floop'(s'(x), y) → floop'(x, *'(s'(x), y))
*'(x, 0') → 0'
*'(x, s'(y)) → +'(*'(x, y), x)
+'(x, 0') → x
+'(x, s'(y)) → s'(+'(x, y))
1's'(0')
fac'(0') → s'(0')

Rewrite Strategy: INNERMOST


Infered types.


Rules:
fac'(0') → 1'
fac'(s'(x)) → *'(s'(x), fac'(x))
floop'(0', y) → y
floop'(s'(x), y) → floop'(x, *'(s'(x), y))
*'(x, 0') → 0'
*'(x, s'(y)) → +'(*'(x, y), x)
+'(x, 0') → x
+'(x, s'(y)) → s'(+'(x, y))
1's'(0')
fac'(0') → s'(0')

Types:
fac' :: 0':s' → 0':s'
0' :: 0':s'
1' :: 0':s'
s' :: 0':s' → 0':s'
*' :: 0':s' → 0':s' → 0':s'
floop' :: 0':s' → 0':s' → 0':s'
+' :: 0':s' → 0':s' → 0':s'
_hole_0':s'1 :: 0':s'
_gen_0':s'2 :: Nat → 0':s'


Heuristically decided to analyse the following defined symbols:
fac', *', floop', +'

They will be analysed ascendingly in the following order:
*' < fac'
*' < floop'
+' < *'


Rules:
fac'(0') → 1'
fac'(s'(x)) → *'(s'(x), fac'(x))
floop'(0', y) → y
floop'(s'(x), y) → floop'(x, *'(s'(x), y))
*'(x, 0') → 0'
*'(x, s'(y)) → +'(*'(x, y), x)
+'(x, 0') → x
+'(x, s'(y)) → s'(+'(x, y))
1's'(0')
fac'(0') → s'(0')

Types:
fac' :: 0':s' → 0':s'
0' :: 0':s'
1' :: 0':s'
s' :: 0':s' → 0':s'
*' :: 0':s' → 0':s' → 0':s'
floop' :: 0':s' → 0':s' → 0':s'
+' :: 0':s' → 0':s' → 0':s'
_hole_0':s'1 :: 0':s'
_gen_0':s'2 :: Nat → 0':s'

Generator Equations:
_gen_0':s'2(0) ⇔ 0'
_gen_0':s'2(+(x, 1)) ⇔ s'(_gen_0':s'2(x))

The following defined symbols remain to be analysed:
+', fac', *', floop'

They will be analysed ascendingly in the following order:
*' < fac'
*' < floop'
+' < *'


Proved the following rewrite lemma:
+'(_gen_0':s'2(a), _gen_0':s'2(_n4)) → _gen_0':s'2(+(_n4, a)), rt ∈ Ω(1 + n4)

Induction Base:
+'(_gen_0':s'2(a), _gen_0':s'2(0)) →RΩ(1)
_gen_0':s'2(a)

Induction Step:
+'(_gen_0':s'2(_a137), _gen_0':s'2(+(_$n5, 1))) →RΩ(1)
s'(+'(_gen_0':s'2(_a137), _gen_0':s'2(_$n5))) →IH
s'(_gen_0':s'2(+(_$n5, _a137)))

We have rt ∈ Ω(n) and sz ∈ O(n). Thus, we have ircR ∈ Ω(n).


Rules:
fac'(0') → 1'
fac'(s'(x)) → *'(s'(x), fac'(x))
floop'(0', y) → y
floop'(s'(x), y) → floop'(x, *'(s'(x), y))
*'(x, 0') → 0'
*'(x, s'(y)) → +'(*'(x, y), x)
+'(x, 0') → x
+'(x, s'(y)) → s'(+'(x, y))
1's'(0')
fac'(0') → s'(0')

Types:
fac' :: 0':s' → 0':s'
0' :: 0':s'
1' :: 0':s'
s' :: 0':s' → 0':s'
*' :: 0':s' → 0':s' → 0':s'
floop' :: 0':s' → 0':s' → 0':s'
+' :: 0':s' → 0':s' → 0':s'
_hole_0':s'1 :: 0':s'
_gen_0':s'2 :: Nat → 0':s'

Lemmas:
+'(_gen_0':s'2(a), _gen_0':s'2(_n4)) → _gen_0':s'2(+(_n4, a)), rt ∈ Ω(1 + n4)

Generator Equations:
_gen_0':s'2(0) ⇔ 0'
_gen_0':s'2(+(x, 1)) ⇔ s'(_gen_0':s'2(x))

The following defined symbols remain to be analysed:
*', fac', floop'

They will be analysed ascendingly in the following order:
*' < fac'
*' < floop'


Proved the following rewrite lemma:
*'(_gen_0':s'2(a), _gen_0':s'2(_n581)) → _gen_0':s'2(*(_n581, a)), rt ∈ Ω(1 + a841·n581 + n581)

Induction Base:
*'(_gen_0':s'2(a), _gen_0':s'2(0)) →RΩ(1)
0'

Induction Step:
*'(_gen_0':s'2(_a841), _gen_0':s'2(+(_$n582, 1))) →RΩ(1)
+'(*'(_gen_0':s'2(_a841), _gen_0':s'2(_$n582)), _gen_0':s'2(_a841)) →IH
+'(_gen_0':s'2(*(_$n582, _a841)), _gen_0':s'2(_a841)) →LΩ(1 + a841)
_gen_0':s'2(+(_a841, *(_$n582, _a841)))

We have rt ∈ Ω(n2) and sz ∈ O(n). Thus, we have ircR ∈ Ω(n2).


Rules:
fac'(0') → 1'
fac'(s'(x)) → *'(s'(x), fac'(x))
floop'(0', y) → y
floop'(s'(x), y) → floop'(x, *'(s'(x), y))
*'(x, 0') → 0'
*'(x, s'(y)) → +'(*'(x, y), x)
+'(x, 0') → x
+'(x, s'(y)) → s'(+'(x, y))
1's'(0')
fac'(0') → s'(0')

Types:
fac' :: 0':s' → 0':s'
0' :: 0':s'
1' :: 0':s'
s' :: 0':s' → 0':s'
*' :: 0':s' → 0':s' → 0':s'
floop' :: 0':s' → 0':s' → 0':s'
+' :: 0':s' → 0':s' → 0':s'
_hole_0':s'1 :: 0':s'
_gen_0':s'2 :: Nat → 0':s'

Lemmas:
+'(_gen_0':s'2(a), _gen_0':s'2(_n4)) → _gen_0':s'2(+(_n4, a)), rt ∈ Ω(1 + n4)
*'(_gen_0':s'2(a), _gen_0':s'2(_n581)) → _gen_0':s'2(*(_n581, a)), rt ∈ Ω(1 + a841·n581 + n581)

Generator Equations:
_gen_0':s'2(0) ⇔ 0'
_gen_0':s'2(+(x, 1)) ⇔ s'(_gen_0':s'2(x))

The following defined symbols remain to be analysed:
fac', floop'


Proved the following rewrite lemma:
fac'(_gen_0':s'2(+(1, _n1442))) → _*3, rt ∈ Ω(n1442)

Induction Base:
fac'(_gen_0':s'2(+(1, 0)))

Induction Step:
fac'(_gen_0':s'2(+(1, +(_$n1443, 1)))) →RΩ(1)
*'(s'(_gen_0':s'2(+(1, _$n1443))), fac'(_gen_0':s'2(+(1, _$n1443)))) →IH
*'(s'(_gen_0':s'2(+(1, _$n1443))), _*3)

We have rt ∈ Ω(n) and sz ∈ O(n). Thus, we have ircR ∈ Ω(n).


Rules:
fac'(0') → 1'
fac'(s'(x)) → *'(s'(x), fac'(x))
floop'(0', y) → y
floop'(s'(x), y) → floop'(x, *'(s'(x), y))
*'(x, 0') → 0'
*'(x, s'(y)) → +'(*'(x, y), x)
+'(x, 0') → x
+'(x, s'(y)) → s'(+'(x, y))
1's'(0')
fac'(0') → s'(0')

Types:
fac' :: 0':s' → 0':s'
0' :: 0':s'
1' :: 0':s'
s' :: 0':s' → 0':s'
*' :: 0':s' → 0':s' → 0':s'
floop' :: 0':s' → 0':s' → 0':s'
+' :: 0':s' → 0':s' → 0':s'
_hole_0':s'1 :: 0':s'
_gen_0':s'2 :: Nat → 0':s'

Lemmas:
+'(_gen_0':s'2(a), _gen_0':s'2(_n4)) → _gen_0':s'2(+(_n4, a)), rt ∈ Ω(1 + n4)
*'(_gen_0':s'2(a), _gen_0':s'2(_n581)) → _gen_0':s'2(*(_n581, a)), rt ∈ Ω(1 + a841·n581 + n581)
fac'(_gen_0':s'2(+(1, _n1442))) → _*3, rt ∈ Ω(n1442)

Generator Equations:
_gen_0':s'2(0) ⇔ 0'
_gen_0':s'2(+(x, 1)) ⇔ s'(_gen_0':s'2(x))

The following defined symbols remain to be analysed:
floop'