mathlib4 icon indicating copy to clipboard operation
mathlib4 copied to clipboard

`ring` doesn't support negation

Open digama0 opened this issue 2 years ago • 1 comments

Currently the implementation of ring is incomplete and has no understanding of subtraction or negation:

import Mathlib.Tactic.Ring

example (a b : ℤ) : a - b = a + -b := by ring
-- ring failed, ring expressions not equal: 
-- (1) * (a - b)^1 + 0
--   !=
-- (1) * (a)^1 + (1) * (-b)^1 + 0

digama0 avatar Jul 20 '22 05:07 digama0

I suspect that this may be because of this line in the code. Right now, it seems conditional on the implementation of rational numbers in Mathlib.

0art0 avatar Aug 11 '22 16:08 0art0