Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

[Merged by Bors] - chore(*): speed up slow proofs #7253

Closed
wants to merge 3 commits into from
Closed

Conversation

sgouezel
Copy link
Collaborator

Proofs that are too slow for the forthcoming gsmul refactor. I learnt that by convert ... is extremely useful even to close a goal, when elaboration using the expected type is a bad idea.

@sgouezel sgouezel added the awaiting-review The author would like community review of the PR label Apr 18, 2021
Copy link
Collaborator

@semorrison semorrison left a comment

Choose a reason for hiding this comment

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

LGTM to me. Thanks so much for resolving these slow proofs!

add_comm := by {intros, ext, unfold coe_fn has_coe_to_fun.coe sesq, rw add_comm} }
sesq_smul_right := λ a x y, by rw [sesq_smul_right, mul_neg_eq_neg_mul_symm] }⟩

instance : add_comm_group (sesq_form R M I) :=
Copy link
Member

Choose a reason for hiding this comment

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

Shouldn't this get a dedicated nsmul field now?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

They get one for free, which is the naive one defined by induction. One should only add one by hand if there is a risk of diamond, i.e., if we ever consider sesquilinear forms over naturals or integers. Sesquilinear forms over naturals don't make sense, so there is no issue here. There is an issue over the integers, so we should probably add a gsmul field, yes. I'll do it in #7255.

@jcommelin
Copy link
Member

Thanks 🎉

bors merge

@github-actions github-actions bot added ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) and removed awaiting-review The author would like community review of the PR labels Apr 19, 2021
bors bot pushed a commit that referenced this pull request Apr 19, 2021
Proofs that are too slow for the forthcoming `gsmul` refactor. I learnt that `by convert ...` is extremely useful even to close a goal, when elaboration using the expected type is a bad idea.
@bors
Copy link

bors bot commented Apr 19, 2021

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title chore(*): speed up slow proofs [Merged by Bors] - chore(*): speed up slow proofs Apr 19, 2021
@bors bors bot closed this Apr 19, 2021
@bors bors bot deleted the speedup2 branch April 19, 2021 17:06
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
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.

5 participants