File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ variables {α : Type u} [linear_order α]
1717
1818lemma min_def (a b : α) : min a b = if a ≤ b then a else b :=
1919by rw [congr_fun linear_order.min_def a, min_default]
20- lemma max_def (a b : α) : max a b = if b ≤ a then a else b :=
20+ lemma max_def (a b : α) : max a b = if a ≤ b then b else a :=
2121by rw [congr_fun linear_order.max_def a, max_default]
2222
2323private meta def min_tac_step : tactic unit :=
@@ -40,13 +40,13 @@ lemma le_min {a b c : α} (h₁ : c ≤ a) (h₂ : c ≤ b) : c ≤ min a b :=
4040by min_tac a b
4141
4242lemma le_max_left (a b : α) : a ≤ max a b :=
43- by min_tac b a
43+ by min_tac a b
4444
4545lemma le_max_right (a b : α) : b ≤ max a b :=
46- by min_tac b a
46+ by min_tac a b
4747
4848lemma max_le {a b c : α} (h₁ : a ≤ c) (h₂ : b ≤ c) : max a b ≤ c :=
49- by min_tac b a
49+ by min_tac a b
5050
5151lemma eq_min {a b c : α} (h₁ : c ≤ a) (h₂ : c ≤ b) (h₃ : ∀{d}, d ≤ a → d ≤ b → d ≤ c) :
5252 c = min a b :=
@@ -131,5 +131,5 @@ or.elim (le_or_gt b c)
131131lemma max_lt {a b c : α} (h₁ : a < c) (h₂ : b < c) : max a b < c :=
132132or.elim (le_or_gt a b)
133133 (assume h : a ≤ b, by min_tac b a)
134- (assume h : a > b, by min_tac b a )
134+ (assume h : a > b, by min_tac a b )
135135end
Original file line number Diff line number Diff line change @@ -189,7 +189,7 @@ section linear_order
189189
190190/-- Default definition of `max`. -/
191191def max_default {α : Type u} [has_le α] [decidable_rel ((≤) : α → α → Prop )] (a b : α) :=
192- if b ≤ a then a else b
192+ if a ≤ b then b else a
193193
194194/-- Default definition of `min`. -/
195195def min_default {α : Type u} [has_le α] [decidable_rel ((≤) : α → α → Prop )] (a b : α) :=
You can’t perform that action at this time.
0 commit comments