mathlib4
mathlib4 copied to clipboard
refactor(Algebra/Polynomial/Laurent): use Int.ofNat.inj
Not sure if we want to have a special name for a theorem of type
Function.Injective Int.ofNat
which is just Int.ofNat.inj with explicit arguments. If yes, what would be a good name and place for it?
Perhaps this is a use case for using alias?
Actually, I do think we should have the Injective lemma as well
Actually, I do think we should have the Injective lemma as well
What would be a good name and place for it?
Int.ofNat_injective, and near Int.natCast_inj in Data.Int.Defs, perhaps
Int.ofNat_injective, and nearInt.natCast_injinData.Int.Defs, perhaps
done
I'm going to test if Nat.cast_injective works better in these rws.
UPD: In 1 case it doesn't help (why do we need erw there?) ; in other case, expr uses Nat.cast, so I rewrote it in terms of Nat.cast_injective.
Thanks! Once CI is happy, please merge this PR using bors r+
bors d+
:v: mo271 can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.
bors r+
Pull request successfully merged into master.
Build succeeded: