Interval approximations for complex numbers #
IsComputableℂ x packages IsComputable approximations for the real and imaginary parts of a
complex number x, and is closed under the field operations, powers, conjugation, norm and inner
product. This also provides DecidableEq and (with ComplexOrder) Decidable comparison
instances; like their real counterparts, these comparison instances are classical and
noncomputable.
Type class stating that x : ℂ has a ComputableℝSeq for its real and imaginary parts.
Note that we can't define this as IsComputable x.re + IsComputable x.im, because then
(if x is a noncomputable expression) this will be a noncomputable expression.
- re : IsComputable x.re
An interval-approximation witness for the real part.
- im : IsComputable x.im
An interval-approximation witness for the imaginary part.
Instances
Turns one IsComputableℂ into another one, given a proof that they're equal. This is directly
analogous to decidable_of_iff, as a way to avoid Eq.rec on data-carrying instances.
Equations
- IsComputableℂ.liftEq h = { re := IsComputable.liftEq ⋯ IsComputableℂ.re, im := IsComputable.liftEq ⋯ IsComputableℂ.im }
Instances For
Equations
Equations
Equations
- IsComputableℂ.instComputableRI r = { re := hr, im := hi }
Equations
- IsComputableℂ.instComputableI = { re := { seq := 0, prop := IsComputableℂ.instComputableI._proof_1 }, im := { seq := 1, prop := IsComputableℂ.instComputableI._proof_2 } }
Equations
- IsComputableℂ.instComputableNat n = { re := { seq := ComputableℝSeq.ofRat ↑n, prop := ⋯ }, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- IsComputableℂ.instComputableInt z = { re := { seq := ComputableℝSeq.ofRat ↑z, prop := ⋯ }, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- IsComputableℂ.instComputableRat q = { re := { seq := ComputableℝSeq.ofRat q, prop := ⋯ }, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- IsComputableℂ.instComputableReal r = { re := hr, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- IsComputableℂ.instComputableOfNat0 = { re := { seq := 0, prop := ComputableℝSeq.val_zero }, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- IsComputableℂ.instComputableOfNat1 = { re := { seq := 1, prop := ComputableℝSeq.val_one }, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- IsComputableℂ.instComputableOfNatAtLeastTwo n = { re := { seq := ComputableℝSeq.ofRat ↑n, prop := ⋯ }, im := { seq := 0, prop := ComputableℝSeq.val_zero } }
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- IsComputableℂ.instComputableMul x y = { re := IsComputable.liftEq ⋯ inferInstance, im := IsComputable.liftEq ⋯ inferInstance }
Equations
- IsComputableℂ.instComputableNatPow x n = Nat.recAux (⋯.mpr inferInstance) (fun (n : ℕ) (a : IsComputableℂ (x ^ n)) => ⋯.mpr inferInstance) n
Equations
- IsComputableℂ.instComputableStar x = { re := IsComputableℂ.re, im := have x_1 := IsComputableℂ.im; { seq := (fun (x : ComputableℝSeq) => -x) (IsComputable.seq x.im), prop := ⋯ } }
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.
Equations
Equations
- One or more equations did not get rendered due to their size.
Equations
- One or more equations did not get rendered due to their size.