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] - fix: make polyrith succeed when target is identically zero #13150

Closed
wants to merge 2 commits into from

Conversation

robertylewis
Copy link
Member

The polyrith feature that checks for membership in the radical of the ideal fails if the target is 0. (That is, polyrith cannot prove x - x = 0.) This PR fixes this by checking (in Sage) whether the target is 0, and short circuiting if it is.

This example succeeded before #7790, fails after, and now succeeds again.

import Mathlib.Tactic.Polyrith

variable {R : Type*} [CommRing R]

example {x : R} (H : x = 1) : x = x := by polyrith 

This PR also renames a misleadingly named variable in the polyrith Python script.


Open in Gitpod

@robertylewis robertylewis added awaiting-review t-meta Tactics, attributes or user commands labels May 24, 2024
@kim-em
Copy link
Contributor

kim-em commented May 24, 2024

bors merge

@github-actions github-actions bot added ready-to-merge This PR has been sent to bors. and removed awaiting-review labels May 24, 2024
mathlib-bors bot pushed a commit that referenced this pull request May 24, 2024
The `polyrith` feature that checks for membership in the radical of the ideal fails if the target is 0. (That is, `polyrith` cannot prove `x - x = 0`.) This PR fixes this by checking (in Sage) whether the target is 0, and short circuiting if it is.

This example succeeded before #7790, fails after, and now succeeds again.

```lean
import Mathlib.Tactic.Polyrith

variable {R : Type*} [CommRing R]

example {x : R} (H : x = 1) : x = x := by polyrith 
```

This PR also renames a misleadingly named variable in the `polyrith` Python script.



Co-authored-by: Rob Lewis <[email protected]>
@mathlib-bors
Copy link
Contributor

mathlib-bors bot commented May 24, 2024

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title fix: make polyrith succeed when target is identically zero [Merged by Bors] - fix: make polyrith succeed when target is identically zero May 24, 2024
@mathlib-bors mathlib-bors bot closed this May 24, 2024
@mathlib-bors mathlib-bors bot deleted the robertylewis/polyrith-0target branch May 24, 2024 04:54
grunweg pushed a commit that referenced this pull request May 24, 2024
The `polyrith` feature that checks for membership in the radical of the ideal fails if the target is 0. (That is, `polyrith` cannot prove `x - x = 0`.) This PR fixes this by checking (in Sage) whether the target is 0, and short circuiting if it is.

This example succeeded before #7790, fails after, and now succeeds again.

```lean
import Mathlib.Tactic.Polyrith

variable {R : Type*} [CommRing R]

example {x : R} (H : x = 1) : x = x := by polyrith 
```

This PR also renames a misleadingly named variable in the `polyrith` Python script.



Co-authored-by: Rob Lewis <[email protected]>
callesonne pushed a commit that referenced this pull request Jun 4, 2024
The `polyrith` feature that checks for membership in the radical of the ideal fails if the target is 0. (That is, `polyrith` cannot prove `x - x = 0`.) This PR fixes this by checking (in Sage) whether the target is 0, and short circuiting if it is.

This example succeeded before #7790, fails after, and now succeeds again.

```lean
import Mathlib.Tactic.Polyrith

variable {R : Type*} [CommRing R]

example {x : R} (H : x = 1) : x = x := by polyrith 
```

This PR also renames a misleadingly named variable in the `polyrith` Python script.



Co-authored-by: Rob Lewis <[email protected]>
js2357 pushed a commit that referenced this pull request Jun 18, 2024
The `polyrith` feature that checks for membership in the radical of the ideal fails if the target is 0. (That is, `polyrith` cannot prove `x - x = 0`.) This PR fixes this by checking (in Sage) whether the target is 0, and short circuiting if it is.

This example succeeded before #7790, fails after, and now succeeds again.

```lean
import Mathlib.Tactic.Polyrith

variable {R : Type*} [CommRing R]

example {x : R} (H : x = 1) : x = x := by polyrith 
```

This PR also renames a misleadingly named variable in the `polyrith` Python script.



Co-authored-by: Rob Lewis <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge This PR has been sent to bors. t-meta Tactics, attributes or user commands
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants