src/HOL/Hahn_Banach/Zorn_Lemma.thy
author wenzelm
Mon Nov 02 11:10:28 2015 +0100 (2015-11-02)
changeset 61539 a29295dac1ca
parent 58889 5b7a9633cfa8
child 61879 e4f9d8f094fe
permissions -rw-r--r--
isabelle update_cartouches -t;
wenzelm@31795
     1
(*  Title:      HOL/Hahn_Banach/Zorn_Lemma.thy
wenzelm@7917
     2
    Author:     Gertrud Bauer, TU Munich
wenzelm@7917
     3
*)
wenzelm@7917
     4
wenzelm@58889
     5
section \<open>Zorn's Lemma\<close>
wenzelm@7917
     6
wenzelm@31795
     7
theory Zorn_Lemma
blanchet@55018
     8
imports Main
wenzelm@27612
     9
begin
wenzelm@7917
    10
wenzelm@58744
    11
text \<open>
wenzelm@10687
    12
  Zorn's Lemmas states: if every linear ordered subset of an ordered
wenzelm@61539
    13
  set \<open>S\<close> has an upper bound in \<open>S\<close>, then there exists a
wenzelm@61539
    14
  maximal element in \<open>S\<close>.  In our application, \<open>S\<close> is a
wenzelm@10687
    15
  set of sets ordered by set inclusion. Since the union of a chain of
wenzelm@10687
    16
  sets is an upper bound for all elements of the chain, the conditions
wenzelm@61539
    17
  of Zorn's lemma can be modified: if \<open>S\<close> is non-empty, it
wenzelm@61539
    18
  suffices to show that for every non-empty chain \<open>c\<close> in \<open>S\<close> the union of \<open>c\<close> also lies in \<open>S\<close>.
wenzelm@58744
    19
\<close>
wenzelm@7917
    20
wenzelm@10687
    21
theorem Zorn's_Lemma:
popescua@52183
    22
  assumes r: "\<And>c. c \<in> chains S \<Longrightarrow> \<exists>x. x \<in> c \<Longrightarrow> \<Union>c \<in> S"
wenzelm@13515
    23
    and aS: "a \<in> S"
popescua@52183
    24
  shows "\<exists>y \<in> S. \<forall>z \<in> S. y \<subseteq> z \<longrightarrow> z = y"
wenzelm@9035
    25
proof (rule Zorn_Lemma2)
popescua@52183
    26
  show "\<forall>c \<in> chains S. \<exists>y \<in> S. \<forall>z \<in> c. z \<subseteq> y"
wenzelm@9035
    27
  proof
popescua@52183
    28
    fix c assume "c \<in> chains S"
wenzelm@10687
    29
    show "\<exists>y \<in> S. \<forall>z \<in> c. z \<subseteq> y"
wenzelm@9035
    30
    proof cases
wenzelm@13515
    31
wenzelm@61539
    32
      txt \<open>If \<open>c\<close> is an empty chain, then every element in
wenzelm@61539
    33
        \<open>S\<close> is an upper bound of \<open>c\<close>.\<close>
wenzelm@7917
    34
wenzelm@13515
    35
      assume "c = {}"
wenzelm@9035
    36
      with aS show ?thesis by fast
wenzelm@7917
    37
wenzelm@61539
    38
      txt \<open>If \<open>c\<close> is non-empty, then \<open>\<Union>c\<close> is an upper
wenzelm@61539
    39
        bound of \<open>c\<close>, lying in \<open>S\<close>.\<close>
wenzelm@7917
    40
wenzelm@9035
    41
    next
wenzelm@27612
    42
      assume "c \<noteq> {}"
wenzelm@13515
    43
      show ?thesis
wenzelm@13515
    44
      proof
wenzelm@10687
    45
        show "\<forall>z \<in> c. z \<subseteq> \<Union>c" by fast
wenzelm@13515
    46
        show "\<Union>c \<in> S"
wenzelm@9035
    47
        proof (rule r)
wenzelm@58744
    48
          from \<open>c \<noteq> {}\<close> show "\<exists>x. x \<in> c" by fast
popescua@52183
    49
          show "c \<in> chains S" by fact
wenzelm@9035
    50
        qed
wenzelm@9035
    51
      qed
wenzelm@9035
    52
    qed
wenzelm@9035
    53
  qed
wenzelm@9035
    54
qed
wenzelm@7917
    55
wenzelm@10687
    56
end