Skip to content
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(analysis/*): a sample of easy useful lemmas #13697

Closed
wants to merge 4 commits into from

Conversation

sgouezel
Copy link
Collaborator

Lemmas needed for #13690


Open in Gitpod

@sgouezel sgouezel added the awaiting-review The author would like community review of the PR label Apr 25, 2022
src/analysis/specific_limits/basic.lean Outdated Show resolved Hide resolved
@@ -105,6 +105,9 @@ by simpa using cpow_neg x 1
complex.zero_cpow (nat.cast_ne_zero.2 (nat.succ_ne_zero _)), zero_mul]
else by simp [cpow_add, hx, pow_add, cpow_nat_cast n]

@[simp] lemma cpow_two (x : ℂ) : x ^ (2 : ℂ) = x ^ 2 :=
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should these be tagged norm_cast?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no cast here (the 2 on the left is not the coercion from nat to complex, it is just the complex 2), so norm_cast does not work. On the other hand, there was a missing norm_cast attribute on nearby lemmas!

@@ -1020,6 +1020,14 @@ begin
exact (tendsto_at_top_of_eventually_const this).cauchy_seq.add hv
end

lemma normed_group.tendsto_sub_nhds_zero_iff
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this be closer to squeeze_zero_norm and other filter-norm lemmas?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, because the proof uses the topological group instance which is proved just a few lines above.

Copy link
Collaborator

@b-mehta b-mehta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM other than the existing comments

Copy link
Collaborator

@ocfnash ocfnash left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should generalise tendsto_sub_nhds_zero_iff but otherwise this LGTM.

bors d+

@@ -1020,6 +1020,14 @@ begin
exact (tendsto_at_top_of_eventually_const this).cauchy_seq.add hv
end

lemma tendsto_sub_nhds_zero_iff
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we prove this for any topological group (multiplicative or additive) rather than just normed?

@bors
Copy link

bors bot commented Apr 28, 2022

✌️ sgouezel can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@leanprover-community-bot-assistant leanprover-community-bot-assistant added delegated The PR author may merge after reviewing final suggestions. and removed awaiting-review The author would like community review of the PR labels Apr 28, 2022
@sgouezel
Copy link
Collaborator Author

bors r+

@github-actions github-actions bot added the ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) label Apr 29, 2022
bors bot pushed a commit that referenced this pull request Apr 29, 2022
@bors
Copy link

bors bot commented Apr 29, 2022

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(analysis/*): a sample of easy useful lemmas [Merged by Bors] - feat(analysis/*): a sample of easy useful lemmas Apr 29, 2022
@bors bors bot closed this Apr 29, 2022
@bors bors bot deleted the gouezel_analysis branch April 29, 2022 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
delegated The PR author may merge after reviewing final suggestions. ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants