-
Notifications
You must be signed in to change notification settings - Fork 346
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] - chore(Topology/PartitionOfUnity): shorten proof using ParitionOfUnity.le_one #19899
Conversation
PR summary 5a6c9a4629Import changes for modified filesNo significant changes to the import graph Import changes for all files
Declarations diffNo declarations were harmed in the making of this PR! 🐙 You can run this locally as follows## summary with just the declaration names:
./scripts/declarations_diff.sh <optional_commit>
## more verbose report:
./scripts/declarations_diff.sh long <optional_commit> The doc-module for No changes to technical debt.You can run this locally as
|
· exact fun j _ _ => f.nonneg j x | ||
simp only [Finset.singleton_subset_iff, Finset.mem_filter, Finset.mem_univ, true_and] | ||
exact h0 | ||
exact ⟨f.nonneg i x, PartitionOfUnity.le_one f i 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.
The type required for the second component here is (f i) x ≤ 1
, which is exactly what PartitionOfUnity.le_one
gives us. (No defeq shenanigans.)
Wow, this maintainer merge |
🚀 Pull request has been placed on the maintainer queue by tb65536. |
Thanks! 🎉 |
….le_one (#19899) Replaces 11 lines of proof with a single invocation of [`ParitionOfUnity.le_one`](https://github.com/leanprover-community/mathlib4/blob/4411562e4fd2d02aa31e413bc8e948829aa3a62d/Mathlib/Topology/PartitionOfUnity.lean#L171). I observed this (via `set_option trace.profiler true`) to lower the elaboration time of this theorem from 0.20 seconds to 0.08 seconds. This simplification was found by [`tryAtEachStep`](https://github.com/dwrensha/tryAtEachStep).
Pull request successfully merged into master. Build succeeded: |
Replaces 11 lines of proof with a single invocation of
ParitionOfUnity.le_one
.I observed this (via
set_option trace.profiler true
) to lower the elaboration time of this theorem from 0.20 seconds to 0.08 seconds.This simplification was found by
tryAtEachStep
.