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

let linear_combination subsume ring #11990

Closed
hrmacbeth opened this issue Feb 12, 2022 · 0 comments
Closed

let linear_combination subsume ring #11990

hrmacbeth opened this issue Feb 12, 2022 · 0 comments
Labels
feature-request This issue is a feature request, either for mathematics, tactics, or CI modifies-tactic-syntax This PR adds a new interactive tactic or modifies the syntax of an existing tactic. t-meta Tactics, attributes or user commands

Comments

@hrmacbeth
Copy link
Member

hrmacbeth commented Feb 12, 2022

It seems like it would be perfectly coherent to let linear_combination with no arguments be an alias for ring -- in fact, this is arguably the correct behaviour for that input, rather than (as currently) failing.

See https://leanprover.zulipchat.com/#narrow/stream/239415-metaprogramming-.2F.20tactics/topic/trivial.20case.20of.20linear_combination for discussion. @robertylewis says

it almost works to interpret it as the trivial combination of hypotheses proving 0 = 0. But, which 0 is that? The tactic builds the sum of hypotheses without looking at the target type .... Proper fix, I think, is to get the expected type at the beginning and check that the hypotheses match

@hrmacbeth hrmacbeth added t-meta Tactics, attributes or user commands modifies-tactic-syntax This PR adds a new interactive tactic or modifies the syntax of an existing tactic. feature-request This issue is a feature request, either for mathematics, tactics, or CI labels Feb 12, 2022
robertylewis added a commit that referenced this issue Feb 15, 2022
…e case

This threads the expected type of the combination from the target throughout the tactic call.
If no hypotheses are given to combine, the behavior is effectively to just call the normalization tactic.

closes #11990
bors bot pushed a commit that referenced this issue Feb 21, 2022
…e case (#12062)

This threads the expected type of the combination from the target throughout the tactic call.
If no hypotheses are given to combine, the behavior is effectively to just call the normalization tactic.

closes #11990





Co-authored-by: Rob Lewis <rob.y.lewis@gmail.com>
bors bot pushed a commit that referenced this issue Feb 21, 2022
…e case (#12062)

This threads the expected type of the combination from the target throughout the tactic call.
If no hypotheses are given to combine, the behavior is effectively to just call the normalization tactic.

closes #11990





Co-authored-by: Rob Lewis <rob.y.lewis@gmail.com>
@bors bors bot closed this as completed in 8aa26b2 Feb 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request This issue is a feature request, either for mathematics, tactics, or CI modifies-tactic-syntax This PR adds a new interactive tactic or modifies the syntax of an existing tactic. t-meta Tactics, attributes or user commands
Projects
None yet
1 participant