Documentation

Mathlib.Data.Fintype.OfMap

Constructors for Fintype #

This file contains basic constructors for Fintype instances, given maps from/to finite types.

Main results #

def Fintype.ofMultiset {α : Type u_1} [DecidableEq α] (s : Multiset α) (H : ∀ (x : α), x s) :

Construct a proof of Fintype α from a universal multiset

Equations
    Instances For
      def Fintype.ofList {α : Type u_1} [DecidableEq α] (l : List α) (H : ∀ (x : α), x l) :

      Construct a proof of Fintype α from a universal list

      Equations
        Instances For
          def Fintype.ofBijective {α : Type u_1} {β : Type u_2} [Fintype α] (f : αβ) (H : Function.Bijective f) :

          If f : α → β is a bijection and α is a fintype, then β is also a fintype.

          Equations
            Instances For
              def Fintype.ofSurjective {α : Type u_1} {β : Type u_2} [DecidableEq β] [Fintype α] (f : αβ) (H : Function.Surjective f) :

              If f : α → β is a surjection and α is a fintype, then β is also a fintype.

              Equations
                Instances For
                  noncomputable def Fintype.ofInjective {α : Type u_1} {β : Type u_2} [Fintype β] (f : αβ) (H : Function.Injective f) :

                  Given an injective function to a fintype, the domain is also a fintype. This is noncomputable because injectivity alone cannot be used to construct preimages.

                  Equations
                    Instances For
                      def Fintype.ofEquiv {β : Type u_2} (α : Type u_4) [Fintype α] (f : α β) :

                      If f : α ≃ β and α is a fintype, then β is also a fintype.

                      Equations
                        Instances For
                          def Fintype.ofSubsingleton {α : Type u_1} (a : α) [Subsingleton α] :

                          Any subsingleton type with a witness is a fintype (with one term).

                          Equations
                            Instances For
                              def Fintype.ofIsEmpty {α : Type u_1} [IsEmpty α] :

                              An empty type is a fintype. Not registered as an instance, to make sure that there aren't two conflicting Fintype ι instances around when casing over whether a fintype ι is empty or not.

                              Equations
                                Instances For

                                  Note: this lemma is specifically about Fintype.ofIsEmpty. For a statement about arbitrary Fintype instances, use Finset.univ_eq_empty.