-
Notifications
You must be signed in to change notification settings - Fork 899
RFC Exp function
We have three definitions:
Real.exp : ℝ → ℝComplex.exp : ℂ → ℂNormedSpace.exp (𝕂 : Type*) {A : Type*} [...] [Algebra 𝕂 A] : A → A
The first 2 definitions work for specific types, the last one generalizes both but takes an extra argument K
which is used to compute ((n ! : ℕ) : 𝕂)⁻¹ • x ^ n.
We want to merge these three definitions into one. The new definition must work at least for Banach algebras over rational, real, complex, and p-adic numbers.
We can require that our ring is an algebra over rational numbers. We do not require that this is a normed algebra, so the definition works for algebras over p-adic numbers.
The main downside of this approach is that we don't have instances deducing [Algebra ℚ A] from [Algebra ℝ A] or [Algebra ℚ_[p] A].
So, with this approach we have a choice
- either add these instances, opening another door for non-defeq instance diamonds;
- or require users to explicitly assume
[Algebra ℚ A]to work withexp.
We can leave NormedSpace.exp as is, but merge Real.exp with Complex.exp into a new definition Real.exp that works for any Banach algebra over real numbers. Algebras over p-adics can use NormedSpace.exp directly.
Use DividedPowers
... or a similar typeclass/structure. This approach has the same downsides as fixing the base field to be rational numbers.