-
Notifications
You must be signed in to change notification settings - Fork 247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Merged by Bors] - feat: add HasSum f a → HasProd (exp ∘ f) (exp a)
#12635
Conversation
@@ -473,6 +473,12 @@ theorem exp_continuous : Continuous (exp 𝕂 : 𝔸 → 𝔸) := by | |||
exact continuousOn_exp | |||
#align exp_continuous NormedSpace.exp_continuous | |||
|
|||
open Topology in | |||
lemma _root_.Filter.Tendsto.NormedSpace_exp {α : Type*} {l : Filter α} {f : α → 𝔸} {a : 𝔸} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think NormedSpace_exp
is compatible with the naming convention. exp_normedSpace
looks better, although not great.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The naming convention is not really explicit on how to deal with names containing a namespace like NormedSpace.exp
when they show up as part of lemma names. Unfortunately, Filter.Tendsto.exp
is already claimed by the real exponential function.
Would NormedSpace.Filter.Tendsto.exp
be a reasonable alternative?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You really want to be able to use dot notation, so it has to be Filter.Tendsto.something
. The something could be normedSpaceExp
or exp_normedSpace
or exp_of_normedSpace
. Maybe the best option is indeed normedSpaceExp
because it's a single atom, and we need a way to separate it from the other ones. Or just exp
, and use rexp
and cexp
for the real and complex version (I think that's my favorite option).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm renaming Filter.Tendsto.exp
to Filter.Tendsto.rexp
and then Filter.Tendsto.NormedSpace_exp
to Filter.Tendsto.exp
.
variable {𝕂 𝔸 : Type*} [RCLike 𝕂] [NormedCommRing 𝔸] [NormedAlgebra 𝕂 𝔸] [CompleteSpace 𝔸] | ||
|
||
/-- If `f` has sum `a`, then `exp ∘ f` has product `exp a`. -/ | ||
lemma HasSum.NormedSpace_exp {ι : Type*} {f : ι → 𝔸} {a : 𝔸} (h : HasSum f a) : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NormedSpace.hasSum_exp
perhaps? Although this would make dot notation on HasSum
unavailable here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You really want dot notation. As above, I'd go for HasSum.exp
, and use rexp
and cexp
for the real and complex versions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using HasSum.exp
now (I'm already using .rexp
for the real exponential version).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you forget to push this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like I actually forgot to change it... Thanks for spotting it!
Tendsto (fun x => exp (f x)) l (𝓝 (exp z)) := | ||
(continuous_exp.tendsto _).comp hf | ||
#align filter.tendsto.exp Filter.Tendsto.exp | ||
#align filter.tendsto.exp Filter.Tendsto.rexp | ||
|
||
variable [TopologicalSpace α] {f : α → ℝ} {s : Set α} {x : α} | ||
|
||
nonrec | ||
theorem ContinuousWithinAt.exp (h : ContinuousWithinAt f s x) : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we want to do the same to these, but I wouldn't object if you wanted to do that in a follow-up
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's perhaps mission creep for this PR. But I agree that it should be done, and I can have a look.
variable {𝕂 𝔸 : Type*} [RCLike 𝕂] [NormedCommRing 𝔸] [NormedAlgebra 𝕂 𝔸] [CompleteSpace 𝔸] | ||
|
||
/-- If `f` has sum `a`, then `exp ∘ f` has product `exp a`. -/ | ||
lemma HasSum.NormedSpace_exp {ι : Type*} {f : ι → 𝔸} {a : 𝔸} (h : HasSum f a) : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you forget to push this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maintainer merge
🚀 Pull request has been placed on the maintainer queue by Ruben-VandeVelde. |
bors r+ |
This adds lemmas saying that ` HasSum f a` implies `HasProd (exp ∘ f) (exp a)` for `exp = rexp, cexp, NormedSpace.exp`. While the `rexp` and `cexp` versions could be deduced from the `NormedSpace.exp` one, we give a direct proof (and so avoid needing to import stuff about `NormedSpace.exp` for these results; the proofs are also a bit faster that way). Based on the discussion below, this also renames `Filter.Tendsto.exp` to `Filter.Tendsto.rexp` for the version specific to the real exponential function, so that `Filter.Tendsto.exp` can be used for the corresponding statement involving `NormedSpace.exp`. See [here](https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/exp.28tsum.29.20.3D.20tprod.28exp.29/near/436891747) on Zulip. Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
Build failed (retrying...): |
This adds lemmas saying that ` HasSum f a` implies `HasProd (exp ∘ f) (exp a)` for `exp = rexp, cexp, NormedSpace.exp`. While the `rexp` and `cexp` versions could be deduced from the `NormedSpace.exp` one, we give a direct proof (and so avoid needing to import stuff about `NormedSpace.exp` for these results; the proofs are also a bit faster that way). Based on the discussion below, this also renames `Filter.Tendsto.exp` to `Filter.Tendsto.rexp` for the version specific to the real exponential function, so that `Filter.Tendsto.exp` can be used for the corresponding statement involving `NormedSpace.exp`. See [here](https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/exp.28tsum.29.20.3D.20tprod.28exp.29/near/436891747) on Zulip. Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
Build failed (retrying...): |
This adds lemmas saying that ` HasSum f a` implies `HasProd (exp ∘ f) (exp a)` for `exp = rexp, cexp, NormedSpace.exp`. While the `rexp` and `cexp` versions could be deduced from the `NormedSpace.exp` one, we give a direct proof (and so avoid needing to import stuff about `NormedSpace.exp` for these results; the proofs are also a bit faster that way). Based on the discussion below, this also renames `Filter.Tendsto.exp` to `Filter.Tendsto.rexp` for the version specific to the real exponential function, so that `Filter.Tendsto.exp` can be used for the corresponding statement involving `NormedSpace.exp`. See [here](https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/exp.28tsum.29.20.3D.20tprod.28exp.29/near/436891747) on Zulip. Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
Pull request successfully merged into master. Build succeeded: |
HasSum f a → HasProd (exp ∘ f) (exp a)
HasSum f a → HasProd (exp ∘ f) (exp a)
This adds lemmas saying that ` HasSum f a` implies `HasProd (exp ∘ f) (exp a)` for `exp = rexp, cexp, NormedSpace.exp`. While the `rexp` and `cexp` versions could be deduced from the `NormedSpace.exp` one, we give a direct proof (and so avoid needing to import stuff about `NormedSpace.exp` for these results; the proofs are also a bit faster that way). Based on the discussion below, this also renames `Filter.Tendsto.exp` to `Filter.Tendsto.rexp` for the version specific to the real exponential function, so that `Filter.Tendsto.exp` can be used for the corresponding statement involving `NormedSpace.exp`. See [here](https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/exp.28tsum.29.20.3D.20tprod.28exp.29/near/436891747) on Zulip. Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
This adds lemmas saying that ` HasSum f a` implies `HasProd (exp ∘ f) (exp a)` for `exp = rexp, cexp, NormedSpace.exp`. While the `rexp` and `cexp` versions could be deduced from the `NormedSpace.exp` one, we give a direct proof (and so avoid needing to import stuff about `NormedSpace.exp` for these results; the proofs are also a bit faster that way). Based on the discussion below, this also renames `Filter.Tendsto.exp` to `Filter.Tendsto.rexp` for the version specific to the real exponential function, so that `Filter.Tendsto.exp` can be used for the corresponding statement involving `NormedSpace.exp`. See [here](https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/exp.28tsum.29.20.3D.20tprod.28exp.29/near/436891747) on Zulip. Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
This adds lemmas saying that
HasSum f a
impliesHasProd (exp ∘ f) (exp a)
forexp = rexp, cexp, NormedSpace.exp
.While the
rexp
andcexp
versions could be deduced from theNormedSpace.exp
one, we give a direct proof (and so avoid needing to import stuff aboutNormedSpace.exp
for these results; the proofs are also a bit faster that way).Based on the discussion below, this also renames
Filter.Tendsto.exp
toFilter.Tendsto.rexp
for the version specific to the real exponential function, so thatFilter.Tendsto.exp
can be used for the corresponding statement involvingNormedSpace.exp
.See here on Zulip.