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

eq(0, 0) → true
eq(0, s(X)) → false
eq(s(X), 0) → false
eq(s(X), s(Y)) → eq(X, Y)
rm(N, nil) → nil
ifrm(true, N, add(M, X)) → rm(N, X)
purge(nil) → nil

Rewrite Strategy: INNERMOST

Renamed function symbols to avoid clashes with predefined symbol.

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

eq'(0', 0') → true'
eq'(0', s'(X)) → false'
eq'(s'(X), 0') → false'
eq'(s'(X), s'(Y)) → eq'(X, Y)
rm'(N, nil') → nil'
ifrm'(true', N, add'(M, X)) → rm'(N, X)
purge'(nil') → nil'

Rewrite Strategy: INNERMOST

Infered types.

Rules:
eq'(0', 0') → true'
eq'(0', s'(X)) → false'
eq'(s'(X), 0') → false'
eq'(s'(X), s'(Y)) → eq'(X, Y)
rm'(N, nil') → nil'
ifrm'(true', N, add'(M, X)) → rm'(N, X)
purge'(nil') → nil'

Types:
eq' :: 0':s' → 0':s' → true':false'
0' :: 0':s'
true' :: true':false'
s' :: 0':s' → 0':s'
false' :: true':false'
_hole_true':false'1 :: true':false'
_hole_0':s'2 :: 0':s'
_gen_0':s'4 :: Nat → 0':s'

Heuristically decided to analyse the following defined symbols:
eq', rm', purge'

They will be analysed ascendingly in the following order:
eq' < rm'
rm' < purge'

Rules:
eq'(0', 0') → true'
eq'(0', s'(X)) → false'
eq'(s'(X), 0') → false'
eq'(s'(X), s'(Y)) → eq'(X, Y)
rm'(N, nil') → nil'
ifrm'(true', N, add'(M, X)) → rm'(N, X)
purge'(nil') → nil'

Types:
eq' :: 0':s' → 0':s' → true':false'
0' :: 0':s'
true' :: true':false'
s' :: 0':s' → 0':s'
false' :: true':false'
_hole_true':false'1 :: true':false'
_hole_0':s'2 :: 0':s'
_gen_0':s'4 :: Nat → 0':s'

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

The following defined symbols remain to be analysed:
eq', rm', purge'

They will be analysed ascendingly in the following order:
eq' < rm'
rm' < purge'

Proved the following rewrite lemma:
eq'(_gen_0':s'4(_n7), _gen_0':s'4(_n7)) → true', rt ∈ Ω(1 + n7)

Induction Base:
eq'(_gen_0':s'4(0), _gen_0':s'4(0)) →RΩ(1)
true'

Induction Step:
eq'(_gen_0':s'4(+(_\$n8, 1)), _gen_0':s'4(+(_\$n8, 1))) →RΩ(1)
eq'(_gen_0':s'4(_\$n8), _gen_0':s'4(_\$n8)) →IH
true'

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

Rules:
eq'(0', 0') → true'
eq'(0', s'(X)) → false'
eq'(s'(X), 0') → false'
eq'(s'(X), s'(Y)) → eq'(X, Y)
rm'(N, nil') → nil'
ifrm'(true', N, add'(M, X)) → rm'(N, X)
purge'(nil') → nil'

Types:
eq' :: 0':s' → 0':s' → true':false'
0' :: 0':s'
true' :: true':false'
s' :: 0':s' → 0':s'
false' :: true':false'
_hole_true':false'1 :: true':false'
_hole_0':s'2 :: 0':s'
_gen_0':s'4 :: Nat → 0':s'

Lemmas:
eq'(_gen_0':s'4(_n7), _gen_0':s'4(_n7)) → true', rt ∈ Ω(1 + n7)

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

The following defined symbols remain to be analysed:
rm', purge'

They will be analysed ascendingly in the following order:
rm' < purge'

Proved the following rewrite lemma:

Induction Base:
nil'

Induction Step:

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

Rules:
eq'(0', 0') → true'
eq'(0', s'(X)) → false'
eq'(s'(X), 0') → false'
eq'(s'(X), s'(Y)) → eq'(X, Y)
rm'(N, nil') → nil'
ifrm'(true', N, add'(M, X)) → rm'(N, X)
purge'(nil') → nil'

Types:
eq' :: 0':s' → 0':s' → true':false'
0' :: 0':s'
true' :: true':false'
s' :: 0':s' → 0':s'
false' :: true':false'
_hole_true':false'1 :: true':false'
_hole_0':s'2 :: 0':s'
_gen_0':s'4 :: Nat → 0':s'

Lemmas:
eq'(_gen_0':s'4(_n7), _gen_0':s'4(_n7)) → true', rt ∈ Ω(1 + n7)

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

The following defined symbols remain to be analysed:
purge'

Could not prove a rewrite lemma for the defined symbol purge'.

Rules:
eq'(0', 0') → true'
eq'(0', s'(X)) → false'
eq'(s'(X), 0') → false'
eq'(s'(X), s'(Y)) → eq'(X, Y)
rm'(N, nil') → nil'
ifrm'(true', N, add'(M, X)) → rm'(N, X)
purge'(nil') → nil'

Types:
eq' :: 0':s' → 0':s' → true':false'
0' :: 0':s'
true' :: true':false'
s' :: 0':s' → 0':s'
false' :: true':false'
_hole_true':false'1 :: true':false'
_hole_0':s'2 :: 0':s'
_gen_0':s'4 :: Nat → 0':s'

Lemmas:
eq'(_gen_0':s'4(_n7), _gen_0':s'4(_n7)) → true', rt ∈ Ω(1 + n7)