Documentation

Mathlib.Algebra.Field.Basic

Lemmas about division (semi)rings and (semi)fields #

theorem add_div {K : Type u_1} [DivisionSemiring K] (a b c : K) :
(a + b) / c = a / c + b / c
@[deprecated add_div (since := "2025-08-25")]
theorem div_add_div_same {K : Type u_1} [DivisionSemiring K] (a b c : K) :
a / c + b / c = (a + b) / c
theorem same_add_div {K : Type u_1} [DivisionSemiring K] {a b : K} (h : b β‰  0) :
(b + a) / b = 1 + a / b
theorem div_add_same {K : Type u_1} [DivisionSemiring K] {a b : K} (h : b β‰  0) :
(a + b) / b = a / b + 1
theorem one_add_div {K : Type u_1} [DivisionSemiring K] {a b : K} (h : b β‰  0) :
1 + a / b = (b + a) / b
theorem div_add_one {K : Type u_1} [DivisionSemiring K] {a b : K} (h : b β‰  0) :
a / b + 1 = (a + b) / b
theorem inv_add_inv' {K : Type u_1} [DivisionSemiring K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :

See inv_add_inv for the more convenient version when K is commutative.

theorem one_div_mul_add_mul_one_div_eq_one_div_add_one_div {K : Type u_1} [DivisionSemiring K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :
1 / a * (a + b) * (1 / b) = 1 / a + 1 / b
theorem add_div_eq_mul_add_div {K : Type u_1} [DivisionSemiring K] {c : K} (a b : K) (hc : c β‰  0) :
a + b / c = (a * c + b) / c
theorem add_div' {K : Type u_1} [DivisionSemiring K] (a b c : K) (hc : c β‰  0) :
b + a / c = (b * c + a) / c
theorem div_add' {K : Type u_1} [DivisionSemiring K] (a b c : K) (hc : c β‰  0) :
a / c + b = (a + b * c) / c
theorem Commute.div_add_div {K : Type u_1} [DivisionSemiring K] {a b c d : K} (hbc : Commute b c) (hbd : Commute b d) (hb : b β‰  0) (hd : d β‰  0) :
a / b + c / d = (a * d + b * c) / (b * d)
theorem Commute.one_div_add_one_div {K : Type u_1} [DivisionSemiring K] {a b : K} (hab : Commute a b) (ha : a β‰  0) (hb : b β‰  0) :
1 / a + 1 / b = (a + b) / (a * b)
theorem Commute.inv_add_inv {K : Type u_1} [DivisionSemiring K] {a b : K} (hab : Commute a b) (ha : a β‰  0) (hb : b β‰  0) :
a⁻¹ + b⁻¹ = (a + b) / (a * b)
@[simp]
theorem add_self_div_two {K : Type u_1} [DivisionSemiring K] [NeZero 2] (a : K) :
(a + a) / 2 = a
@[simp]
theorem add_halves {K : Type u_1} [DivisionSemiring K] [NeZero 2] (a : K) :
a / 2 + a / 2 = a
@[simp]
theorem div_neg_self {K : Type u_1} [DivisionRing K] {a : K} (h : a β‰  0) :
a / -a = -1
@[simp]
theorem neg_div_self {K : Type u_1} [DivisionRing K] {a : K} (h : a β‰  0) :
-a / a = -1
theorem div_sub_div_same {K : Type u_1} [DivisionRing K] (a b c : K) :
a / c - b / c = (a - b) / c
theorem same_sub_div {K : Type u_1} [DivisionRing K] {a b : K} (h : b β‰  0) :
(b - a) / b = 1 - a / b
theorem one_sub_div {K : Type u_1} [DivisionRing K] {a b : K} (h : b β‰  0) :
1 - a / b = (b - a) / b
theorem div_sub_same {K : Type u_1} [DivisionRing K] {a b : K} (h : b β‰  0) :
(a - b) / b = a / b - 1
theorem div_sub_one {K : Type u_1} [DivisionRing K] {a b : K} (h : b β‰  0) :
a / b - 1 = (a - b) / b
theorem sub_div {K : Type u_1} [DivisionRing K] (a b c : K) :
(a - b) / c = a / c - b / c
theorem inv_sub_inv' {K : Type u_1} [DivisionRing K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :

See inv_sub_inv for the more convenient version when K is commutative.

theorem one_div_mul_sub_mul_one_div_eq_one_div_add_one_div {K : Type u_1} [DivisionRing K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :
1 / a * (b - a) * (1 / b) = 1 / a - 1 / b
theorem inv_eq_selfβ‚€ {K : Type u_1} [DivisionRing K] {a : K} :
a⁻¹ = a ↔ a = -1 ∨ a = 0 ∨ a = 1
theorem self_eq_invβ‚€ {K : Type u_1} [DivisionRing K] {a : K} :
a = a⁻¹ ↔ a = -1 ∨ a = 0 ∨ a = 1
@[instance 100]
theorem Commute.div_sub_div {K : Type u_1} [DivisionRing K] {a b c d : K} (hbc : Commute b c) (hbd : Commute b d) (hb : b β‰  0) (hd : d β‰  0) :
a / b - c / d = (a * d - b * c) / (b * d)
theorem Commute.inv_sub_inv {K : Type u_1} [DivisionRing K] {a b : K} (hab : Commute a b) (ha : a β‰  0) (hb : b β‰  0) :
a⁻¹ - b⁻¹ = (b - a) / (a * b)
theorem sub_half {K : Type u_1} [DivisionRing K] [NeZero 2] (a : K) :
a - a / 2 = a / 2
theorem half_sub {K : Type u_1} [DivisionRing K] [NeZero 2] (a : K) :
a / 2 - a = -(a / 2)
theorem div_add_div {K : Type u_1} [Semifield K] {b d : K} (a c : K) (hb : b β‰  0) (hd : d β‰  0) :
a / b + c / d = (a * d + b * c) / (b * d)
theorem one_div_add_one_div {K : Type u_1} [Semifield K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :
1 / a + 1 / b = (a + b) / (a * b)
theorem inv_add_inv {K : Type u_1} [Semifield K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :
a⁻¹ + b⁻¹ = (a + b) / (a * b)
@[instance 100]
instance Field.toGrindField {K : Type u_1} [Field K] :
Equations
    theorem div_sub_div {K : Type u_1} [Field K] (a : K) {b : K} (c : K) {d : K} (hb : b β‰  0) (hd : d β‰  0) :
    a / b - c / d = (a * d - b * c) / (b * d)
    theorem inv_sub_inv {K : Type u_1} [Field K] {a b : K} (ha : a β‰  0) (hb : b β‰  0) :
    a⁻¹ - b⁻¹ = (b - a) / (a * b)
    theorem sub_div' {K : Type u_1} [Field K] {a b c : K} (hc : c β‰  0) :
    b - a / c = (b * c - a) / c
    theorem div_sub' {K : Type u_1} [Field K] {a b c : K} (hc : c β‰  0) :
    a / c - b = (a - c * b) / c
    @[instance 100]
    instance Field.isDomain {K : Type u_1} [Field K] :
    @[reducible, inline]
    noncomputable abbrev DivisionRing.ofIsUnitOrEqZero {R : Type u_3} [Nontrivial R] [Ring R] (h : βˆ€ (a : R), IsUnit a ∨ a = 0) :

    Constructs a DivisionRing structure on a Ring consisting only of units and 0.

    Equations
      Instances For
        @[reducible, inline]
        noncomputable abbrev Field.ofIsUnitOrEqZero {R : Type u_3} [Nontrivial R] [CommRing R] (h : βˆ€ (a : R), IsUnit a ∨ a = 0) :

        Constructs a Field structure on a CommRing consisting only of units and 0.

        Equations
          Instances For
            @[reducible, inline]
            abbrev Function.Injective.divisionSemiring {K : Type u_1} {L : Type u_2} [Zero K] [Add K] [One K] [Mul K] [Inv K] [Div K] [SMul β„• K] [SMul β„šβ‰₯0 K] [Pow K β„•] [Pow K β„€] [NatCast K] [NNRatCast K] (f : K β†’ L) (hf : Injective f) [DivisionSemiring L] (zero : f 0 = 0) (one : f 1 = 1) (add : βˆ€ (x y : K), f (x + y) = f x + f y) (mul : βˆ€ (x y : K), f (x * y) = f x * f y) (inv : βˆ€ (x : K), f x⁻¹ = (f x)⁻¹) (div : βˆ€ (x y : K), f (x / y) = f x / f y) (nsmul : βˆ€ (n : β„•) (x : K), f (n β€’ x) = n β€’ f x) (nnqsmul : βˆ€ (q : β„šβ‰₯0) (x : K), f (q β€’ x) = q β€’ f x) (npow : βˆ€ (x : K) (n : β„•), f (x ^ n) = f x ^ n) (zpow : βˆ€ (x : K) (n : β„€), f (x ^ n) = f x ^ n) (natCast : βˆ€ (n : β„•), f ↑n = ↑n) (nnratCast : βˆ€ (q : β„šβ‰₯0), f ↑q = ↑q) :

            Pullback a DivisionSemiring along an injective function.

            Equations
              Instances For
                @[reducible, inline]
                abbrev Function.Injective.divisionRing {K : Type u_1} {L : Type u_2} [Zero K] [Add K] [Neg K] [Sub K] [One K] [Mul K] [Inv K] [Div K] [SMul β„• K] [SMul β„€ K] [SMul β„šβ‰₯0 K] [SMul β„š K] [Pow K β„•] [Pow K β„€] [NatCast K] [IntCast K] [NNRatCast K] [RatCast K] (f : K β†’ L) (hf : Injective f) [DivisionRing L] (zero : f 0 = 0) (one : f 1 = 1) (add : βˆ€ (x y : K), f (x + y) = f x + f y) (mul : βˆ€ (x y : K), f (x * y) = f x * f y) (neg : βˆ€ (x : K), f (-x) = -f x) (sub : βˆ€ (x y : K), f (x - y) = f x - f y) (inv : βˆ€ (x : K), f x⁻¹ = (f x)⁻¹) (div : βˆ€ (x y : K), f (x / y) = f x / f y) (nsmul : βˆ€ (n : β„•) (x : K), f (n β€’ x) = n β€’ f x) (zsmul : βˆ€ (n : β„€) (x : K), f (n β€’ x) = n β€’ f x) (nnqsmul : βˆ€ (q : β„šβ‰₯0) (x : K), f (q β€’ x) = q β€’ f x) (qsmul : βˆ€ (q : β„š) (x : K), f (q β€’ x) = q β€’ f x) (npow : βˆ€ (x : K) (n : β„•), f (x ^ n) = f x ^ n) (zpow : βˆ€ (x : K) (n : β„€), f (x ^ n) = f x ^ n) (natCast : βˆ€ (n : β„•), f ↑n = ↑n) (intCast : βˆ€ (n : β„€), f ↑n = ↑n) (nnratCast : βˆ€ (q : β„šβ‰₯0), f ↑q = ↑q) (ratCast : βˆ€ (q : β„š), f ↑q = ↑q) :

                Pullback a DivisionSemiring along an injective function.

                Equations
                  Instances For
                    @[reducible, inline]
                    abbrev Function.Injective.semifield {K : Type u_1} {L : Type u_2} [Zero K] [Add K] [One K] [Mul K] [Inv K] [Div K] [SMul β„• K] [SMul β„šβ‰₯0 K] [Pow K β„•] [Pow K β„€] [NatCast K] [NNRatCast K] (f : K β†’ L) (hf : Injective f) [Semifield L] (zero : f 0 = 0) (one : f 1 = 1) (add : βˆ€ (x y : K), f (x + y) = f x + f y) (mul : βˆ€ (x y : K), f (x * y) = f x * f y) (inv : βˆ€ (x : K), f x⁻¹ = (f x)⁻¹) (div : βˆ€ (x y : K), f (x / y) = f x / f y) (nsmul : βˆ€ (n : β„•) (x : K), f (n β€’ x) = n β€’ f x) (nnqsmul : βˆ€ (q : β„šβ‰₯0) (x : K), f (q β€’ x) = q β€’ f x) (npow : βˆ€ (x : K) (n : β„•), f (x ^ n) = f x ^ n) (zpow : βˆ€ (x : K) (n : β„€), f (x ^ n) = f x ^ n) (natCast : βˆ€ (n : β„•), f ↑n = ↑n) (nnratCast : βˆ€ (q : β„šβ‰₯0), f ↑q = ↑q) :

                    Pullback a Field along an injective function.

                    Equations
                      Instances For
                        @[reducible, inline]
                        abbrev Function.Injective.field {K : Type u_1} {L : Type u_2} [Zero K] [Add K] [Neg K] [Sub K] [One K] [Mul K] [Inv K] [Div K] [SMul β„• K] [SMul β„€ K] [SMul β„šβ‰₯0 K] [SMul β„š K] [Pow K β„•] [Pow K β„€] [NatCast K] [IntCast K] [NNRatCast K] [RatCast K] (f : K β†’ L) (hf : Injective f) [Field L] (zero : f 0 = 0) (one : f 1 = 1) (add : βˆ€ (x y : K), f (x + y) = f x + f y) (mul : βˆ€ (x y : K), f (x * y) = f x * f y) (neg : βˆ€ (x : K), f (-x) = -f x) (sub : βˆ€ (x y : K), f (x - y) = f x - f y) (inv : βˆ€ (x : K), f x⁻¹ = (f x)⁻¹) (div : βˆ€ (x y : K), f (x / y) = f x / f y) (nsmul : βˆ€ (n : β„•) (x : K), f (n β€’ x) = n β€’ f x) (zsmul : βˆ€ (n : β„€) (x : K), f (n β€’ x) = n β€’ f x) (nnqsmul : βˆ€ (q : β„šβ‰₯0) (x : K), f (q β€’ x) = q β€’ f x) (qsmul : βˆ€ (q : β„š) (x : K), f (q β€’ x) = q β€’ f x) (npow : βˆ€ (x : K) (n : β„•), f (x ^ n) = f x ^ n) (zpow : βˆ€ (x : K) (n : β„€), f (x ^ n) = f x ^ n) (natCast : βˆ€ (n : β„•), f ↑n = ↑n) (intCast : βˆ€ (n : β„€), f ↑n = ↑n) (nnratCast : βˆ€ (q : β„šβ‰₯0), f ↑q = ↑q) (ratCast : βˆ€ (q : β„š), f ↑q = ↑q) :

                        Pullback a Field along an injective function.

                        Equations
                          Instances For

                            Order dual #

                            @[simp]
                            theorem toDual_ratCast {K : Type u_1} [RatCast K] (n : β„š) :
                            OrderDual.toDual ↑n = ↑n
                            @[simp]
                            theorem ofDual_ratCast {K : Type u_1} [RatCast K] (n : β„š) :
                            OrderDual.ofDual ↑n = ↑n

                            Lexicographic order #

                            instance Lex.instRatCast {K : Type u_1} [RatCast K] :
                            Equations
                              instance Lex.instField {K : Type u_1} [Field K] :
                              Equations
                                @[simp]
                                theorem toLex_ratCast {K : Type u_1} [RatCast K] (n : β„š) :
                                toLex ↑n = ↑n
                                @[simp]
                                theorem ofLex_ratCast {K : Type u_1} [RatCast K] (n : β„š) :
                                ofLex ↑n = ↑n