Documentation
Mathlib
.
Data
.
Nat
.
Set
Search
Google site search
Mathlib
.
Data
.
Nat
.
Set
source
Imports
Init
Mathlib.Data.Set.Image
Imported by
Nat
.
zero_union_range_succ
Nat
.
range_succ
Nat
.
range_of_succ
Nat
.
range_rec
Nat
.
range_casesOn
Recursion on the natural numbers and
Set.range
#
source
theorem
Nat
.
zero_union_range_succ
:
{
0
}
∪
Set.range
Nat.succ
=
Set.univ
source
@[simp]
theorem
Nat
.
range_succ
:
Set.range
Nat.succ
=
{
i
|
0
<
i
}
source
theorem
Nat
.
range_of_succ
{α :
Type
u_1}
(f :
ℕ
→
α
)
:
{
f
0
}
∪
Set.range
(
f
∘
Nat.succ
)
=
Set.range
f
source
theorem
Nat
.
range_rec
{α :
Type
u_2}
(x :
α
)
(f :
ℕ
→
α
→
α
)
:
(
Set.range
fun
n
=>
Nat.rec
x
f
n
)
=
{
x
}
∪
Set.range
fun
n
=>
Nat.rec
(
f
0
x
) (
f
∘
Nat.succ
)
n
source
theorem
Nat
.
range_casesOn
{α :
Type
u_2}
(x :
α
)
(f :
ℕ
→
α
)
:
(
Set.range
fun
n
=>
Nat.casesOn
n
x
f
)
=
{
x
}
∪
Set.range
f