Module docstring
{"# Equivalences between Fintype, Fin and Finite
This file defines the bijection between a Fintype α and Fin (Fintype.card α), and uses this to
relate Fintype with Finite. From that we can derive properties of Finite and Infinite,
and show some instances of Infinite.
Main declarations
Fintype.truncEquivFin: A fintypeαis computably equivalent toFin (card α). TheTrunc-free, noncomputable version isFintype.equivFin.Fintype.truncEquivOfCardEqFintype.equivOfCardEq: Two fintypes of same cardinality are equivalent. See above.Fin.equiv_iff_eq:Fin m ≃ Fin niffm = n.Infinite.natEmbedding: An embedding ofℕinto an infinite type.
Types which have an injection from/a surjection to an Infinite type are themselves Infinite.
See Infinite.of_injective and Infinite.of_surjective.
Instances
We provide Infinite instances for
* specific types: ℕ, ℤ, String
* type constructors: Multiset α, List α
","### Relation to Finite
In this section we prove that α : Type* is Finite if and only if Fintype α is nonempty.
"}