# HG changeset patch # User paulson # Date 1556398619 -3600 # Node ID 373eb0aa97e302dc86687edb6a5fed436f3aaccc # Parent 2e496190039d62b49bab8931ff4a2d65908710be tiny bit of extra restructuring diff -r 2e496190039d -r 373eb0aa97e3 src/HOL/ex/Tarski.thy --- a/src/HOL/ex/Tarski.thy Sat Apr 27 20:00:38 2019 +0100 +++ b/src/HOL/ex/Tarski.thy Sat Apr 27 21:56:59 2019 +0100 @@ -444,34 +444,34 @@ qed qed -lemma flubH_le_lubH: +lemma lubH_is_fixp: assumes "H = {x \ A. (x, f x) \ r}" - shows "(f (lub H cl), lub H cl) \ r" + shows "lub H cl \ fix f A" proof - - have "(lub H cl, f (lub H cl)) \ r" - using assms lubH_le_flubH by blast - then have "(f (lub H cl), f (f (lub H cl))) \ r" - by (meson PO_imp_refl_on monotoneE monotone_f refl_on_domain) - then have "f (lub H cl) \ H" - by (metis (no_types, lifting) PO_imp_refl_on assms mem_Collect_eq refl_on_domain) - then show ?thesis - by (simp add: assms lub_upper) + have "(f (lub H cl), lub H cl) \ r" + proof - + have "(lub H cl, f (lub H cl)) \ r" + using assms lubH_le_flubH by blast + then have "(f (lub H cl), f (f (lub H cl))) \ r" + by (meson PO_imp_refl_on monotoneE monotone_f refl_on_domain) + then have "f (lub H cl) \ H" + by (metis (no_types, lifting) PO_imp_refl_on assms mem_Collect_eq refl_on_domain) + then show ?thesis + by (simp add: assms lub_upper) + qed + with assms show ?thesis + by (simp add: fix_def antisymE lubH_le_flubH lub_in_lattice) qed - - -lemma lubH_is_fixp: "H = {x \ A. (x, f x) \ r} \ lub H cl \ fix f A" - by (simp add: fix_def antisymE flubH_le_lubH lubH_le_flubH lub_in_lattice) - -lemma fix_in_H: "\H = {x \ A. (x, f x) \ r}; x \ P\ \ x \ H" - by (simp add: P_def fix_imp_eq [of _ f A] reflE fix_subset [of f A, THEN subsetD]) - -lemma fixf_le_lubH: "H = {x \ A. (x, f x) \ r} \ \x \ fix f A. (x, lub H cl) \ r" - by (metis (no_types, lifting) P_def fix_in_H lub_upper mem_Collect_eq subset_eq) - -lemma lubH_least_fixf: - "H = {x \ A. (x, f x) \ r} \ \L. (\y \ fix f A. (y,L) \ r) \ (lub H cl, L) \ r" - using lubH_is_fixp by blast +lemma fixf_le_lubH: + assumes "H = {x \ A. (x, f x) \ r}" "x \ fix f A" + shows "(x, lub H cl) \ r" +proof - + have "x \ P \ x \ H" + by (simp add: assms P_def fix_imp_eq [of _ f A] reflE fix_subset [of f A, THEN subsetD]) + with assms show ?thesis + by (metis (no_types, lifting) P_def lub_upper mem_Collect_eq subset_eq) +qed subsection \Tarski fixpoint theorem 1, first part\ @@ -623,9 +623,8 @@ using Bot_dual_Top Bot_prop intervalI reflE by fastforce -subsection \fixed points form a partial order\ - -lemma fixf_po: "\pset = P, order = induced P r\ \ PartialOrder" +text \the set of fixed points form a partial order\ +proposition fixf_po: "\pset = P, order = induced P r\ \ PartialOrder" by (simp add: P_def fix_subset po_subset_po) end @@ -723,11 +722,9 @@ end lemma CompleteLatticeI_simp: - "\po \ PartialOrder; \S. S \ A \ \L. isLub S po L; A = pset po\ - \ po \ CompleteLattice" + "\po \ PartialOrder; \S. S \ A \ \L. isLub S po L; A = pset po\ \ po \ CompleteLattice" by (metis CompleteLatticeI Rdual) - theorem (in CLF) Tarski_full: "\pset = P, order = induced P r\ \ CompleteLattice" proof (intro CompleteLatticeI_simp allI impI) show "\pset = P, order = induced P r\ \ PartialOrder"