Images and preimages of sets #
Main definitions #
preimage f t : Set α: the preimage f⁻¹(t) (writtenf ⁻¹' tin Lean) of a subset of β.range f : Set β: the image ofunivunderf. Also works for{p : Prop} (f : p → α)(unlikeimage)
Notation #
f ⁻¹' tforSet.preimage f tf '' sforSet.image f s
Tags #
set, sets, image, preimage, pre-image, range
Inverse image #
Image of a set under a function #
A common special case of image_congr
Set.image is monotone. See Set.image_mono for the statement in terms of ⊆.
A variant of image_comp, useful for rewriting
A variant of image_id
image and preimage are a Galois connection
If the only elements outside s are those left fixed by σ, then mapping by σ has no effect.
Lemmas about the powerset and image. #
The powerset of {a} ∪ s is 𝒫 s together with {a} ∪ t for each t ∈ 𝒫 s.
Lemmas about range of a function. #
Alias of the reverse direction of Set.range_eq_univ.
Variant of range_comp using a lambda instead of function composition.
The range of a function from a Unique type contains just the
function applied to its single value.
The image of a subsingleton is a subsingleton.
The preimage of a subsingleton under an injective map is a subsingleton.
If the image of a set under an injective map is a subsingleton, the set is a subsingleton.
If the preimage of a set under a surjective map is a subsingleton, the set is a subsingleton.
The preimage of a nontrivial set under a surjective map is nontrivial.
The image of a nontrivial set under an injective map is nontrivial.
If the image of a set is nontrivial, the set is nontrivial.
If the preimage of a set under an injective map is nontrivial, the set is nontrivial.
Alias of the forward direction of Function.Injective.mem_range_iff_existsUnique.
Image and preimage on subtypes #
Images and preimages on Option #
The range of Option.elim b f is {b} ∪ range f.
The image of range some under Option.elim b f equals range f.