(0) Obligation:

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

cond_scanr_f_z_xs_1(Cons(0, x11), 0) → Cons(0, Cons(0, x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0) → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0, x11), M(x2)) → Cons(0, Cons(0, x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0)) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0, x11), S(x2)) → Cons(S(x2), Cons(0, x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0, Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0, x16) → 0
minus#2(S(x20), 0) → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0, S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0, x8) → x8
max#2(S(x12), 0) → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0, scanr#3(x1))

Rewrite Strategy: INNERMOST

(1) RenamingProof (EQUIVALENT transformation)

Renamed function symbols to avoid clashes with predefined symbol.

(2) Obligation:

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

cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

S is empty.
Rewrite Strategy: INNERMOST

(3) TypeInferenceProof (BOTH BOUNDS(ID, ID) transformation)

Infered types.

(4) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

(5) OrderProof (LOWER BOUND(ID) transformation)

Heuristically decided to analyse the following defined symbols:
minus#2, plus#2, scanr#3, foldl#3, max#2

They will be analysed ascendingly in the following order:
max#2 < foldl#3

(6) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

The following defined symbols remain to be analysed:
minus#2, plus#2, scanr#3, foldl#3, max#2

They will be analysed ascendingly in the following order:
max#2 < foldl#3

(7) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

Induction Base:
minus#2(gen_0':S:M4_5(0), gen_0':S:M4_5(0)) →RΩ(1)
0'

Induction Step:
minus#2(gen_0':S:M4_5(+(n6_5, 1)), gen_0':S:M4_5(+(n6_5, 1))) →RΩ(1)
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) →IH
gen_0':S:M4_5(0)

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

(8) Complex Obligation (BEST)

(9) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

The following defined symbols remain to be analysed:
plus#2, scanr#3, foldl#3, max#2

They will be analysed ascendingly in the following order:
max#2 < foldl#3

(10) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)

Induction Base:
plus#2(gen_0':S:M4_5(0), gen_0':S:M4_5(1)) →RΩ(1)
S(gen_0':S:M4_5(0))

Induction Step:
plus#2(gen_0':S:M4_5(+(n679_5, 1)), gen_0':S:M4_5(1)) →RΩ(1)
S(plus#2(gen_0':S:M4_5(n679_5), S(gen_0':S:M4_5(0)))) →IH
S(gen_0':S:M4_5(+(1, c680_5)))

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

(11) Complex Obligation (BEST)

(12) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

The following defined symbols remain to be analysed:
scanr#3, foldl#3, max#2

They will be analysed ascendingly in the following order:
max#2 < foldl#3

(13) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)

Induction Base:
scanr#3(gen_Cons:Nil3_5(0)) →RΩ(1)
Cons(0', Nil)

Induction Step:
scanr#3(gen_Cons:Nil3_5(+(n1297_5, 1))) →RΩ(1)
cond_scanr_f_z_xs_1(scanr#3(gen_Cons:Nil3_5(n1297_5)), 0') →IH
cond_scanr_f_z_xs_1(gen_Cons:Nil3_5(+(1, c1298_5)), 0') →RΩ(1)
Cons(0', Cons(0', gen_Cons:Nil3_5(n1297_5)))

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

(14) Complex Obligation (BEST)

(15) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

The following defined symbols remain to be analysed:
max#2, foldl#3

They will be analysed ascendingly in the following order:
max#2 < foldl#3

(16) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
max#2(gen_0':S:M4_5(n15671_5), gen_0':S:M4_5(n15671_5)) → gen_0':S:M4_5(n15671_5), rt ∈ Ω(1 + n156715)

Induction Base:
max#2(gen_0':S:M4_5(0), gen_0':S:M4_5(0)) →RΩ(1)
gen_0':S:M4_5(0)

Induction Step:
max#2(gen_0':S:M4_5(+(n15671_5, 1)), gen_0':S:M4_5(+(n15671_5, 1))) →RΩ(1)
S(max#2(gen_0':S:M4_5(n15671_5), gen_0':S:M4_5(n15671_5))) →IH
S(gen_0':S:M4_5(c15672_5))

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

(17) Complex Obligation (BEST)

(18) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)
max#2(gen_0':S:M4_5(n15671_5), gen_0':S:M4_5(n15671_5)) → gen_0':S:M4_5(n15671_5), rt ∈ Ω(1 + n156715)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

The following defined symbols remain to be analysed:
foldl#3

(19) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
foldl#3(gen_0':S:M4_5(0), gen_Cons:Nil3_5(n16598_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n165985)

Induction Base:
foldl#3(gen_0':S:M4_5(0), gen_Cons:Nil3_5(0)) →RΩ(1)
gen_0':S:M4_5(0)

Induction Step:
foldl#3(gen_0':S:M4_5(0), gen_Cons:Nil3_5(+(n16598_5, 1))) →RΩ(1)
foldl#3(max#2(gen_0':S:M4_5(0), 0'), gen_Cons:Nil3_5(n16598_5)) →LΩ(1)
foldl#3(gen_0':S:M4_5(0), gen_Cons:Nil3_5(n16598_5)) →IH
gen_0':S:M4_5(0)

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

(20) Complex Obligation (BEST)

(21) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)
max#2(gen_0':S:M4_5(n15671_5), gen_0':S:M4_5(n15671_5)) → gen_0':S:M4_5(n15671_5), rt ∈ Ω(1 + n156715)
foldl#3(gen_0':S:M4_5(0), gen_Cons:Nil3_5(n16598_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n165985)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

No more defined symbols left to analyse.

(22) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

(23) BOUNDS(n^1, INF)

(24) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)
max#2(gen_0':S:M4_5(n15671_5), gen_0':S:M4_5(n15671_5)) → gen_0':S:M4_5(n15671_5), rt ∈ Ω(1 + n156715)
foldl#3(gen_0':S:M4_5(0), gen_Cons:Nil3_5(n16598_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n165985)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

No more defined symbols left to analyse.

(25) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

(26) BOUNDS(n^1, INF)

(27) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)
max#2(gen_0':S:M4_5(n15671_5), gen_0':S:M4_5(n15671_5)) → gen_0':S:M4_5(n15671_5), rt ∈ Ω(1 + n156715)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

No more defined symbols left to analyse.

(28) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

(29) BOUNDS(n^1, INF)

(30) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)
scanr#3(gen_Cons:Nil3_5(n1297_5)) → gen_Cons:Nil3_5(+(1, n1297_5)), rt ∈ Ω(1 + n12975)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

No more defined symbols left to analyse.

(31) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

(32) BOUNDS(n^1, INF)

(33) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)
plus#2(gen_0':S:M4_5(n679_5), gen_0':S:M4_5(1)) → gen_0':S:M4_5(+(1, n679_5)), rt ∈ Ω(1 + n6795)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

No more defined symbols left to analyse.

(34) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

(35) BOUNDS(n^1, INF)

(36) Obligation:

Innermost TRS:
Rules:
cond_scanr_f_z_xs_1(Cons(0', x11), 0') → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), 0') → Cons(S(x2), Cons(S(x2), x11))
cond_scanr_f_z_xs_1(Cons(0', x11), M(x2)) → Cons(0', Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x40), x23), M(0')) → Cons(S(x40), Cons(S(x40), x23))
cond_scanr_f_z_xs_1(Cons(S(x8), x23), M(S(x4))) → Cons(minus#2(x8, x4), Cons(S(x8), x23))
cond_scanr_f_z_xs_1(Cons(0', x11), S(x2)) → Cons(S(x2), Cons(0', x11))
cond_scanr_f_z_xs_1(Cons(S(x2), x11), S(x4)) → Cons(plus#2(S(x4), S(x2)), Cons(S(x2), x11))
scanr#3(Nil) → Cons(0', Nil)
scanr#3(Cons(x4, x2)) → cond_scanr_f_z_xs_1(scanr#3(x2), x4)
foldl#3(x2, Nil) → x2
foldl#3(x6, Cons(x4, x2)) → foldl#3(max#2(x6, x4), x2)
minus#2(0', x16) → 0'
minus#2(S(x20), 0') → S(x20)
minus#2(S(x4), S(x2)) → minus#2(x4, x2)
plus#2(0', S(x2)) → S(x2)
plus#2(S(x4), S(x2)) → S(plus#2(x4, S(x2)))
max#2(0', x8) → x8
max#2(S(x12), 0') → S(x12)
max#2(S(x4), S(x2)) → S(max#2(x4, x2))
main(x1) → foldl#3(0', scanr#3(x1))

Types:
cond_scanr_f_z_xs_1 :: Cons:Nil → 0':S:M → Cons:Nil
Cons :: 0':S:M → Cons:Nil → Cons:Nil
0' :: 0':S:M
S :: 0':S:M → 0':S:M
M :: 0':S:M → 0':S:M
minus#2 :: 0':S:M → 0':S:M → 0':S:M
plus#2 :: 0':S:M → 0':S:M → 0':S:M
scanr#3 :: Cons:Nil → Cons:Nil
Nil :: Cons:Nil
foldl#3 :: 0':S:M → Cons:Nil → 0':S:M
max#2 :: 0':S:M → 0':S:M → 0':S:M
main :: Cons:Nil → 0':S:M
hole_Cons:Nil1_5 :: Cons:Nil
hole_0':S:M2_5 :: 0':S:M
gen_Cons:Nil3_5 :: Nat → Cons:Nil
gen_0':S:M4_5 :: Nat → 0':S:M

Lemmas:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

Generator Equations:
gen_Cons:Nil3_5(0) ⇔ Nil
gen_Cons:Nil3_5(+(x, 1)) ⇔ Cons(0', gen_Cons:Nil3_5(x))
gen_0':S:M4_5(0) ⇔ 0'
gen_0':S:M4_5(+(x, 1)) ⇔ S(gen_0':S:M4_5(x))

No more defined symbols left to analyse.

(37) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
minus#2(gen_0':S:M4_5(n6_5), gen_0':S:M4_5(n6_5)) → gen_0':S:M4_5(0), rt ∈ Ω(1 + n65)

(38) BOUNDS(n^1, INF)