The complex numbers #
The complex numbers are modelled as ℝ^2 in the obvious way and it is shown that they form a field
of characteristic zero. The result that the complex numbers are algebraically closed, see
FieldTheory.AlgebraicClosure
.
Definition and basic arithmetic #
Complex numbers consist of two Real
s: a real part re
and an imaginary part im
.
Equations
- termℂ = Lean.ParserDescr.node `termℂ 1024 (Lean.ParserDescr.symbol "ℂ")
Instances For
Equations
The natural inclusion of the real numbers into the complex numbers.
The name Complex.ofReal
is reserved for the bundled homomorphism.
Equations
- ↑r = { re := r, im := 0 }
Instances For
Equations
- Complex.instCoeRealComplex = { coe := Complex.ofReal' }
Equations
The product of a set on the real axis and a set on the imaginary axis of the complex plane,
denoted by s ×ℂ t
.
Equations
- s ×ℂ t = Complex.re ⁻¹' s ∩ Complex.im ⁻¹' t
Instances For
Equations
- Complex.«term_×ℂ_» = Lean.ParserDescr.trailingNode `Complex.term_×ℂ_ 72 72 (Lean.ParserDescr.binary `andthen (Lean.ParserDescr.symbol " ×ℂ ") (Lean.ParserDescr.cat `term 73))
Instances For
Equations
- Complex.instInhabitedComplex = { default := 0 }
Equations
- Complex.instAddComplex = { add := fun (z w : ℂ) => { re := z.re + w.re, im := z.im + w.im } }
Equations
- Complex.instNegComplex = { neg := fun (z : ℂ) => { re := -z.re, im := -z.im } }
Equations
- Complex.instSubComplex = { sub := fun (z w : ℂ) => { re := z.re - w.re, im := z.im - w.im } }
Commutative ring instance and lemmas #
Equations
Equations
- One or more equations did not get rendered due to their size.
Equations
This shortcut instance ensures we do not find Ring
via the noncomputable Complex.field
instance.
Equations
- Complex.instRingComplex = inferInstance
This shortcut instance ensures we do not find CommSemiring
via the noncomputable
Complex.field
instance.
Equations
- Complex.instCommSemiringComplex = inferInstance
This shortcut instance ensures we do not find Semiring
via the noncomputable
Complex.field
instance.
Equations
- Complex.instSemiringComplex = inferInstance
The "real part" map, considered as an additive group homomorphism.
Equations
- Complex.reAddGroupHom = { toZeroHom := { toFun := Complex.re, map_zero' := Complex.zero_re }, map_add' := Complex.add_re }
Instances For
The "imaginary part" map, considered as an additive group homomorphism.
Equations
- Complex.imAddGroupHom = { toZeroHom := { toFun := Complex.im, map_zero' := Complex.zero_im }, map_add' := Complex.add_im }
Instances For
Equations
- Complex.instRatCastComplex = { ratCast := fun (q : ℚ) => ↑↑q }
Complex conjugation #
This defines the complex conjugate as the star
operation of the StarRing ℂ
. It
is recommended to use the ring endomorphism version starRingEnd
, available under the
notation conj
in the locale ComplexConjugate
.
Equations
- One or more equations did not get rendered due to their size.
Norm squared #
The norm squared function.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Inversion #
Equations
- Complex.instInvComplex = { inv := fun (z : ℂ) => (starRingEnd ℂ) z * ↑(Complex.normSq z)⁻¹ }
Cast lemmas #
Field instance and lemmas #
Equations
- One or more equations did not get rendered due to their size.
Characteristic zero #
A complex number z
plus its conjugate conj z
is 2
times its real part.
A complex number z
minus its conjugate conj z
is 2i
times its imaginary part.