Skip to content

Commit

Permalink
chore(order/well_founded_set): golf two proofs (#12529)
Browse files Browse the repository at this point in the history
  • Loading branch information
eric-wieser committed Mar 8, 2022
1 parent 709a3b7 commit d69cda1
Showing 1 changed file with 2 additions and 22 deletions.
24 changes: 2 additions & 22 deletions src/order/well_founded_set.lean
Expand Up @@ -474,32 +474,12 @@ end set
@[simp]
theorem finset.is_wf_sup {ι : Type*} [partial_order α] (f : finset ι) (g : ι → set α)
(hf : ∀ i : ι, i ∈ f → (g i).is_wf) : (f.sup g).is_wf :=
begin
classical,
revert hf,
apply f.induction_on,
{ intro h,
simp [set.is_pwo_empty.is_wf], },
{ intros s f sf hf hsf,
rw finset.sup_insert,
exact (hsf s (finset.mem_insert_self _ _)).union (hf (λ s' s'f, hsf _
(finset.mem_insert_of_mem s'f))) }
end
finset.sup_induction set.is_pwo_empty.is_wf (λ a ha b hb, ha.union hb) hf

@[simp]
theorem finset.is_pwo_sup {ι : Type*} [partial_order α] (f : finset ι) (g : ι → set α)
(hf : ∀ i : ι, i ∈ f → (g i).is_pwo) : (f.sup g).is_pwo :=
begin
classical,
revert hf,
apply f.induction_on,
{ intro h,
simp [set.is_pwo_empty.is_wf], },
{ intros s f sf hf hsf,
rw finset.sup_insert,
exact (hsf s (finset.mem_insert_self _ _)).union (hf (λ s' s'f, hsf _
(finset.mem_insert_of_mem s'f))) }
end
finset.sup_induction set.is_pwo_empty (λ a ha b hb, ha.union hb) hf

namespace set
variables [linear_order α] {s t : set α} {a : α}
Expand Down

0 comments on commit d69cda1

Please sign in to comment.