# HG changeset patch # User wenzelm # Date 997212420 -7200 # Node ID d08d4e17a5f662246627517f9e891b48fc8d4585 # Parent ba2c252b55adce15b6643b5451147fa5a6fd2fc7 tuned; diff -r ba2c252b55ad -r d08d4e17a5f6 src/HOL/Real/HahnBanach/FunctionNorm.thy --- a/src/HOL/Real/HahnBanach/FunctionNorm.thy Tue Aug 07 19:29:08 2001 +0200 +++ b/src/HOL/Real/HahnBanach/FunctionNorm.thy Tue Aug 07 21:27:00 2001 +0200 @@ -10,10 +10,10 @@ subsection {* Continuous linear forms*} text {* - A linear form @{text f} on a normed vector space @{text "(V, \\\\\\)"} + A linear form @{text f} on a normed vector space @{text "(V, \\\)"} is \emph{continuous}, iff it is bounded, i.~e. \begin{center} - @{text "\\c \\ R. \\x \\ V. \\f x\\ \\ c \\ \\x\\"} + @{text "\c \ R. \x \ V. \f x\ \ c \ \x\"} \end{center} In our application no other functions than linear forms are considered, so we can define continuous linear forms as bounded @@ -22,61 +22,58 @@ constdefs is_continuous :: - "'a::{plus, minus, zero} set \\ ('a \\ real) \\ ('a \\ real) \\ bool" - "is_continuous V norm f \\ - is_linearform V f \\ (\\c. \\x \\ V. \\f x\\ \\ c * norm x)" + "'a::{plus, minus, zero} set \ ('a \ real) \ ('a \ real) \ bool" + "is_continuous V norm f \ + is_linearform V f \ (\c. \x \ V. \f x\ \ c * norm x)" lemma continuousI [intro]: - "is_linearform V f \\ (\\x. x \\ V \\ \\f x\\ \\ c * norm x) - \\ is_continuous V norm f" -proof (unfold is_continuous_def, intro exI conjI ballI) - assume r: "\\x. x \\ V \\ \\f x\\ \\ c * norm x" - fix x assume "x \\ V" show "\\f x\\ \\ c * norm x" by (rule r) -qed + "is_linearform V f \ (\x. x \ V \ \f x\ \ c * norm x) + \ is_continuous V norm f" + by (unfold is_continuous_def) blast lemma continuous_linearform [intro?]: - "is_continuous V norm f \\ is_linearform V f" + "is_continuous V norm f \ is_linearform V f" by (unfold is_continuous_def) blast lemma continuous_bounded [intro?]: "is_continuous V norm f - \\ \\c. \\x \\ V. \\f x\\ \\ c * norm x" + \ \c. \x \ V. \f x\ \ c * norm x" by (unfold is_continuous_def) blast + subsection{* The norm of a linear form *} - text {* The least real number @{text c} for which holds \begin{center} - @{text "\\x \\ V. \\f x\\ \\ c \\ \\x\\"} + @{text "\x \ V. \f x\ \ c \ \x\"} \end{center} is called the \emph{norm} of @{text f}. - For non-trivial vector spaces @{text "V \\ {0}"} the norm can be + For non-trivial vector spaces @{text "V \ {0}"} the norm can be defined as \begin{center} - @{text "\\f\\ = \x \\ 0. \\f x\\ / \\x\\"} + @{text "\f\ = \x \ 0. \f x\ / \x\"} \end{center} For the case @{text "V = {0}"} the supremum would be taken from an - empty set. Since @{text \\} is unbounded, there would be no supremum. + empty set. Since @{text \} is unbounded, there would be no supremum. To avoid this situation it must be guaranteed that there is an - element in this set. This element must be @{text "{} \\ 0"} so that + element in this set. This element must be @{text "{} \ 0"} so that @{text function_norm} has the norm properties. Furthermore it does not have to change the norm in all other cases, so it must - be @{text 0}, as all other elements of are @{text "{} \\ 0"}. + be @{text 0}, as all other elements of are @{text "{} \ 0"}. Thus we define the set @{text B} the supremum is taken from as \begin{center} - @{text "{0} \\ {\\f x\\ / \\x\\. x \\ 0 \\ x \\ F}"} + @{text "{0} \ {\f x\ / \x\. x \ 0 \ x \ F}"} \end{center} *} constdefs - B :: "'a set \\ ('a \\ real) \\ ('a::{plus, minus, zero} \\ real) \\ real set" - "B V norm f \\ - {#0} \\ {\\f x\\ * inverse (norm x) | x. x \\ 0 \\ x \\ V}" + B :: "'a set \ ('a \ real) \ ('a::{plus, minus, zero} \ real) \ real set" + "B V norm f \ + {#0} \ {\f x\ * inverse (norm x) | x. x \ 0 \ x \ V}" text {* @{text n} is the function norm of @{text f}, iff @{text n} is the @@ -85,8 +82,8 @@ constdefs is_function_norm :: - "('a::{minus,plus,zero} \\ real) \\ 'a set \\ ('a \\ real) \\ real \\ bool" - "is_function_norm f V norm fn \\ is_Sup UNIV (B V norm f) fn" + "('a::{minus,plus,zero} \ real) \ 'a set \ ('a \ real) \ real \ bool" + "is_function_norm f V norm fn \ is_Sup UNIV (B V norm f) fn" text {* @{text function_norm} is equal to the supremum of @{text B}, if the @@ -94,124 +91,124 @@ *} constdefs - function_norm :: "('a::{minus,plus,zero} \\ real) \\ 'a set \\ ('a \\ real) \\ real" - "function_norm f V norm \\ Sup UNIV (B V norm f)" + function_norm :: "('a::{minus,plus,zero} \ real) \ 'a set \ ('a \ real) \ real" + "function_norm f V norm \ Sup UNIV (B V norm f)" syntax - function_norm :: "('a \\ real) \\ 'a set \\ ('a \\ real) \\ real" ("\\_\\_,_") + function_norm :: "('a \ real) \ 'a set \ ('a \ real) \ real" ("\_\_,_") -lemma B_not_empty: "#0 \\ B V norm f" +lemma B_not_empty: "#0 \ B V norm f" by (unfold B_def) blast text {* The following lemma states that every continuous linear form on a - normed space @{text "(V, \\\\\\)"} has a function norm. + normed space @{text "(V, \\\)"} has a function norm. *} lemma ex_fnorm [intro?]: - "is_normed_vectorspace V norm \\ is_continuous V norm f - \\ is_function_norm f V norm \\f\\V,norm" + "is_normed_vectorspace V norm \ is_continuous V norm f + \ is_function_norm f V norm \f\V,norm" proof (unfold function_norm_def is_function_norm_def is_continuous_def Sup_def, elim conjE, rule someI2_ex) assume "is_normed_vectorspace V norm" assume "is_linearform V f" - and e: "\\c. \\x \\ V. \\f x\\ \\ c * norm x" + and e: "\c. \x \ V. \f x\ \ c * norm x" txt {* The existence of the supremum is shown using the completeness of the reals. Completeness means, that every non-empty bounded set of reals has a supremum. *} - show "\\a. is_Sup UNIV (B V norm f) a" + show "\a. is_Sup UNIV (B V norm f) a" proof (unfold is_Sup_def, rule reals_complete) txt {* First we have to show that @{text B} is non-empty: *} - show "\\X. X \\ B V norm f" + show "\X. X \ B V norm f" proof - show "#0 \\ (B V norm f)" by (unfold B_def) blast + show "#0 \ (B V norm f)" by (unfold B_def) blast qed txt {* Then we have to show that @{text B} is bounded: *} - from e show "\\Y. isUb UNIV (B V norm f) Y" + from e show "\Y. isUb UNIV (B V norm f) Y" proof txt {* We know that @{text f} is bounded by some value @{text c}. *} - fix c assume a: "\\x \\ V. \\f x\\ \\ c * norm x" - def b \\ "max c #0" + fix c assume a: "\x \ V. \f x\ \ c * norm x" + def b \ "max c #0" show "?thesis" proof (intro exI isUbI setleI ballI, unfold B_def, elim UnE CollectE exE conjE singletonE) txt {* To proof the thesis, we have to show that there is some - constant @{text b}, such that @{text "y \\ b"} for all - @{text "y \\ B"}. Due to the definition of @{text B} there are - two cases for @{text "y \\ B"}. If @{text "y = 0"} then - @{text "y \\ max c 0"}: *} + constant @{text b}, such that @{text "y \ b"} for all + @{text "y \ B"}. Due to the definition of @{text B} there are + two cases for @{text "y \ B"}. If @{text "y = 0"} then + @{text "y \ max c 0"}: *} fix y assume "y = (#0::real)" - show "y \\ b" by (simp! add: le_maxI2) + show "y \ b" by (simp! add: le_maxI2) - txt {* The second case is @{text "y = \\f x\\ / \\x\\"} for some - @{text "x \\ V"} with @{text "x \\ 0"}. *} + txt {* The second case is @{text "y = \f x\ / \x\"} for some + @{text "x \ V"} with @{text "x \ 0"}. *} next fix x y - assume "x \\ V" "x \\ 0" + assume "x \ V" "x \ 0" txt {* The thesis follows by a short calculation using the fact that @{text f} is bounded. *} - assume "y = \\f x\\ * inverse (norm x)" - also have "... \\ c * norm x * inverse (norm x)" + assume "y = \f x\ * inverse (norm x)" + also have "... \ c * norm x * inverse (norm x)" proof (rule real_mult_le_le_mono2) - show "#0 \\ inverse (norm x)" + show "#0 \ inverse (norm x)" by (rule order_less_imp_le, rule real_inverse_gt_zero1, rule normed_vs_norm_gt_zero) - from a show "\\f x\\ \\ c * norm x" .. + from a show "\f x\ \ c * norm x" .. qed also have "... = c * (norm x * inverse (norm x))" by (rule real_mult_assoc) also have "(norm x * inverse (norm x)) = (#1::real)" proof (rule real_mult_inv_right1) - show nz: "norm x \\ #0" + show nz: "norm x \ #0" by (rule not_sym, rule lt_imp_not_eq, rule normed_vs_norm_gt_zero) qed - also have "c * ... \\ b " by (simp! add: le_maxI1) - finally show "y \\ b" . + also have "c * ... \ b " by (simp! add: le_maxI1) + finally show "y \ b" . qed simp qed qed qed -text {* The norm of a continuous function is always @{text "\\ 0"}. *} +text {* The norm of a continuous function is always @{text "\ 0"}. *} lemma fnorm_ge_zero [intro?]: - "is_continuous V norm f \\ is_normed_vectorspace V norm - \\ #0 \\ \\f\\V,norm" + "is_continuous V norm f \ is_normed_vectorspace V norm + \ #0 \ \f\V,norm" proof - assume c: "is_continuous V norm f" and n: "is_normed_vectorspace V norm" txt {* The function norm is defined as the supremum of @{text B}. - So it is @{text "\\ 0"} if all elements in @{text B} are - @{text "\\ 0"}, provided the supremum exists and @{text B} is not + So it is @{text "\ 0"} if all elements in @{text B} are + @{text "\ 0"}, provided the supremum exists and @{text B} is not empty. *} show ?thesis proof (unfold function_norm_def, rule sup_ub1) - show "\\x \\ (B V norm f). #0 \\ x" + show "\x \ (B V norm f). #0 \ x" proof (intro ballI, unfold B_def, elim UnE singletonE CollectE exE conjE) fix x r - assume "x \\ V" "x \\ 0" - and r: "r = \\f x\\ * inverse (norm x)" + assume "x \ V" "x \ 0" + and r: "r = \f x\ * inverse (norm x)" - have ge: "#0 \\ \\f x\\" by (simp! only: abs_ge_zero) - have "#0 \\ inverse (norm x)" + have ge: "#0 \ \f x\" by (simp! only: abs_ge_zero) + have "#0 \ inverse (norm x)" by (rule order_less_imp_le, rule real_inverse_gt_zero1, rule)(*** proof (rule order_less_imp_le); show "#0 < inverse (norm x)"; @@ -219,34 +216,34 @@ show "#0 < norm x"; ..; qed; qed; ***) - with ge show "#0 \\ r" + with ge show "#0 \ r" by (simp only: r, rule real_le_mult_order1a) qed (simp!) txt {* Since @{text f} is continuous the function norm exists: *} - have "is_function_norm f V norm \\f\\V,norm" .. + have "is_function_norm f V norm \f\V,norm" .. thus "is_Sup UNIV (B V norm f) (Sup UNIV (B V norm f))" by (unfold is_function_norm_def function_norm_def) txt {* @{text B} is non-empty by construction: *} - show "#0 \\ B V norm f" by (rule B_not_empty) + show "#0 \ B V norm f" by (rule B_not_empty) qed qed text {* \medskip The fundamental property of function norms is: \begin{center} - @{text "\\f x\\ \\ \\f\\ \\ \\x\\"} + @{text "\f x\ \ \f\ \ \x\"} \end{center} *} lemma norm_fx_le_norm_f_norm_x: - "is_continuous V norm f \\ is_normed_vectorspace V norm \\ x \\ V - \\ \\f x\\ \\ \\f\\V,norm * norm x" + "is_continuous V norm f \ is_normed_vectorspace V norm \ x \ V + \ \f x\ \ \f\V,norm * norm x" proof - - assume "is_normed_vectorspace V norm" "x \\ V" + assume "is_normed_vectorspace V norm" "x \ V" and c: "is_continuous V norm f" have v: "is_vectorspace V" .. @@ -260,46 +257,46 @@ @{text "f 0 = 0"}. *} assume "x = 0" - have "\\f x\\ = \\f 0\\" by (simp!) + have "\f x\ = \f 0\" by (simp!) also from v continuous_linearform have "f 0 = #0" .. also note abs_zero - also have "#0 \\ \\f\\V,norm * norm x" + also have "#0 \ \f\V,norm * norm x" proof (rule real_le_mult_order1a) - show "#0 \\ \\f\\V,norm" .. - show "#0 \\ norm x" .. + show "#0 \ \f\V,norm" .. + show "#0 \ norm x" .. qed finally - show "\\f x\\ \\ \\f\\V,norm * norm x" . + show "\f x\ \ \f\V,norm * norm x" . next - assume "x \\ 0" + assume "x \ 0" have n: "#0 < norm x" .. - hence nz: "norm x \\ #0" + hence nz: "norm x \ #0" by (simp only: lt_imp_not_eq) - txt {* For the case @{text "x \\ 0"} we derive the following fact + txt {* For the case @{text "x \ 0"} we derive the following fact from the definition of the function norm:*} - have l: "\\f x\\ * inverse (norm x) \\ \\f\\V,norm" + have l: "\f x\ * inverse (norm x) \ \f\V,norm" proof (unfold function_norm_def, rule sup_ub) from ex_fnorm [OF _ c] show "is_Sup UNIV (B V norm f) (Sup UNIV (B V norm f))" by (simp! add: is_function_norm_def function_norm_def) - show "\\f x\\ * inverse (norm x) \\ B V norm f" + show "\f x\ * inverse (norm x) \ B V norm f" by (unfold B_def, intro UnI2 CollectI exI [of _ x] conjI, simp) qed txt {* The thesis now follows by a short calculation: *} - have "\\f x\\ = \\f x\\ * #1" by (simp!) + have "\f x\ = \f x\ * #1" by (simp!) also from nz have "#1 = inverse (norm x) * norm x" by (simp add: real_mult_inv_left1) - also have "\\f x\\ * ... = \\f x\\ * inverse (norm x) * norm x" + also have "\f x\ * ... = \f x\ * inverse (norm x) * norm x" by (simp! add: real_mult_assoc) - also from n l have "... \\ \\f\\V,norm * norm x" + also from n l have "... \ \f\V,norm * norm x" by (simp add: real_mult_le_le_mono2) - finally show "\\f x\\ \\ \\f\\V,norm * norm x" . + finally show "\f x\ \ \f\V,norm * norm x" . qed qed @@ -307,72 +304,72 @@ \medskip The function norm is the least positive real number for which the following inequation holds: \begin{center} - @{text "\\f x\\ \\ c \\ \\x\\"} + @{text "\f x\ \ c \ \x\"} \end{center} *} lemma fnorm_le_ub: - "is_continuous V norm f \\ is_normed_vectorspace V norm \\ - \\x \\ V. \\f x\\ \\ c * norm x \\ #0 \\ c - \\ \\f\\V,norm \\ c" + "is_continuous V norm f \ is_normed_vectorspace V norm \ + \x \ V. \f x\ \ c * norm x \ #0 \ c + \ \f\V,norm \ c" proof (unfold function_norm_def) assume "is_normed_vectorspace V norm" assume c: "is_continuous V norm f" - assume fb: "\\x \\ V. \\f x\\ \\ c * norm x" - and "#0 \\ c" + assume fb: "\x \ V. \f x\ \ c * norm x" + and "#0 \ c" - txt {* Suppose the inequation holds for some @{text "c \\ 0"}. If + txt {* Suppose the inequation holds for some @{text "c \ 0"}. If @{text c} is an upper bound of @{text B}, then @{text c} is greater than the function norm since the function norm is the least upper bound. *} - show "Sup UNIV (B V norm f) \\ c" + show "Sup UNIV (B V norm f) \ c" proof (rule sup_le_ub) from ex_fnorm [OF _ c] show "is_Sup UNIV (B V norm f) (Sup UNIV (B V norm f))" by (simp! add: is_function_norm_def function_norm_def) txt {* @{text c} is an upper bound of @{text B}, i.e. every - @{text "y \\ B"} is less than @{text c}. *} + @{text "y \ B"} is less than @{text c}. *} show "isUb UNIV (B V norm f) c" proof (intro isUbI setleI ballI) - fix y assume "y \\ B V norm f" - thus le: "y \\ c" + fix y assume "y \ B V norm f" + thus le: "y \ c" proof (unfold B_def, elim UnE CollectE exE conjE singletonE) - txt {* The first case for @{text "y \\ B"} is @{text "y = 0"}. *} + txt {* The first case for @{text "y \ B"} is @{text "y = 0"}. *} assume "y = #0" - show "y \\ c" by (blast!) + show "y \ c" by (blast!) - txt{* The second case is @{text "y = \\f x\\ / \\x\\"} for some - @{text "x \\ V"} with @{text "x \\ 0"}. *} + txt{* The second case is @{text "y = \f x\ / \x\"} for some + @{text "x \ V"} with @{text "x \ 0"}. *} next fix x - assume "x \\ V" "x \\ 0" + assume "x \ V" "x \ 0" have lz: "#0 < norm x" by (simp! add: normed_vs_norm_gt_zero) - have nz: "norm x \\ #0" + have nz: "norm x \ #0" proof (rule not_sym) - from lz show "#0 \\ norm x" + from lz show "#0 \ norm x" by (simp! add: order_less_imp_not_eq) qed from lz have "#0 < inverse (norm x)" by (simp! add: real_inverse_gt_zero1) - hence inverse_gez: "#0 \\ inverse (norm x)" + hence inverse_gez: "#0 \ inverse (norm x)" by (rule order_less_imp_le) - assume "y = \\f x\\ * inverse (norm x)" - also from inverse_gez have "... \\ c * norm x * inverse (norm x)" + assume "y = \f x\ * inverse (norm x)" + also from inverse_gez have "... \ c * norm x * inverse (norm x)" proof (rule real_mult_le_le_mono2) - show "\\f x\\ \\ c * norm x" by (rule bspec) + show "\f x\ \ c * norm x" by (rule bspec) qed - also have "... \\ c" by (simp add: nz real_mult_assoc) + also have "... \ c" by (simp add: nz real_mult_assoc) finally show ?thesis . qed qed blast diff -r ba2c252b55ad -r d08d4e17a5f6 src/HOL/Real/HahnBanach/FunctionOrder.thy --- a/src/HOL/Real/HahnBanach/FunctionOrder.thy Tue Aug 07 19:29:08 2001 +0200 +++ b/src/HOL/Real/HahnBanach/FunctionOrder.thy Tue Aug 07 21:27:00 2001 +0200 @@ -27,7 +27,7 @@ "graph F f \ {(x, f x) | x. x \ F}" lemma graphI [intro?]: "x \ F \ (x, f x) \ graph F f" - by (unfold graph_def, intro CollectI exI) blast + by (unfold graph_def) blast lemma graphI2 [intro?]: "x \ F \ \t\ (graph F f). t = (x, f x)" by (unfold graph_def) blast diff -r ba2c252b55ad -r d08d4e17a5f6 src/HOL/Real/HahnBanach/VectorSpace.thy --- a/src/HOL/Real/HahnBanach/VectorSpace.thy Tue Aug 07 19:29:08 2001 +0200 +++ b/src/HOL/Real/HahnBanach/VectorSpace.thy Tue Aug 07 21:27:00 2001 +0200 @@ -146,14 +146,10 @@ proof - assume "is_vectorspace V" have "V \ {}" .. - hence "\x. x \ V" by blast - thus ?thesis - proof - fix x assume "x \ V" - have "0 = x - x" by (simp!) - also have "... \ V" by (simp! only: vs_diff_closed) - finally show ?thesis . - qed + then obtain x where "x \ V" by blast + have "0 = x - x" by (simp!) + also have "... \ V" by (simp! only: vs_diff_closed) + finally show ?thesis . qed lemma vs_add_zero_left [simp]: