Skip to content

Commit

Permalink
feat(algebra/order/ring): add three_ne_zero and four_ne_zero (#12142)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ruben-VandeVelde committed Feb 20, 2022
1 parent 6c6e142 commit 334fb89
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/algebra/order/ring.lean
Expand Up @@ -127,7 +127,7 @@ lt_of_le_of_ne zero_le_one zero_ne_one
lemma zero_lt_two : 0 < (2:α) := add_pos zero_lt_one zero_lt_one

@[field_simps] lemma two_ne_zero : (2:α) ≠ 0 :=
ne.symm (ne_of_lt zero_lt_two)
zero_lt_two.ne'

lemma one_lt_two : 1 < (2:α) :=
calc (2:α) = 1+1 : one_add_one_eq_two
Expand All @@ -136,8 +136,14 @@ calc (2:α) = 1+1 : one_add_one_eq_two

lemma zero_lt_three : 0 < (3:α) := add_pos zero_lt_two zero_lt_one

@[field_simps] lemma three_ne_zero : (3:α) ≠ 0 :=
zero_lt_three.ne'

lemma zero_lt_four : 0 < (4:α) := add_pos zero_lt_two zero_lt_two

@[field_simps] lemma four_ne_zero : (4:α) ≠ 0 :=
zero_lt_four.ne'

alias zero_lt_one ← one_pos
alias zero_lt_two ← two_pos
alias zero_lt_three ← three_pos
Expand Down

0 comments on commit 334fb89

Please sign in to comment.