Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/Lean/Mathlib/Mathlib/Data/Set/Lattice/     Datei vom 15.10.2026 mit Größe 25 kB image not shown  

Quelle  Powerset.lean   Sprache: Lean

 

/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Mario Carneiro, Kyle Miller
-/

module

public import Mathlib.Data.Finset.Powerset

import Mathlib.Data.Set.Finite.Basic

/-!
# Finiteness of the powerset of a finite set

## Implementation notes

Each result in this file should come in three forms: a `Fintype` instance, a `Finite` instance
and a `Set.Finite` constructor.

## Tags

finite sets
-/


public section

assert_not_exists IsOrderedRing MonoidWithZero

open Set Function

universe u v w x

variable {α : Type u}

namespace Set

/-! ### Constructors for `Set.Finite`

Every constructor here should have a corresponding `Fintype` instance in the `Fintype` module.

The implementation of these constructors ideally should be no more than `Set.toFinite`,
after possibly setting up some `Fintype` and classical `Decidable` instances.
-/



section SetFiniteConstructors

/-- There are finitely many subsets of a given finite set -/
theorem Finite.finite_subsets {α : Type u} {a : Set α} (h : a.Finite) : { b | b ⊆ a }.Finite := by
  refine ((Finset.powerset h.toFinset).map Finset.coeEmb.1).finite_toSet.subset fun s hs => ?_
  simp only [Finset.coe_map, Set.mem_image, Finset.mem_coe, Finset.mem_powerset, Finset.coeEmb]
  exact ⟨(h.subset hs).toFinset, by simp [show s ⊆ a from hs], by simp⟩

protected theorem Finite.powerset {s : Set α} (h : s.Finite) : (�� s).Finite :=
  h.finite_subsets

end SetFiniteConstructors

end Set

Messung
CHZG
9210010097

¤ Dauer der Verarbeitung: 0.62 Sekunden  ¤

*© Formatika GbR, Deutschland