Skip to content

Commit

Permalink
feat(data/fintype/basic): one_lt_card_iff and two_lt_card_iff (#1…
Browse files Browse the repository at this point in the history
…1524)

This PR adds `one_lt_card_iff` and `two_lt_card_iff`.
  • Loading branch information
tb65536 committed Jan 18, 2022
1 parent e895c8f commit 01fa7f5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/data/fintype/basic.lean
Expand Up @@ -1023,6 +1023,12 @@ fintype.card_eq_one_iff.2 ⟨i,h⟩
lemma one_lt_card [h : nontrivial α] : 1 < fintype.card α :=
fintype.one_lt_card_iff_nontrivial.mpr h

lemma one_lt_card_iff : 1 < card α ↔ ∃ a b : α, a ≠ b :=
one_lt_card_iff_nontrivial.trans nontrivial_iff

lemma two_lt_card_iff : 2 < card α ↔ ∃ a b c : α, a ≠ b ∧ a ≠ c ∧ b ≠ c :=
by simp_rw [←finset.card_univ, two_lt_card_iff, mem_univ, true_and]

lemma injective_iff_surjective {f : α → α} : injective f ↔ surjective f :=
by haveI := classical.prop_decidable; exact
have ∀ {f : α → α}, injective f → surjective f,
Expand Down

0 comments on commit 01fa7f5

Please sign in to comment.