statement stringlengths 1 2.88k | proof stringlengths 0 13.9k | type stringclasses 10
values | symbolic_name stringlengths 1 131 | library stringclasses 417
values | filename stringlengths 17 80 | imports listlengths 0 16 | deps listlengths 0 64 | docstring stringlengths 0 10.2k | source_url stringclasses 1
value | commit stringclasses 1
value |
|---|---|---|---|---|---|---|---|---|---|---|
eq_of_forall_dvd' (h : ∀ c, c ∣ a ↔ c ∣ b) : a = b | ((h _).1 dvd_rfl).antisymm $ (h _).2 dvd_rfl | lemma | eq_of_forall_dvd' | algebra.group_with_zero | src/algebra/group_with_zero/divisibility.lean | [
"algebra.group_with_zero.basic",
"algebra.divisibility.units"
] | [
"dvd_rfl"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
function.injective.mul_zero_class [has_mul M₀'] [has_zero M₀'] (f : M₀' → M₀)
(hf : injective f) (zero : f 0 = 0) (mul : ∀ a b, f (a * b) = f a * f b) :
mul_zero_class M₀' | { mul := (*),
zero := 0,
zero_mul := λ a, hf $ by simp only [mul, zero, zero_mul],
mul_zero := λ a, hf $ by simp only [mul, zero, mul_zero] } | def | function.injective.mul_zero_class | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"mul_zero",
"mul_zero_class",
"zero_mul"
] | Pullback a `mul_zero_class` instance along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.mul_zero_class [has_mul M₀'] [has_zero M₀'] (f : M₀ → M₀')
(hf : surjective f) (zero : f 0 = 0) (mul : ∀ a b, f (a * b) = f a * f b) :
mul_zero_class M₀' | { mul := (*),
zero := 0,
mul_zero := hf.forall.2 $ λ x, by simp only [← zero, ← mul, mul_zero],
zero_mul := hf.forall.2 $ λ x, by simp only [← zero, ← mul, zero_mul] } | def | function.surjective.mul_zero_class | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"mul_zero",
"mul_zero_class",
"zero_mul"
] | Pushforward a `mul_zero_class` instance along an surjective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.no_zero_divisors [has_mul M₀] [has_zero M₀]
[has_mul M₀'] [has_zero M₀'] [no_zero_divisors M₀']
(f : M₀ → M₀') (hf : injective f) (zero : f 0 = 0) (mul : ∀ x y, f (x * y) = f x * f y) :
no_zero_divisors M₀ | { eq_zero_or_eq_zero_of_mul_eq_zero := λ x y H,
have f x * f y = 0, by rw [← mul, H, zero],
(eq_zero_or_eq_zero_of_mul_eq_zero this).imp (λ H, hf $ by rwa zero) (λ H, hf $ by rwa zero) } | lemma | function.injective.no_zero_divisors | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"no_zero_divisors"
] | Pushforward a `no_zero_divisors` instance along an injective function. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.mul_zero_one_class [has_mul M₀'] [has_zero M₀'] [has_one M₀']
(f : M₀' → M₀)
(hf : injective f) (zero : f 0 = 0) (one : f 1 = 1) (mul : ∀ a b, f (a * b) = f a * f b) :
mul_zero_one_class M₀' | { ..hf.mul_zero_class f zero mul, ..hf.mul_one_class f one mul } | def | function.injective.mul_zero_one_class | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"mul_zero_one_class"
] | Pullback a `mul_zero_one_class` instance along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.mul_zero_one_class [has_mul M₀'] [has_zero M₀'] [has_one M₀']
(f : M₀ → M₀')
(hf : surjective f) (zero : f 0 = 0) (one : f 1 = 1) (mul : ∀ a b, f (a * b) = f a * f b) :
mul_zero_one_class M₀' | { ..hf.mul_zero_class f zero mul, ..hf.mul_one_class f one mul } | def | function.surjective.mul_zero_one_class | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"mul_zero_one_class"
] | Pushforward a `mul_zero_one_class` instance along an surjective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.semigroup_with_zero
[has_zero M₀'] [has_mul M₀'] [semigroup_with_zero M₀] (f : M₀' → M₀) (hf : injective f)
(zero : f 0 = 0) (mul : ∀ x y, f (x * y) = f x * f y) :
semigroup_with_zero M₀' | { .. hf.mul_zero_class f zero mul,
.. ‹has_zero M₀'›,
.. hf.semigroup f mul } | def | function.injective.semigroup_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"semigroup_with_zero"
] | Pullback a `semigroup_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.semigroup_with_zero
[semigroup_with_zero M₀] [has_zero M₀'] [has_mul M₀'] (f : M₀ → M₀') (hf : surjective f)
(zero : f 0 = 0) (mul : ∀ x y, f (x * y) = f x * f y) :
semigroup_with_zero M₀' | { .. hf.mul_zero_class f zero mul,
.. ‹has_zero M₀'›,
.. hf.semigroup f mul } | def | function.surjective.semigroup_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"semigroup_with_zero"
] | Pushforward a `semigroup_with_zero` class along an surjective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.monoid_with_zero [has_zero M₀'] [has_mul M₀'] [has_one M₀']
[has_pow M₀' ℕ] [monoid_with_zero M₀]
(f : M₀' → M₀) (hf : injective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (npow : ∀ x (n : ℕ), f (x ^ n) = f x ^ n) :
monoid_with_zero M₀' | { .. hf.monoid f one mul npow, .. hf.mul_zero_class f zero mul } | def | function.injective.monoid_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"monoid_with_zero"
] | Pullback a `monoid_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.monoid_with_zero [has_zero M₀'] [has_mul M₀'] [has_one M₀']
[has_pow M₀' ℕ] [monoid_with_zero M₀]
(f : M₀ → M₀') (hf : surjective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (npow : ∀ x (n : ℕ), f (x ^ n) = f x ^ n) :
monoid_with_zero M₀' | { .. hf.monoid f one mul npow, .. hf.mul_zero_class f zero mul } | def | function.surjective.monoid_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"monoid_with_zero"
] | Pushforward a `monoid_with_zero` class along a surjective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.comm_monoid_with_zero [has_zero M₀'] [has_mul M₀'] [has_one M₀']
[has_pow M₀' ℕ] [comm_monoid_with_zero M₀]
(f : M₀' → M₀) (hf : injective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (npow : ∀ x (n : ℕ), f (x ^ n) = f x ^ n) :
comm_monoid_with_zero M₀' | { .. hf.comm_monoid f one mul npow, .. hf.mul_zero_class f zero mul } | def | function.injective.comm_monoid_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"comm_monoid_with_zero"
] | Pullback a `monoid_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.comm_monoid_with_zero [has_zero M₀'] [has_mul M₀'] [has_one M₀']
[has_pow M₀' ℕ] [comm_monoid_with_zero M₀]
(f : M₀ → M₀') (hf : surjective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (npow : ∀ x (n : ℕ), f (x ^ n) = f x ^ n) :
comm_monoid_with_zero M₀' | { .. hf.comm_monoid f one mul npow, .. hf.mul_zero_class f zero mul } | def | function.surjective.comm_monoid_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"comm_monoid_with_zero"
] | Pushforward a `monoid_with_zero` class along a surjective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.cancel_monoid_with_zero [has_zero M₀'] [has_mul M₀'] [has_one M₀']
[has_pow M₀' ℕ] (f : M₀' → M₀) (hf : injective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (npow : ∀ x (n : ℕ), f (x ^ n) = f x ^ n) :
cancel_monoid_with_zero M₀' | { mul_left_cancel_of_ne_zero := λ x y z hx H, hf $ mul_left_cancel₀ ((hf.ne_iff' zero).2 hx) $
by erw [← mul, ← mul, H]; refl,
mul_right_cancel_of_ne_zero := λ x y z hx H, hf $ mul_right_cancel₀ ((hf.ne_iff' zero).2 hx) $
by erw [← mul, ← mul, H]; refl,
.. hf.monoid f one mul npow, .. hf.mul_zero_class f ze... | def | function.injective.cancel_monoid_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"cancel_monoid_with_zero",
"mul_left_cancel₀",
"mul_right_cancel₀"
] | Pullback a `monoid_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.cancel_comm_monoid_with_zero
[has_zero M₀'] [has_mul M₀'] [has_one M₀'] [has_pow M₀' ℕ]
(f : M₀' → M₀) (hf : injective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (npow : ∀ x (n : ℕ), f (x ^ n) = f x ^ n) :
cancel_comm_monoid_with_zero M₀' | { .. hf.comm_monoid_with_zero f zero one mul npow,
.. hf.cancel_monoid_with_zero f zero one mul npow } | def | function.injective.cancel_comm_monoid_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"cancel_comm_monoid_with_zero"
] | Pullback a `cancel_comm_monoid_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.group_with_zero [has_zero G₀'] [has_mul G₀'] [has_one G₀']
[has_inv G₀'] [has_div G₀'] [has_pow G₀' ℕ] [has_pow G₀' ℤ]
(f : G₀' → G₀) (hf : injective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (inv : ∀ x, f x⁻¹ = (f x)⁻¹)
(div : ∀ x y, f (x / y) = f x / f y) (npo... | { inv_zero := hf $ by erw [inv, zero, inv_zero],
mul_inv_cancel := λ x hx, hf $ by erw [one, mul, inv, mul_inv_cancel ((hf.ne_iff' zero).2 hx)],
.. hf.monoid_with_zero f zero one mul npow,
.. hf.div_inv_monoid f one mul inv div npow zpow,
.. pullback_nonzero f zero one, } | def | function.injective.group_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"group_with_zero",
"inv_zero",
"mul_inv_cancel",
"pullback_nonzero"
] | Pullback a `group_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.group_with_zero [has_zero G₀'] [has_mul G₀'] [has_one G₀']
[has_inv G₀'] [has_div G₀'] [has_pow G₀' ℕ] [has_pow G₀' ℤ]
(h01 : (0:G₀') ≠ 1) (f : G₀ → G₀') (hf : surjective f)
(zero : f 0 = 0) (one : f 1 = 1) (mul : ∀ x y, f (x * y) = f x * f y)
(inv : ∀ x, f x⁻¹ = (f x)⁻¹) (div : ∀ x y, f (x ... | { inv_zero := by erw [← zero, ← inv, inv_zero],
mul_inv_cancel := hf.forall.2 $ λ x hx,
by erw [← inv, ← mul, mul_inv_cancel (mt (congr_arg f) $ trans_rel_left ne hx zero.symm)];
exact one,
exists_pair_ne := ⟨0, 1, h01⟩,
.. hf.monoid_with_zero f zero one mul npow,
.. hf.div_inv_monoid f one mul inv di... | def | function.surjective.group_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"exists_pair_ne",
"group_with_zero",
"inv_zero",
"mul_inv_cancel"
] | Pushforward a `group_with_zero` class along an surjective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.injective.comm_group_with_zero [has_zero G₀'] [has_mul G₀'] [has_one G₀']
[has_inv G₀'] [has_div G₀'] [has_pow G₀' ℕ] [has_pow G₀' ℤ]
(f : G₀' → G₀) (hf : injective f) (zero : f 0 = 0) (one : f 1 = 1)
(mul : ∀ x y, f (x * y) = f x * f y) (inv : ∀ x, f x⁻¹ = (f x)⁻¹)
(div : ∀ x y, f (x / y) = f x / f y)... | { .. hf.group_with_zero f zero one mul inv div npow zpow, .. hf.comm_semigroup f mul } | def | function.injective.comm_group_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"comm_group_with_zero"
] | Pullback a `comm_group_with_zero` class along an injective function.
See note [reducible non-instances]. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
function.surjective.comm_group_with_zero [has_zero G₀'] [has_mul G₀']
[has_one G₀'] [has_inv G₀'] [has_div G₀'] [has_pow G₀' ℕ] [has_pow G₀' ℤ]
(h01 : (0:G₀') ≠ 1) (f : G₀ → G₀') (hf : surjective f)
(zero : f 0 = 0) (one : f 1 = 1) (mul : ∀ x y, f (x * y) = f x * f y) (inv : ∀ x, f x⁻¹ = (f x)⁻¹)
(div : ∀ x y, ... | { .. hf.group_with_zero h01 f zero one mul inv div npow zpow, .. hf.comm_semigroup f mul } | def | function.surjective.comm_group_with_zero | algebra.group_with_zero | src/algebra/group_with_zero/inj_surj.lean | [
"algebra.group.inj_surj",
"algebra.group_with_zero.defs"
] | [
"comm_group_with_zero"
] | Pushforward a `comm_group_with_zero` class along a surjective function. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
pow_sub₀ (a : G₀) {m n : ℕ} (ha : a ≠ 0) (h : n ≤ m) : a ^ (m - n) = a ^ m * (a ^ n)⁻¹ | have h1 : m - n + n = m, from tsub_add_cancel_of_le h,
have h2 : a ^ (m - n) * a ^ n = a ^ m, by rw [←pow_add, h1],
by simpa only [div_eq_mul_inv] using eq_div_of_mul_eq (pow_ne_zero _ ha) h2 | theorem | pow_sub₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"div_eq_mul_inv",
"eq_div_of_mul_eq",
"pow_ne_zero",
"tsub_add_cancel_of_le"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
pow_sub_of_lt (a : G₀) {m n : ℕ} (h : n < m) : a ^ (m - n) = a ^ m * (a ^ n)⁻¹ | begin
obtain rfl | ha := eq_or_ne a 0,
{ rw [zero_pow (tsub_pos_of_lt h), zero_pow (n.zero_le.trans_lt h), zero_mul] },
{ exact pow_sub₀ _ ha h.le }
end | lemma | pow_sub_of_lt | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"eq_or_ne",
"pow_sub₀",
"tsub_pos_of_lt",
"zero_mul",
"zero_pow"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
pow_inv_comm₀ (a : G₀) (m n : ℕ) : (a⁻¹) ^ m * a ^ n = a ^ n * (a⁻¹) ^ m | (commute.refl a).inv_left₀.pow_pow m n | theorem | pow_inv_comm₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute.refl"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_pow_sub₀ (ha : a ≠ 0) (h : n ≤ m) : a⁻¹ ^ (m - n) = (a ^ m)⁻¹ * a ^ n | by rw [pow_sub₀ _ (inv_ne_zero ha) h, inv_pow, inv_pow, inv_inv] | lemma | inv_pow_sub₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"inv_inv",
"inv_ne_zero",
"inv_pow",
"pow_sub₀"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_pow_sub_of_lt (a : G₀) (h : n < m) : a⁻¹ ^ (m - n) = (a ^ m)⁻¹ * a ^ n | by rw [pow_sub_of_lt a⁻¹ h, inv_pow, inv_pow, inv_inv] | lemma | inv_pow_sub_of_lt | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"inv_inv",
"inv_pow",
"pow_sub_of_lt"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zero_zpow : ∀ z : ℤ, z ≠ 0 → (0 : G₀) ^ z = 0 | | (n : ℕ) h := by { rw [zpow_coe_nat, zero_pow'], simpa using h }
| -[1+n] h := by simp | lemma | zero_zpow | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zero_pow'",
"zpow_coe_nat"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zero_zpow_eq (n : ℤ) : (0 : G₀) ^ n = if n = 0 then 1 else 0 | begin
split_ifs with h,
{ rw [h, zpow_zero] },
{ rw [zero_zpow _ h] }
end | lemma | zero_zpow_eq | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zero_zpow",
"zpow_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_add_one₀ {a : G₀} (ha : a ≠ 0) : ∀ n : ℤ, a ^ (n + 1) = a ^ n * a | | (n : ℕ) := by simp only [← int.coe_nat_succ, zpow_coe_nat, pow_succ']
| -[1+0] := by erw [zpow_zero, zpow_neg_succ_of_nat, pow_one, inv_mul_cancel ha]
| -[1+(n+1)] := by rw [int.neg_succ_of_nat_eq, zpow_neg, neg_add, neg_add_cancel_right, zpow_neg,
← int.coe_nat_succ, zpow_coe_nat, zpow_coe_nat, pow_succ _ (... | lemma | zpow_add_one₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"inv_mul_cancel",
"mul_assoc",
"mul_inv_rev",
"mul_one",
"pow_one",
"pow_succ",
"pow_succ'",
"zpow_coe_nat",
"zpow_neg",
"zpow_neg_succ_of_nat",
"zpow_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_sub_one₀ {a : G₀} (ha : a ≠ 0) (n : ℤ) : a ^ (n - 1) = a ^ n * a⁻¹ | calc a ^ (n - 1) = a ^ (n - 1) * a * a⁻¹ : by rw [mul_assoc, mul_inv_cancel ha, mul_one]
... = a^n * a⁻¹ : by rw [← zpow_add_one₀ ha, sub_add_cancel] | lemma | zpow_sub_one₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"mul_assoc",
"mul_inv_cancel",
"mul_one",
"zpow_add_one₀"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_add₀ {a : G₀} (ha : a ≠ 0) (m n : ℤ) : a ^ (m + n) = a ^ m * a ^ n | begin
induction n using int.induction_on with n ihn n ihn,
case hz : { simp },
{ simp only [← add_assoc, zpow_add_one₀ ha, ihn, mul_assoc] },
{ rw [zpow_sub_one₀ ha, ← mul_assoc, ← ihn, ← zpow_sub_one₀ ha, add_sub_assoc] }
end | lemma | zpow_add₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"int.induction_on",
"mul_assoc",
"zpow_add_one₀",
"zpow_sub_one₀"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_add' {a : G₀} {m n : ℤ} (h : a ≠ 0 ∨ m + n ≠ 0 ∨ m = 0 ∧ n = 0) :
a ^ (m + n) = a ^ m * a ^ n | begin
by_cases hm : m = 0, { simp [hm] },
by_cases hn : n = 0, { simp [hn] },
by_cases ha : a = 0,
{ subst a,
simp only [false_or, eq_self_iff_true, not_true, ne.def, hm, hn, false_and, or_false] at h,
rw [zero_zpow _ h, zero_zpow _ hm, zero_mul] },
{ exact zpow_add₀ ha m n }
end | lemma | zpow_add' | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zero_mul",
"zero_zpow",
"zpow_add₀"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_one_add₀ {a : G₀} (h : a ≠ 0) (i : ℤ) : a ^ (1 + i) = a * a ^ i | by rw [zpow_add₀ h, zpow_one] | theorem | zpow_one_add₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zpow_add₀",
"zpow_one"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
semiconj_by.zpow_right₀ {a x y : G₀} (h : semiconj_by a x y) :
∀ m : ℤ, semiconj_by a (x^m) (y^m) | | (n : ℕ) := by simp [h.pow_right n]
| -[1+n] := by simp [(h.pow_right (n + 1)).inv_right₀] | theorem | semiconj_by.zpow_right₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"semiconj_by"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
commute.zpow_right₀ {a b : G₀} (h : commute a b) : ∀ m : ℤ, commute a (b^m) | h.zpow_right₀ | theorem | commute.zpow_right₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
commute.zpow_left₀ {a b : G₀} (h : commute a b) (m : ℤ) : commute (a^m) b | (h.symm.zpow_right₀ m).symm | theorem | commute.zpow_left₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
commute.zpow_zpow₀ {a b : G₀} (h : commute a b) (m n : ℤ) : commute (a^m) (b^n) | (h.zpow_left₀ m).zpow_right₀ n | theorem | commute.zpow_zpow₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
commute.zpow_self₀ (a : G₀) (n : ℤ) : commute (a^n) a | (commute.refl a).zpow_left₀ n | theorem | commute.zpow_self₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute",
"commute.refl"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
commute.self_zpow₀ (a : G₀) (n : ℤ) : commute a (a^n) | (commute.refl a).zpow_right₀ n | theorem | commute.self_zpow₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute",
"commute.refl"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
commute.zpow_zpow_self₀ (a : G₀) (m n : ℤ) : commute (a^m) (a^n) | (commute.refl a).zpow_zpow₀ m n | theorem | commute.zpow_zpow_self₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute",
"commute.refl"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_bit1₀ (a : G₀) (n : ℤ) : a ^ bit1 n = a ^ n * a ^ n * a | begin
rw [← zpow_bit0, bit1, zpow_add', zpow_one],
right, left,
apply bit1_ne_zero
end | theorem | zpow_bit1₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zpow_add'",
"zpow_bit0",
"zpow_one"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_ne_zero_of_ne_zero {a : G₀} (ha : a ≠ 0) : ∀ (z : ℤ), a ^ z ≠ 0 | | (n : ℕ) := by { rw zpow_coe_nat, exact pow_ne_zero _ ha }
| -[1+n] := by { rw zpow_neg_succ_of_nat, exact inv_ne_zero (pow_ne_zero _ ha) } | lemma | zpow_ne_zero_of_ne_zero | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"inv_ne_zero",
"pow_ne_zero",
"zpow_coe_nat",
"zpow_neg_succ_of_nat"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_sub₀ {a : G₀} (ha : a ≠ 0) (z1 z2 : ℤ) : a ^ (z1 - z2) = a ^ z1 / a ^ z2 | by rw [sub_eq_add_neg, zpow_add₀ ha, zpow_neg, div_eq_mul_inv] | lemma | zpow_sub₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"div_eq_mul_inv",
"zpow_add₀",
"zpow_neg"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_bit1' (a : G₀) (n : ℤ) : a ^ bit1 n = (a * a) ^ n * a | by rw [zpow_bit1₀, (commute.refl a).mul_zpow] | theorem | zpow_bit1' | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"commute.refl",
"mul_zpow",
"zpow_bit1₀"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_eq_zero {x : G₀} {n : ℤ} (h : x ^ n = 0) : x = 0 | classical.by_contradiction $ λ hx, zpow_ne_zero_of_ne_zero hx n h | lemma | zpow_eq_zero | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zpow_ne_zero_of_ne_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_eq_zero_iff {a : G₀} {n : ℤ} (hn : n ≠ 0) :
a ^ n = 0 ↔ a = 0 | ⟨zpow_eq_zero, λ ha, ha.symm ▸ zero_zpow _ hn⟩ | lemma | zpow_eq_zero_iff | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zero_zpow"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_ne_zero {x : G₀} (n : ℤ) : x ≠ 0 → x ^ n ≠ 0 | mt zpow_eq_zero | lemma | zpow_ne_zero | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"zpow_eq_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zpow_neg_mul_zpow_self (n : ℤ) {x : G₀} (h : x ≠ 0) :
x ^ (-n) * x ^ n = 1 | begin
rw [zpow_neg],
exact inv_mul_cancel (zpow_ne_zero n h)
end | theorem | zpow_neg_mul_zpow_self | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"inv_mul_cancel",
"zpow_ne_zero",
"zpow_neg"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
div_sq_cancel (a b : G₀) : a ^ 2 * b / a = a * b | begin
by_cases ha : a = 0,
{ simp [ha] },
rw [sq, mul_assoc, mul_div_cancel_left _ ha]
end | lemma | div_sq_cancel | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"mul_assoc",
"mul_div_cancel_left"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
map_zpow₀ {F G₀ G₀' : Type*} [group_with_zero G₀] [group_with_zero G₀']
[monoid_with_zero_hom_class F G₀ G₀'] (f : F) (x : G₀) (n : ℤ) :
f (x ^ n) = f x ^ n | map_zpow' f (map_inv₀ f) x n | lemma | map_zpow₀ | algebra.group_with_zero | src/algebra/group_with_zero/power.lean | [
"algebra.group_power.lemmas",
"data.int.bitwise"
] | [
"group_with_zero",
"map_inv₀",
"map_zpow'",
"monoid_with_zero_hom_class"
] | If a monoid homomorphism `f` between two `group_with_zero`s maps `0` to `0`, then it maps `x^n`,
`n : ℤ`, to `(f x)^n`. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
zero_right [mul_zero_class G₀] (a : G₀) : semiconj_by a 0 0 | by simp only [semiconj_by, mul_zero, zero_mul] | lemma | semiconj_by.zero_right | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"mul_zero",
"mul_zero_class",
"semiconj_by",
"zero_mul"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
zero_left [mul_zero_class G₀] (x y : G₀) : semiconj_by 0 x y | by simp only [semiconj_by, mul_zero, zero_mul] | lemma | semiconj_by.zero_left | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"mul_zero",
"mul_zero_class",
"semiconj_by",
"zero_mul"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_symm_left_iff₀ : semiconj_by a⁻¹ x y ↔ semiconj_by a y x | classical.by_cases
(λ ha : a = 0, by simp only [ha, inv_zero, semiconj_by.zero_left])
(λ ha, @units_inv_symm_left_iff _ _ (units.mk0 a ha) _ _) | lemma | semiconj_by.inv_symm_left_iff₀ | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"inv_zero",
"semiconj_by",
"semiconj_by.zero_left",
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_symm_left₀ (h : semiconj_by a x y) : semiconj_by a⁻¹ y x | semiconj_by.inv_symm_left_iff₀.2 h | lemma | semiconj_by.inv_symm_left₀ | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"semiconj_by"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_right₀ (h : semiconj_by a x y) : semiconj_by a x⁻¹ y⁻¹ | begin
by_cases ha : a = 0,
{ simp only [ha, zero_left] },
by_cases hx : x = 0,
{ subst x,
simp only [semiconj_by, mul_zero, @eq_comm _ _ (y * a), mul_eq_zero] at h,
simp [h.resolve_right ha] },
{ have := mul_ne_zero ha hx,
rw [h.eq, mul_ne_zero_iff] at this,
exact @units_inv_right _ _ _ (units... | lemma | semiconj_by.inv_right₀ | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"mul_eq_zero",
"mul_ne_zero",
"mul_ne_zero_iff",
"mul_zero",
"semiconj_by",
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_right_iff₀ : semiconj_by a x⁻¹ y⁻¹ ↔ semiconj_by a x y | ⟨λ h, inv_inv x ▸ inv_inv y ▸ h.inv_right₀, inv_right₀⟩ | lemma | semiconj_by.inv_right_iff₀ | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"inv_inv",
"semiconj_by"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
div_right (h : semiconj_by a x y) (h' : semiconj_by a x' y') :
semiconj_by a (x / x') (y / y') | by { rw [div_eq_mul_inv, div_eq_mul_inv], exact h.mul_right h'.inv_right₀ } | lemma | semiconj_by.div_right | algebra.group_with_zero | src/algebra/group_with_zero/semiconj.lean | [
"algebra.group_with_zero.units.basic",
"algebra.group.semiconj"
] | [
"div_eq_mul_inv",
"semiconj_by"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
ne_zero [nontrivial M₀] (u : M₀ˣ) :
(u : M₀) ≠ 0 | left_ne_zero_of_mul_eq_one u.mul_inv | lemma | units.ne_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"left_ne_zero_of_mul_eq_one",
"ne_zero",
"nontrivial"
] | An element of the unit group of a nonzero monoid with zero represented as an element
of the monoid is nonzero. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
mul_left_eq_zero (u : M₀ˣ) {a : M₀} : a * u = 0 ↔ a = 0 | ⟨λ h, by simpa using mul_eq_zero_of_left h ↑u⁻¹, λ h, mul_eq_zero_of_left h u⟩ | lemma | units.mul_left_eq_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"mul_eq_zero_of_left"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mul_right_eq_zero (u : M₀ˣ) {a : M₀} : ↑u * a = 0 ↔ a = 0 | ⟨λ h, by simpa using mul_eq_zero_of_right ↑u⁻¹ h, mul_eq_zero_of_right u⟩ | lemma | units.mul_right_eq_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"mul_eq_zero_of_right"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
ne_zero [nontrivial M₀] {a : M₀} (ha : is_unit a) : a ≠ 0 | let ⟨u, hu⟩ :=
ha in hu ▸ u.ne_zero | lemma | is_unit.ne_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"ne_zero",
"nontrivial"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mul_right_eq_zero {a b : M₀} (ha : is_unit a) : a * b = 0 ↔ b = 0 | let ⟨u, hu⟩ := ha in hu ▸ u.mul_right_eq_zero | lemma | is_unit.mul_right_eq_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mul_left_eq_zero {a b : M₀} (hb : is_unit b) : a * b = 0 ↔ a = 0 | let ⟨u, hu⟩ := hb in hu ▸ u.mul_left_eq_zero | lemma | is_unit.mul_left_eq_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
is_unit_zero_iff : is_unit (0 : M₀) ↔ (0:M₀) = 1 | ⟨λ ⟨⟨_, a, (a0 : 0 * a = 1), _⟩, rfl⟩, by rwa zero_mul at a0,
λ h, @is_unit_of_subsingleton _ _ (subsingleton_of_zero_eq_one h) 0⟩ | theorem | is_unit_zero_iff | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"is_unit_of_subsingleton",
"zero_mul"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
not_is_unit_zero [nontrivial M₀] : ¬ is_unit (0 : M₀) | mt is_unit_zero_iff.1 zero_ne_one | theorem | not_is_unit_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"nontrivial",
"zero_ne_one"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse : M₀ → M₀ | λ x, if h : is_unit x then ((h.unit⁻¹ : M₀ˣ) : M₀) else 0 | def | ring.inverse | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit"
] | Introduce a function `inverse` on a monoid with zero `M₀`, which sends `x` to `x⁻¹` if `x` is
invertible and to `0` otherwise. This definition is somewhat ad hoc, but one needs a fully (rather
than partially) defined inverse function for some purposes, including for calculus.
Note that while this is in the `ring` nam... | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
inverse_unit (u : M₀ˣ) : inverse (u : M₀) = (u⁻¹ : M₀ˣ) | begin
simp only [units.is_unit, inverse, dif_pos],
exact units.inv_unique rfl
end | lemma | ring.inverse_unit | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"units.inv_unique",
"units.is_unit"
] | By definition, if `x` is invertible then `inverse x = x⁻¹`. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
inverse_non_unit (x : M₀) (h : ¬(is_unit x)) : inverse x = 0 | dif_neg h | lemma | ring.inverse_non_unit | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit"
] | By definition, if `x` is not invertible then `inverse x = 0`. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
mul_inverse_cancel (x : M₀) (h : is_unit x) : x * inverse x = 1 | by { rcases h with ⟨u, rfl⟩, rw [inverse_unit, units.mul_inv], } | lemma | ring.mul_inverse_cancel | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"units.mul_inv"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse_mul_cancel (x : M₀) (h : is_unit x) : inverse x * x = 1 | by { rcases h with ⟨u, rfl⟩, rw [inverse_unit, units.inv_mul], } | lemma | ring.inverse_mul_cancel | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"units.inv_mul"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mul_inverse_cancel_right (x y : M₀) (h : is_unit x) : y * x * inverse x = y | by rw [mul_assoc, mul_inverse_cancel x h, mul_one] | lemma | ring.mul_inverse_cancel_right | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"mul_assoc",
"mul_one"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse_mul_cancel_right (x y : M₀) (h : is_unit x) : y * inverse x * x = y | by rw [mul_assoc, inverse_mul_cancel x h, mul_one] | lemma | ring.inverse_mul_cancel_right | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"mul_assoc",
"mul_one"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mul_inverse_cancel_left (x y : M₀) (h : is_unit x) : x * (inverse x * y) = y | by rw [← mul_assoc, mul_inverse_cancel x h, one_mul] | lemma | ring.mul_inverse_cancel_left | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"mul_assoc",
"one_mul"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse_mul_cancel_left (x y : M₀) (h : is_unit x) : inverse x * (x * y) = y | by rw [← mul_assoc, inverse_mul_cancel x h, one_mul] | lemma | ring.inverse_mul_cancel_left | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"mul_assoc",
"one_mul"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse_mul_eq_iff_eq_mul (x y z : M₀) (h : is_unit x) :
inverse x * y = z ↔ y = x * z | ⟨λ h1, by rw [← h1, mul_inverse_cancel_left _ _ h], λ h1, by rw [h1, inverse_mul_cancel_left _ _ h]⟩ | lemma | ring.inverse_mul_eq_iff_eq_mul | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
eq_mul_inverse_iff_mul_eq (x y z : M₀) (h : is_unit z) :
x = y * inverse z ↔ x * z = y | ⟨λ h1, by rw [h1, inverse_mul_cancel_right _ _ h],
λ h1, by rw [← h1, mul_inverse_cancel_right _ _ h]⟩ | lemma | ring.eq_mul_inverse_iff_mul_eq | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse_one : inverse (1 : M₀) = 1 | inverse_unit 1 | lemma | ring.inverse_one | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inverse_zero : inverse (0 : M₀) = 0 | by { nontriviality, exact inverse_non_unit _ not_is_unit_zero } | lemma | ring.inverse_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"not_is_unit_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
is_unit.ring_inverse {a : M₀} : is_unit a → is_unit (ring.inverse a) | | ⟨u, hu⟩ := hu ▸ ⟨u⁻¹, (ring.inverse_unit u).symm⟩ | lemma | is_unit.ring_inverse | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"ring.inverse",
"ring.inverse_unit"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
is_unit_ring_inverse {a : M₀} : is_unit (ring.inverse a) ↔ is_unit a | ⟨λ h, begin
casesI subsingleton_or_nontrivial M₀,
{ convert h },
{ contrapose h,
rw ring.inverse_non_unit _ h,
exact not_is_unit_zero, },
end, is_unit.ring_inverse⟩ | lemma | is_unit_ring_inverse | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"not_is_unit_zero",
"ring.inverse",
"ring.inverse_non_unit",
"subsingleton_or_nontrivial"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mk0 (a : G₀) (ha : a ≠ 0) : G₀ˣ | ⟨a, a⁻¹, mul_inv_cancel ha, inv_mul_cancel ha⟩ | def | units.mk0 | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"inv_mul_cancel",
"mul_inv_cancel"
] | Embed a non-zero element of a `group_with_zero` into the unit group.
By combining this function with the operations on units,
or the `/ₚ` operation, it is possible to write a division
as a partial function with three arguments. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
mk0_one (h := one_ne_zero) :
mk0 (1 : G₀) h = 1 | by { ext, refl } | lemma | units.mk0_one | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"one_ne_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
coe_mk0 {a : G₀} (h : a ≠ 0) : (mk0 a h : G₀) = a | rfl | lemma | units.coe_mk0 | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mk0_coe (u : G₀ˣ) (h : (u : G₀) ≠ 0) : mk0 (u : G₀) h = u | units.ext rfl | lemma | units.mk0_coe | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"units.ext"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mul_inv' (u : G₀ˣ) : (u : G₀) * u⁻¹ = 1 | mul_inv_cancel u.ne_zero | lemma | units.mul_inv' | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"mul_inv_cancel"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
inv_mul' (u : G₀ˣ) : (u⁻¹ : G₀) * u = 1 | inv_mul_cancel u.ne_zero | lemma | units.inv_mul' | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"inv_mul'",
"inv_mul_cancel"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
mk0_inj {a b : G₀} (ha : a ≠ 0) (hb : b ≠ 0) :
units.mk0 a ha = units.mk0 b hb ↔ a = b | ⟨λ h, by injection h, λ h, units.ext h⟩ | lemma | units.mk0_inj | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"units.ext",
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
exists0 {p : G₀ˣ → Prop} : (∃ g : G₀ˣ, p g) ↔ ∃ (g : G₀) (hg : g ≠ 0), p (units.mk0 g hg) | ⟨λ ⟨g, pg⟩, ⟨g, g.ne_zero, (g.mk0_coe g.ne_zero).symm ▸ pg⟩, λ ⟨g, hg, pg⟩, ⟨units.mk0 g hg, pg⟩⟩ | lemma | units.exists0 | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"units.mk0"
] | In a group with zero, an existential over a unit can be rewritten in terms of `units.mk0`. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
exists0' {p : Π g : G₀, g ≠ 0 → Prop} :
(∃ (g : G₀) (hg : g ≠ 0), p g hg) ↔ ∃ g : G₀ˣ, p g g.ne_zero | iff.trans (by simp_rw [coe_mk0]) exists0.symm | lemma | units.exists0' | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [] | An alternative version of `units.exists0`. This one is useful if Lean cannot
figure out `p` when using `units.exists0` from right to left. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
exists_iff_ne_zero {x : G₀} : (∃ u : G₀ˣ, ↑u = x) ↔ x ≠ 0 | by simp [exists0] | lemma | units.exists_iff_ne_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
_root_.group_with_zero.eq_zero_or_unit (a : G₀) :
a = 0 ∨ ∃ u : G₀ˣ, a = u | begin
by_cases h : a = 0,
{ left,
exact h },
{ right,
simpa only [eq_comm] using units.exists_iff_ne_zero.mpr h }
end | lemma | group_with_zero.eq_zero_or_unit | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
is_unit.mk0 (x : G₀) (hx : x ≠ 0) : is_unit x | (units.mk0 x hx).is_unit | lemma | is_unit.mk0 | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
is_unit_iff_ne_zero : is_unit a ↔ a ≠ 0 | units.exists_iff_ne_zero | lemma | is_unit_iff_ne_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"is_unit",
"units.exists_iff_ne_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
group_with_zero.no_zero_divisors : no_zero_divisors G₀ | { eq_zero_or_eq_zero_of_mul_eq_zero := λ a b h,
begin
contrapose! h,
exact ((units.mk0 a h.1) * (units.mk0 b h.2)).ne_zero
end,
.. (‹_› : group_with_zero G₀) } | instance | group_with_zero.no_zero_divisors | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"group_with_zero",
"ne_zero",
"no_zero_divisors",
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
units.mk0_mul (x y : G₀) (hxy) :
units.mk0 (x * y) hxy =
units.mk0 x (mul_ne_zero_iff.mp hxy).1 * units.mk0 y (mul_ne_zero_iff.mp hxy).2 | by { ext, refl } | lemma | units.mk0_mul | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
div_ne_zero (ha : a ≠ 0) (hb : b ≠ 0) : a / b ≠ 0 | by { rw div_eq_mul_inv, exact mul_ne_zero ha (inv_ne_zero hb) } | lemma | div_ne_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"div_eq_mul_inv",
"inv_ne_zero",
"mul_ne_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
div_eq_zero_iff : a / b = 0 ↔ a = 0 ∨ b = 0 | by simp [div_eq_mul_inv] | lemma | div_eq_zero_iff | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"div_eq_mul_inv"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
div_ne_zero_iff : a / b ≠ 0 ↔ a ≠ 0 ∧ b ≠ 0 | div_eq_zero_iff.not.trans not_or_distrib | lemma | div_ne_zero_iff | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"not_or_distrib"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
ring.inverse_eq_inv (a : G₀) : ring.inverse a = a⁻¹ | begin
obtain rfl | ha := eq_or_ne a 0,
{ simp },
{ exact ring.inverse_unit (units.mk0 a ha) }
end | lemma | ring.inverse_eq_inv | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"eq_or_ne",
"ring.inverse",
"ring.inverse_unit",
"units.mk0"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
ring.inverse_eq_inv' : (ring.inverse : G₀ → G₀) = has_inv.inv | funext ring.inverse_eq_inv | lemma | ring.inverse_eq_inv' | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"ring.inverse",
"ring.inverse_eq_inv"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
comm_group_with_zero.to_cancel_comm_monoid_with_zero : cancel_comm_monoid_with_zero G₀ | { ..group_with_zero.to_cancel_monoid_with_zero, ..comm_group_with_zero.to_comm_monoid_with_zero G₀ } | instance | comm_group_with_zero.to_cancel_comm_monoid_with_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"cancel_comm_monoid_with_zero",
"group_with_zero.to_cancel_monoid_with_zero"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
comm_group_with_zero.to_division_comm_monoid : division_comm_monoid G₀ | { ..‹comm_group_with_zero G₀›, ..group_with_zero.to_division_monoid } | instance | comm_group_with_zero.to_division_comm_monoid | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"division_comm_monoid",
"group_with_zero.to_division_monoid"
] | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 | |
group_with_zero_of_is_unit_or_eq_zero [hM : monoid_with_zero M]
(h : ∀ (a : M), is_unit a ∨ a = 0) : group_with_zero M | { inv := λ a, if h0 : a = 0 then 0 else ↑((h a).resolve_right h0).unit⁻¹,
inv_zero := dif_pos rfl,
mul_inv_cancel := λ a h0, by
{ change a * (if h0 : a = 0 then 0 else ↑((h a).resolve_right h0).unit⁻¹) = 1,
rw [dif_neg h0, units.mul_inv_eq_iff_eq_mul, one_mul, is_unit.unit_spec] },
exists_pair_ne := nontriv... | def | group_with_zero_of_is_unit_or_eq_zero | algebra.group_with_zero.units | src/algebra/group_with_zero/units/basic.lean | [
"algebra.group_with_zero.basic",
"algebra.group.units",
"tactic.nontriviality",
"tactic.assert_exists"
] | [
"exists_pair_ne",
"group_with_zero",
"inv_zero",
"is_unit",
"is_unit.unit_spec",
"monoid_with_zero",
"mul_inv_cancel",
"one_mul",
"units.mul_inv_eq_iff_eq_mul"
] | Constructs a `group_with_zero` structure on a `monoid_with_zero`
consisting only of units and 0. | https://github.com/leanprover-community/mathlib | 65a1391a0106c9204fe45bc73a039f056558cb83 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.