# HG changeset patch # User desharna # Date 1712039743 -7200 # Node ID 6de94d690f9f8b1fa2ae6dd05ae12a2cb779ad5f # Parent 60b6c735b5d5ec01a98e8b6a44ac96439b008392# Parent 67e77f1e6d7bd7b4c5546673c46e9a03c935cdd9 merged diff -r 60b6c735b5d5 -r 6de94d690f9f src/HOL/Algebra/Coset.thy --- a/src/HOL/Algebra/Coset.thy Mon Apr 01 15:47:15 2024 +0200 +++ b/src/HOL/Algebra/Coset.thy Tue Apr 02 08:35:43 2024 +0200 @@ -670,7 +670,9 @@ interpret group G by fact show ?thesis proof (intro equivI) - show "refl_on (carrier G) (rcong H)" + have "rcong H \ carrier G \ carrier G" + by (auto simp add: r_congruent_def) + thus "refl_on (carrier G) (rcong H)" by (auto simp add: r_congruent_def refl_on_def) next show "sym (rcong H)" diff -r 60b6c735b5d5 -r 6de94d690f9f src/HOL/Algebra/Sylow.thy --- a/src/HOL/Algebra/Sylow.thy Mon Apr 01 15:47:15 2024 +0200 +++ b/src/HOL/Algebra/Sylow.thy Tue Apr 02 08:35:43 2024 +0200 @@ -23,6 +23,9 @@ and "RelM \ {(N1, N2). N1 \ calM \ N2 \ calM \ (\g \ carrier G. N1 = N2 #> g)}" begin +lemma RelM_subset: "RelM \ calM \ calM" + by (auto simp only: RelM_def) + lemma RelM_refl_on: "refl_on calM RelM" by (auto simp: refl_on_def RelM_def calM_def) (blast intro!: coset_mult_one [symmetric]) @@ -41,7 +44,7 @@ by (auto simp add: trans_def RelM_def calM_def coset_mult_assoc) lemma RelM_equiv: "equiv calM RelM" - unfolding equiv_def by (blast intro: RelM_refl_on RelM_sym RelM_trans) + using RelM_subset RelM_refl_on RelM_sym RelM_trans by (intro equivI) lemma M_subset_calM_prep: "M' \ calM // RelM \ M' \ calM" unfolding RelM_def by (blast elim!: quotientE) diff -r 60b6c735b5d5 -r 6de94d690f9f src/HOL/Cardinals/Wellorder_Constructions.thy --- a/src/HOL/Cardinals/Wellorder_Constructions.thy Mon Apr 01 15:47:15 2024 +0200 +++ b/src/HOL/Cardinals/Wellorder_Constructions.thy Tue Apr 02 08:35:43 2024 +0200 @@ -44,6 +44,9 @@ corollary ordLeq_preorder_on: "preorder_on {r. Well_order r} ordLeq" by(auto simp add: preorder_on_def ordLeq_refl_on ordLeq_trans) +corollary ordIso_subset: "ordIso \ {r. Well_order r} \ {r. Well_order r}" + using ordIso_reflexive unfolding refl_on_def ordIso_def by blast + corollary ordIso_refl_on: "refl_on {r. Well_order r} ordIso" using ordIso_reflexive unfolding refl_on_def ordIso_def by blast @@ -55,7 +58,7 @@ by (auto simp add: sym_def ordIso_symmetric) corollary ordIso_equiv: "equiv {r. Well_order r} ordIso" - by (auto simp add: equiv_def ordIso_sym ordIso_refl_on ordIso_trans) + using ordIso_subset ordIso_refl_on ordIso_sym ordIso_trans by (intro equivI) lemma ordLess_Well_order_simp[simp]: assumes "r p \ P. x \ p \ y \ p}" proof (rule equivI) - have "A = \P" "disjoint P" "{} \ P" + have "A = \P" using P by (auto simp: partition_on_def) + + have "{(x, y). \p \ P. x \ p \ y \ p} \ A \ A" + unfolding \A = \P\ by blast then show "refl_on A {(x, y). \p\P. x \ p \ y \ p}" - unfolding refl_on_def by auto + unfolding refl_on_def \A = \P\ by auto +next show "trans {(x, y). \p\P. x \ p \ y \ p}" - using \disjoint P\ by (auto simp: trans_def disjoint_def) -qed (auto simp: sym_def) + using P by (auto simp only: trans_def disjoint_def partition_on_def) +next + show "sym {(x, y). \p\P. x \ p \ y \ p}" + by (auto simp only: sym_def) +qed lemma partition_on_eq_quotient: assumes P: "partition_on A P" diff -r 60b6c735b5d5 -r 6de94d690f9f src/HOL/Library/FSet.thy --- a/src/HOL/Library/FSet.thy Mon Apr 01 15:47:15 2024 +0200 +++ b/src/HOL/Library/FSet.thy Tue Apr 02 08:35:43 2024 +0200 @@ -192,6 +192,23 @@ end +syntax (input) + "_fBall" :: "pttrn \ 'a fset \ bool \ bool" ("(3! (_/|:|_)./ _)" [0, 0, 10] 10) + "_fBex" :: "pttrn \ 'a fset \ bool \ bool" ("(3? (_/|:|_)./ _)" [0, 0, 10] 10) + +syntax + "_fBall" :: "pttrn \ 'a fset \ bool \ bool" ("(3\(_/|\|_)./ _)" [0, 0, 10] 10) + "_fBex" :: "pttrn \ 'a fset \ bool \ bool" ("(3\(_/|\|_)./ _)" [0, 0, 10] 10) + +translations + "\x|\|A. P" \ "CONST FSet.Ball A (\x. P)" + "\x|\|A. P" \ "CONST FSet.Bex A (\x. P)" + +print_translation \ + [Syntax_Trans.preserve_binder_abs2_tr' \<^const_syntax>\fBall\ \<^syntax_const>\_fBall\, + Syntax_Trans.preserve_binder_abs2_tr' \<^const_syntax>\fBex\ \<^syntax_const>\_fBex\] +\ \ \to avoid eta-contraction of body\ + context includes lifting_syntax begin diff -r 60b6c735b5d5 -r 6de94d690f9f src/HOL/Library/Multiset_Order.thy --- a/src/HOL/Library/Multiset_Order.thy Mon Apr 01 15:47:15 2024 +0200 +++ b/src/HOL/Library/Multiset_Order.thy Tue Apr 02 08:35:43 2024 +0200 @@ -813,7 +813,16 @@ lemma wf_less_multiset: "wf {(M :: 'a multiset, N). M < N}" unfolding less_multiset_def multp_def by (auto intro: wf_mult wf) -instance by standard (metis less_multiset_def multp_def wf wf_def wf_mult) +instance +proof intro_classes + fix P :: "'a multiset \ bool" and a :: "'a multiset" + have "wfp ((<) :: 'a \ 'a \ bool)" + using wfp_on_less . + hence "wfp ((<) :: 'a multiset \ 'a multiset \ bool)" + unfolding less_multiset_def by (rule wfP_multp) + thus "(\x. (\y. y < x \ P y) \ P x) \ P a" + unfolding wfp_on_def[of UNIV, simplified] by metis +qed end diff -r 60b6c735b5d5 -r 6de94d690f9f src/HOL/ZF/Games.thy --- a/src/HOL/ZF/Games.thy Mon Apr 01 15:47:15 2024 +0200 +++ b/src/HOL/ZF/Games.thy Tue Apr 02 08:35:43 2024 +0200 @@ -815,8 +815,16 @@ unfolding Pg_def by (auto simp add: quotient_def) lemma equiv_eq_game[simp]: "equiv UNIV eq_game_rel" - by (auto simp add: equiv_def refl_on_def sym_def trans_def eq_game_rel_def - eq_game_sym intro: eq_game_refl eq_game_trans) +proof (rule equivI) + show "refl eq_game_rel" + by (auto simp only: eq_game_rel_def intro: reflI eq_game_refl) +next + show "sym eq_game_rel" + by (auto simp only: eq_game_rel_def eq_game_sym intro: symI) +next + show "trans eq_game_rel" + by (auto simp only: eq_game_rel_def intro: transI eq_game_trans) +qed instantiation Pg :: "{ord, zero, plus, minus, uminus}" begin