The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V05. Groups

Mathlib.Algebra.Group.Pi.Basic

81 declarations. Mathlib docs · Source

Instances and theorems on pi types

This file provides instances for the typeclass defined in Algebra.Group.Defs. More sophisticated instances are defined in Algebra.Group.Pi.Lemmas files elsewhere.

Porting note

This file relied on the pi_instance tactic, which was not available at the time of porting. The comment --pi_instance is inserted before all fields which were previously derived by pi_instance. See this Zulip discussion: [https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/not.20porting.20pi_instance]

instance Pi.isAddCommutative E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Add (f i)] [∀ (i : I), IsAddCommutative (f i)],
  IsAddCommutative ((i : I) → f i)

instance Pi.isMulCommutative E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Mul (f i)] [∀ (i : I), IsMulCommutative (f i)],
  IsMulCommutative ((i : I) → f i)

instance Pi.commMagma E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → CommMagma (f i)] → CommMagma ((i : I) → f i)

instance Pi.addCommMagma E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddCommMagma (f i)] → AddCommMagma ((i : I) → f i)

instance Pi.addSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddSemigroup (f i)] → AddSemigroup ((i : I) → f i)

instance Pi.semigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → Semigroup (f i)] → Semigroup ((i : I) → f i)

instance Pi.addCommSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddCommSemigroup (f i)] → AddCommSemigroup ((i : I) → f i)

instance Pi.commSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → CommSemigroup (f i)] → CommSemigroup ((i : I) → f i)

instance Pi.mulOneClass E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → MulOneClass (f i)] → MulOneClass ((i : I) → f i)

instance Pi.addZeroClass E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddZeroClass (f i)] → AddZeroClass ((i : I) → f i)

instance Pi.instIsDedekindFiniteMonoidForall E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → MulOneClass (f i)] [∀ (i : I), IsDedekindFiniteMonoid (f i)],
  IsDedekindFiniteMonoid ((i : I) → f i)

instance Pi.instIsDedekindFiniteAddMonoidForall E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → AddZeroClass (f i)] [∀ (i : I), IsDedekindFiniteAddMonoid (f i)],
  IsDedekindFiniteAddMonoid ((i : I) → f i)

instance Pi.invOneClass E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → InvOneClass (f i)] → InvOneClass ((i : I) → f i)

instance Pi.negZeroClass E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → NegZeroClass (f i)] → NegZeroClass ((i : I) → f i)

instance Pi.addMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddMonoid (f i)] → AddMonoid ((i : I) → f i)

instance Pi.monoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → Monoid (f i)] → Monoid ((i : I) → f i)

instance Pi.addCommMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddCommMonoid (f i)] → AddCommMonoid ((i : I) → f i)

instance Pi.commMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → CommMonoid (f i)] → CommMonoid ((i : I) → f i)

instance Pi.subNegMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → SubNegMonoid (f i)] → SubNegMonoid ((i : I) → f i)

instance Pi.divInvMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → DivInvMonoid (f i)] → DivInvMonoid ((i : I) → f i)

instance Pi.subNegZeroMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → SubNegZeroMonoid (f i)] → SubNegZeroMonoid ((i : I) → f i)

instance Pi.divInvOneMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → DivInvOneMonoid (f i)] → DivInvOneMonoid ((i : I) → f i)

instance Pi.involutiveNeg E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → InvolutiveNeg (f i)] → InvolutiveNeg ((i : I) → f i)

instance Pi.involutiveInv E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → InvolutiveInv (f i)] → InvolutiveInv ((i : I) → f i)

instance Pi.divisionMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → DivisionMonoid (f i)] → DivisionMonoid ((i : I) → f i)

instance Pi.subtractionMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → SubtractionMonoid (f i)] → SubtractionMonoid ((i : I) → f i)

instance Pi.divisionCommMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → DivisionCommMonoid (f i)] → DivisionCommMonoid ((i : I) → f i)

instance Pi.instSubtractionCommMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → SubtractionCommMonoid (f i)] → SubtractionCommMonoid ((i : I) → f i)

instance Pi.addGroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddGroup (f i)] → AddGroup ((i : I) → f i)

instance Pi.group E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → Group (f i)] → Group ((i : I) → f i)

instance Pi.addCommGroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddCommGroup (f i)] → AddCommGroup ((i : I) → f i)

instance Pi.commGroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → CommGroup (f i)] → CommGroup ((i : I) → f i)

instance Pi.instIsLeftCancelAdd E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Add (f i)] [∀ (i : I), IsLeftCancelAdd (f i)],
  IsLeftCancelAdd ((i : I) → f i)

instance Pi.instIsLeftCancelMul E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Mul (f i)] [∀ (i : I), IsLeftCancelMul (f i)],
  IsLeftCancelMul ((i : I) → f i)

instance Pi.instIsRightCancelAdd E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Add (f i)] [∀ (i : I), IsRightCancelAdd (f i)],
  IsRightCancelAdd ((i : I) → f i)

instance Pi.instIsRightCancelMul E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Mul (f i)] [∀ (i : I), IsRightCancelMul (f i)],
  IsRightCancelMul ((i : I) → f i)

instance Pi.instIsCancelAdd E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Add (f i)] [∀ (i : I), IsCancelAdd (f i)],
  IsCancelAdd ((i : I) → f i)

instance Pi.instIsCancelMul E0 #

∀ {I : Type u} {f : I → Type v₁} [inst : (i : I) → Mul (f i)] [∀ (i : I), IsCancelMul (f i)],
  IsCancelMul ((i : I) → f i)

instance Pi.leftCancelSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → LeftCancelSemigroup (f i)] → LeftCancelSemigroup ((i : I) → f i)

instance Pi.addLeftCancelSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddLeftCancelSemigroup (f i)] → AddLeftCancelSemigroup ((i : I) → f i)

instance Pi.addRightCancelSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddRightCancelSemigroup (f i)] → AddRightCancelSemigroup ((i : I) → f i)

instance Pi.rightCancelSemigroup E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → RightCancelSemigroup (f i)] → RightCancelSemigroup ((i : I) → f i)

instance Pi.addLeftCancelMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddLeftCancelMonoid (f i)] → AddLeftCancelMonoid ((i : I) → f i)

instance Pi.leftCancelMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → LeftCancelMonoid (f i)] → LeftCancelMonoid ((i : I) → f i)

instance Pi.rightCancelMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → RightCancelMonoid (f i)] → RightCancelMonoid ((i : I) → f i)

instance Pi.addRightCancelMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddRightCancelMonoid (f i)] → AddRightCancelMonoid ((i : I) → f i)

instance Pi.addCancelMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddCancelMonoid (f i)] → AddCancelMonoid ((i : I) → f i)

instance Pi.cancelMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → CancelMonoid (f i)] → CancelMonoid ((i : I) → f i)

instance Pi.cancelCommMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → CancelCommMonoid (f i)] → CancelCommMonoid ((i : I) → f i)

instance Pi.addCancelCommMonoid E0 #

{I : Type u} → {f : I → Type v₁} → [(i : I) → AddCancelCommMonoid (f i)] → AddCancelCommMonoid ((i : I) → f i)

theorem Function.extend_one E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : One γ] (f : α → β), Function.extend f 1 1 = 1

theorem Function.extend_zero E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Zero γ] (f : α → β), Function.extend f 0 0 = 0

theorem Function.Injective.extend_mulSingle E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : DecidableEq α] [inst_1 : DecidableEq β] [inst_2 : One γ]
  {f : α → β}, Function.Injective f → ∀ (i : α) (a : γ), Function.extend f (Pi.mulSingle i a) 1 = Pi.mulSingle (f i) a

theorem Function.Injective.extend_single E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : DecidableEq α] [inst_1 : DecidableEq β] [inst_2 : Zero γ]
  {f : α → β}, Function.Injective f → ∀ (i : α) (a : γ), Function.extend f (Pi.single i a) 0 = Pi.single (f i) a

theorem Function.extend_add E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Add γ] (f : α → β) (g₁ g₂ : α → γ) (e₁ e₂ : β → γ),
  Function.extend f (g₁ + g₂) (e₁ + e₂) = Function.extend f g₁ e₁ + Function.extend f g₂ e₂

theorem Function.extend_mul E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Mul γ] (f : α → β) (g₁ g₂ : α → γ) (e₁ e₂ : β → γ),
  Function.extend f (g₁ * g₂) (e₁ * e₂) = Function.extend f g₁ e₁ * Function.extend f g₂ e₂

theorem Function.extend_neg E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Neg γ] (f : α → β) (g : α → γ) (e : β → γ),
  Function.extend f (-g) (-e) = -Function.extend f g e

theorem Function.extend_inv E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Inv γ] (f : α → β) (g : α → γ) (e : β → γ),
  Function.extend f g⁻¹ e⁻¹ = (Function.extend f g e)⁻¹

theorem Function.extend_div E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Div γ] (f : α → β) (g₁ g₂ : α → γ) (e₁ e₂ : β → γ),
  Function.extend f (g₁ / g₂) (e₁ / e₂) = Function.extend f g₁ e₁ / Function.extend f g₂ e₂

theorem Function.extend_sub E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Sub γ] (f : α → β) (g₁ g₂ : α → γ) (e₁ e₂ : β → γ),
  Function.extend f (g₁ - g₂) (e₁ - e₂) = Function.extend f g₁ e₁ - Function.extend f g₂ e₂

theorem Function.comp_eq_const_iff E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (b : β) (f : α → β) {g : β → γ},
  Function.Injective g → (g ∘ f = Function.const α (g b) ↔ f = Function.const α b)

theorem Function.comp_eq_zero_iff E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Zero β] [inst_1 : Zero γ] (f : α → β) {g : β → γ},
  Function.Injective g → g 0 = 0 → (g ∘ f = 0 ↔ f = 0)

theorem Function.comp_eq_one_iff E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : One β] [inst_1 : One γ] (f : α → β) {g : β → γ},
  Function.Injective g → g 1 = 1 → (g ∘ f = 1 ↔ f = 1)

theorem Function.comp_ne_zero_iff E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Zero β] [inst_1 : Zero γ] (f : α → β) {g : β → γ},
  Function.Injective g → g 0 = 0 → (g ∘ f ≠ 0 ↔ f ≠ 0)

theorem Function.comp_ne_one_iff E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : One β] [inst_1 : One γ] (f : α → β) {g : β → γ},
  Function.Injective g → g 1 = 1 → (g ∘ f ≠ 1 ↔ f ≠ 1)

def uniqueOfSurjectiveOne E1 #

(α : Type u_4) → {β : Type u_5} → [inst : One β] → Function.Surjective 1 → Unique β

If the one function is surjective, the codomain is trivial.

def uniqueOfSurjectiveZero E1 #

(α : Type u_4) → {β : Type u_5} → [inst : Zero β] → Function.Surjective 0 → Unique β

If the zero function is surjective, the codomain is trivial.

theorem Subsingleton.pi_single_eq E0 #

∀ {I : Type u} {α : Type u_4} [inst : DecidableEq I] [Subsingleton I] [inst_2 : Zero α] (i : I) (x : α),
  Pi.single i x = fun x_1 ↦ x

theorem Subsingleton.pi_mulSingle_eq E0 #

∀ {I : Type u} {α : Type u_4} [inst : DecidableEq I] [Subsingleton I] [inst_2 : One α] (i : I) (x : α),
  Pi.mulSingle i x = fun x_1 ↦ x

theorem Sum.elim_zero_zero E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : Zero γ], Sum.elim 0 0 = 0

theorem Sum.elim_one_one E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : One γ], Sum.elim 1 1 = 1

theorem Sum.elim_single_zero E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : DecidableEq α] [inst_1 : DecidableEq β] [inst_2 : Zero γ] (i : α)
  (c : γ), Sum.elim (Pi.single i c) 0 = Pi.single (Sum.inl i) c

theorem Sum.elim_mulSingle_one E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : DecidableEq α] [inst_1 : DecidableEq β] [inst_2 : One γ] (i : α)
  (c : γ), Sum.elim (Pi.mulSingle i c) 1 = Pi.mulSingle (Sum.inl i) c

theorem Sum.elim_zero_single E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : DecidableEq α] [inst_1 : DecidableEq β] [inst_2 : Zero γ] (i : β)
  (c : γ), Sum.elim 0 (Pi.single i c) = Pi.single (Sum.inr i) c

theorem Sum.elim_one_mulSingle E0 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} [inst : DecidableEq α] [inst_1 : DecidableEq β] [inst_2 : One γ] (i : β)
  (c : γ), Sum.elim 1 (Pi.mulSingle i c) = Pi.mulSingle (Sum.inr i) c

theorem Sum.elim_inv_inv E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (a : α → γ) (b : β → γ) [inst : Inv γ],
  Sum.elim a⁻¹ b⁻¹ = (Sum.elim a b)⁻¹

theorem Sum.elim_neg_neg E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (a : α → γ) (b : β → γ) [inst : Neg γ],
  Sum.elim (-a) (-b) = -Sum.elim a b

theorem Sum.elim_add_add E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (a a' : α → γ) (b b' : β → γ) [inst : Add γ],
  Sum.elim (a + a') (b + b') = Sum.elim a b + Sum.elim a' b'

theorem Sum.elim_mul_mul E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (a a' : α → γ) (b b' : β → γ) [inst : Mul γ],
  Sum.elim (a * a') (b * b') = Sum.elim a b * Sum.elim a' b'

theorem Sum.elim_sub_sub E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (a a' : α → γ) (b b' : β → γ) [inst : Sub γ],
  Sum.elim (a - a') (b - b') = Sum.elim a b - Sum.elim a' b'

theorem Sum.elim_div_div E1 #

∀ {α : Type u_1} {β : Type u_2} {γ : Type u_3} (a a' : α → γ) (b b' : β → γ) [inst : Div γ],
  Sum.elim (a / a') (b / b') = Sum.elim a b / Sum.elim a' b'