src/HOL/Hahn_Banach/Function_Order.thy
author wenzelm
Sun, 20 Dec 2015 13:56:02 +0100
changeset 61879 e4f9d8f094fe
parent 61540 f92bf6674699
permissions -rw-r--r--
tuned whitespace;
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
31795
be3e1cc5005c standard naming conventions for session and theories;
wenzelm
parents: 29197
diff changeset
     1
(*  Title:      HOL/Hahn_Banach/Function_Order.thy
7566
c5a3f980a7af accomodate refined facts handling;
wenzelm
parents: 7535
diff changeset
     2
    Author:     Gertrud Bauer, TU Munich
c5a3f980a7af accomodate refined facts handling;
wenzelm
parents: 7535
diff changeset
     3
*)
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
     4
58889
5b7a9633cfa8 modernized header uniformly as section;
wenzelm
parents: 58745
diff changeset
     5
section \<open>An order on functions\<close>
7808
fd019ac3485f update from Gertrud;
wenzelm
parents: 7656
diff changeset
     6
31795
be3e1cc5005c standard naming conventions for session and theories;
wenzelm
parents: 29197
diff changeset
     7
theory Function_Order
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
     8
imports Subspace Linearform
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
     9
begin
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    10
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    11
subsection \<open>The graph of a function\<close>
7808
fd019ac3485f update from Gertrud;
wenzelm
parents: 7656
diff changeset
    12
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    13
text \<open>
61879
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    14
  We define the \<^emph>\<open>graph\<close> of a (real) function \<open>f\<close> with domain \<open>F\<close> as the set
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
    15
  \begin{center}
61539
a29295dac1ca isabelle update_cartouches -t;
wenzelm
parents: 61486
diff changeset
    16
  \<open>{(x, f x). x \<in> F}\<close>
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
    17
  \end{center}
61879
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    18
  So we are modeling partial functions by specifying the domain and the
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    19
  mapping function. We use the term ``function'' also for its graph.
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    20
\<close>
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    21
41818
6d4c3ee8219d modernized specifications;
wenzelm
parents: 31795
diff changeset
    22
type_synonym 'a graph = "('a \<times> real) set"
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    23
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    24
definition graph :: "'a set \<Rightarrow> ('a \<Rightarrow> real) \<Rightarrow> 'a graph"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    25
  where "graph F f = {(x, f x) | x. x \<in> F}"
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    26
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    27
lemma graphI [intro]: "x \<in> F \<Longrightarrow> (x, f x) \<in> graph F f"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    28
  unfolding graph_def by blast
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    29
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    30
lemma graphI2 [intro?]: "x \<in> F \<Longrightarrow> \<exists>t \<in> graph F f. t = (x, f x)"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    31
  unfolding graph_def by blast
7566
c5a3f980a7af accomodate refined facts handling;
wenzelm
parents: 7535
diff changeset
    32
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    33
lemma graphE [elim?]:
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    34
  assumes "(x, y) \<in> graph F f"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    35
  obtains "x \<in> F" and "y = f x"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    36
  using assms unfolding graph_def by blast
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
    37
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    38
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    39
subsection \<open>Functions ordered by domain extension\<close>
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    40
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    41
text \<open>
61879
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    42
  A function \<open>h'\<close> is an extension of \<open>h\<close>, iff the graph of \<open>h\<close> is a subset of
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    43
  the graph of \<open>h'\<close>.
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    44
\<close>
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    45
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
    46
lemma graph_extI:
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
    47
  "(\<And>x. x \<in> H \<Longrightarrow> h x = h' x) \<Longrightarrow> H \<subseteq> H'
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    48
    \<Longrightarrow> graph H h \<subseteq> graph H' h'"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    49
  unfolding graph_def by blast
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    50
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    51
lemma graph_extD1 [dest?]: "graph H h \<subseteq> graph H' h' \<Longrightarrow> x \<in> H \<Longrightarrow> h x = h' x"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    52
  unfolding graph_def by blast
7566
c5a3f980a7af accomodate refined facts handling;
wenzelm
parents: 7535
diff changeset
    53
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    54
lemma graph_extD2 [dest?]: "graph H h \<subseteq> graph H' h' \<Longrightarrow> H \<subseteq> H'"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    55
  unfolding graph_def by blast
7566
c5a3f980a7af accomodate refined facts handling;
wenzelm
parents: 7535
diff changeset
    56
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    57
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    58
subsection \<open>Domain and function of a graph\<close>
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    59
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    60
text \<open>
61539
a29295dac1ca isabelle update_cartouches -t;
wenzelm
parents: 61486
diff changeset
    61
  The inverse functions to \<open>graph\<close> are \<open>domain\<close> and \<open>funct\<close>.
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    62
\<close>
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    63
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    64
definition domain :: "'a graph \<Rightarrow> 'a set"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    65
  where "domain g = {x. \<exists>y. (x, y) \<in> g}"
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    66
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    67
definition funct :: "'a graph \<Rightarrow> ('a \<Rightarrow> real)"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
    68
  where "funct g = (\<lambda>x. (SOME y. (x, y) \<in> g))"
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    69
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    70
text \<open>
61540
f92bf6674699 tuned document;
wenzelm
parents: 61539
diff changeset
    71
  The following lemma states that \<open>g\<close> is the graph of a function if the
f92bf6674699 tuned document;
wenzelm
parents: 61539
diff changeset
    72
  relation induced by \<open>g\<close> is unique.
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    73
\<close>
7566
c5a3f980a7af accomodate refined facts handling;
wenzelm
parents: 7535
diff changeset
    74
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
    75
lemma graph_domain_funct:
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    76
  assumes uniq: "\<And>x y z. (x, y) \<in> g \<Longrightarrow> (x, z) \<in> g \<Longrightarrow> z = y"
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    77
  shows "graph (domain g) (funct g) = g"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    78
  unfolding domain_def funct_def graph_def
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
    79
proof auto  (* FIXME !? *)
23378
1d138d6bb461 tuned proofs: avoid implicit prems;
wenzelm
parents: 21404
diff changeset
    80
  fix a b assume g: "(a, b) \<in> g"
1d138d6bb461 tuned proofs: avoid implicit prems;
wenzelm
parents: 21404
diff changeset
    81
  from g show "(a, SOME y. (a, y) \<in> g) \<in> g" by (rule someI2)
1d138d6bb461 tuned proofs: avoid implicit prems;
wenzelm
parents: 21404
diff changeset
    82
  from g show "\<exists>y. (a, y) \<in> g" ..
1d138d6bb461 tuned proofs: avoid implicit prems;
wenzelm
parents: 21404
diff changeset
    83
  from g show "b = (SOME y. (a, y) \<in> g)"
9969
4753185f1dd2 renamed (most of...) the select rules
paulson
parents: 9623
diff changeset
    84
  proof (rule some_equality [symmetric])
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
    85
    fix y assume "(a, y) \<in> g"
23378
1d138d6bb461 tuned proofs: avoid implicit prems;
wenzelm
parents: 21404
diff changeset
    86
    with g show "y = b" by (rule uniq)
9035
371f023d3dbd removed explicit terminator (";");
wenzelm
parents: 8203
diff changeset
    87
  qed
371f023d3dbd removed explicit terminator (";");
wenzelm
parents: 8203
diff changeset
    88
qed
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
    89
7808
fd019ac3485f update from Gertrud;
wenzelm
parents: 7656
diff changeset
    90
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    91
subsection \<open>Norm-preserving extensions of a function\<close>
7917
5e5b9813cce7 HahnBanach update by Gertrud Bauer;
wenzelm
parents: 7808
diff changeset
    92
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    93
text \<open>
61879
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    94
  Given a linear form \<open>f\<close> on the space \<open>F\<close> and a seminorm \<open>p\<close> on \<open>E\<close>. The set
e4f9d8f094fe tuned whitespace;
wenzelm
parents: 61540
diff changeset
    95
  of all linear extensions of \<open>f\<close>, to superspaces \<open>H\<close> of \<open>F\<close>, which are
61540
f92bf6674699 tuned document;
wenzelm
parents: 61539
diff changeset
    96
  bounded by \<open>p\<close>, is defined as follows.
58744
c434e37f290e update_cartouches;
wenzelm
parents: 44887
diff changeset
    97
\<close>
7808
fd019ac3485f update from Gertrud;
wenzelm
parents: 7656
diff changeset
    98
19736
wenzelm
parents: 16417
diff changeset
    99
definition
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
   100
  norm_pres_extensions ::
58745
wenzelm
parents: 58744
diff changeset
   101
    "'a::{plus,minus,uminus,zero} set \<Rightarrow> ('a \<Rightarrow> real) \<Rightarrow> 'a set \<Rightarrow> ('a \<Rightarrow> real)
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   102
      \<Rightarrow> 'a graph set"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   103
where
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   104
  "norm_pres_extensions E p F f
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   105
    = {g. \<exists>H h. g = graph H h
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   106
        \<and> linearform H h
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   107
        \<and> H \<unlhd> E
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   108
        \<and> F \<unlhd> H
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   109
        \<and> graph F f \<subseteq> graph H h
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   110
        \<and> (\<forall>x \<in> H. h x \<le> p x)}"
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
   111
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   112
lemma norm_pres_extensionE [elim]:
44887
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   113
  assumes "g \<in> norm_pres_extensions E p F f"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   114
  obtains H h
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   115
    where "g = graph H h"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   116
    and "linearform H h"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   117
    and "H \<unlhd> E"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   118
    and "F \<unlhd> H"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   119
    and "graph F f \<subseteq> graph H h"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   120
    and "\<forall>x \<in> H. h x \<le> p x"
7ca82df6e951 misc tuning and clarification;
wenzelm
parents: 41818
diff changeset
   121
  using assms unfolding norm_pres_extensions_def by blast
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
   122
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
   123
lemma norm_pres_extensionI2 [intro]:
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   124
  "linearform H h \<Longrightarrow> H \<unlhd> E \<Longrightarrow> F \<unlhd> H
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   125
    \<Longrightarrow> graph F f \<subseteq> graph H h \<Longrightarrow> \<forall>x \<in> H. h x \<le> p x
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   126
    \<Longrightarrow> graph H h \<in> norm_pres_extensions E p F f"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
   127
  unfolding norm_pres_extensions_def by blast
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
   128
13515
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   129
lemma norm_pres_extensionI:  (* FIXME ? *)
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   130
  "\<exists>H h. g = graph H h
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   131
    \<and> linearform H h
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   132
    \<and> H \<unlhd> E
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   133
    \<and> F \<unlhd> H
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   134
    \<and> graph F f \<subseteq> graph H h
a6a7025fd7e8 updated to use locales (still some rough edges);
wenzelm
parents: 11472
diff changeset
   135
    \<and> (\<forall>x \<in> H. h x \<le> p x) \<Longrightarrow> g \<in> norm_pres_extensions E p F f"
27612
d3eb431db035 modernized specifications and proofs;
wenzelm
parents: 25762
diff changeset
   136
  unfolding norm_pres_extensions_def by blast
7535
599d3414b51d The Hahn-Banach theorem for real vectorspaces (Isabelle/Isar)
wenzelm
parents:
diff changeset
   137
10687
c186279eecea tuned HOL/Real/HahnBanach;
wenzelm
parents: 9969
diff changeset
   138
end