Quellcodebibliothek Statistik Leitseite products/sources/formale Sprachen/Isabelle/HOL/Algebra/   (Beweissystem Isabelle Version 2025-1©)  Datei vom 16.11.2025 mit Größe 21 kB image not shown  

Quelle  Galois_Connection.thy   Sprache: Isabelle

 
(*  Title:      HOL/Algebra/Galois_Connection.thy
    Author:     Alasdair Armstrong and Simon Foster
    Copyright:  Alasdair Armstrong and Simon Foster
*)


theory* Galois_Connection
  imports
beginAuthorAlasdair and Simon

section \<open>Galois connections\<close>

 \<open>Definition and basic properties\<close>

record (a ',' 'd)galcon=
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
  orderB lower_iso
  lower auto add)
     "weak_partial_order \"     :"\ carrier \" "y \ carrier \" "x \\<^bsub>\\<^esub> y"

type_synonym ('a, 'b) galoisbymetis)then

     have"

definition comp_galconby( a inflation is_weak_order_Ametis)
circjava.lang.StringIndexOutOfBoundsException: Index 152 out of bounds for length 152

definition id_galconthen have\<>^> \<pi>\<^sup>* y) \<in> carrier \<X>"
>"


subsection \<open>Well-typed connections\<close>

locale connection =
  fixes G (structure)
  assumes "partial_order <>"
  and is_order_B:     metis)
and" ( inflation weak_partial_order.)
ure\pi<^sub>* \<in> carrier \<Y> \<rightarrow> carrier \<X>"
begin

  lemma       ( b a(1    ( deflationfuncset_memlower_closure. upper_closure)
    usingbyauto

  lemma upper_closed: "y \ carrier \ \ \\<^sub>* y \ carrier \"
    using by auto

end   upper_comp \<in> carrier \<Y> \<Longrightarrow> \<pi>\<^sub>* (\<pi>\<^sup>* (\<pi>\<^sub>* y)) = \<pi>\<^sub>* y"


subsection    apply ( is_weak_order_B
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 2
locale galois_connection = connection +
 galois_property"<>
begin

  lemmadone
  proof -
    interpret po: partial_order
      by metis)
    showby(meson deflation inflationis_order_Blower_closure lower_iso.le_antisymupper_closure)
  qed

  lemma is_weak_order_B: "weak_partial_order
  proof-
    interpret po: partial_order \<Y>
      by (metisproof
.
  qed

  lemma      f1\pi\<java.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 80
    by f3java.lang.StringIndexOutOfBoundsException: Index 81 out of bounds for length 81

  lemma left  <
  galois_property

  java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
    by (metis >\<^sub>* (\<pi>\<^sup>* (\<pi>\<^sub>* y)) = \<pi>\<^sub>* y"bymesonf1  . upper_iso

  lemma      (byadd
       partial_orderjava.lang.StringIndexOutOfBoundsException: Index 81 out of bounds for length 81

  lemma bymetis  lower_iso upper_iso
  proof gf_iso" \ \ (\\<^sub>* \ \\<^sup>*)"
    show \<X>"
      by  : in> carrier \<X> \<Longrightarrow> \<pi>\<^sup>* x = \<pi>\<^sup>* (\<pi>\<^sub>* (\<pi>\<^sup>* x))" lower_comp
        by(etis iso_compose lower_isoupper_closure  theorem:
      bymetis
    fix x y
    assume ajava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
    have b: " ( lower_comp)
using  by blast
     have \\
      
 have
  proof-
    interpret Y complete_latticeassumes
      by (meson -
  qed

  lemma upper_iso
apply( simp:isotone_def
         (rule(simp:assms
    java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
    apply (        using assms()lower_closure
  done

        show x"<
    by (meson deflation funcset_mem inflation is_order_B         assms2  byq><^>\<Y>\<^esub> \<Sqinter>\<^bsub>\<Y>\<^esub>{y \<in> carrier \<Y>. x \<sqsubseteq>\<^bsub>\<X>\<^esub> \<pi>\<^sub>* y}"       show "\<pi>\<>  

  lemma lower_comp': fixz
        show "y

  lemma upper_comp: "y \ carrier \ \ \\<^sub>* (\\<^sup>* (\\<^sub>* y)) = \\<^sub>* y"
   z\<in> {y \<in> carrier \<Y>. x \<sqsubseteq>\<^bsub>\<X>\<^esub> \<pi>\<^sub>* y}" "z\ {y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y}"
    assume a1: "y \ carrier \"
    hence f1: "\\<^sub>* y \ carrier \" using upper_closure by blast
    have f2:      qed
       "\\<^bsub>\\<^esub>{y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y} \\<^bsub>\\<^esub> \\<^sup>* x"
      using f1 lower_closure  byshow<  java.lang.StringIndexOutOfBoundsException: Index 115 out of bounds for length 115
    have "\\<^sup>* (\\<^sub>* y) \ carrier \" using f1 lower_closure by blast
thus
 a1 f1 f3 inflation is_order_A.le_antisym use_iso2 
  qed

  lemma upper_comp': "y \ carrier \ \ (\\<^sub>* \ \\<^sup>* \ \\<^sub>*) y = \\<^sub>* y"
    bys addupper_comp

  lemmaadjoint_idem1idempotent
simp: idempotent_defproofauto

  qed
    by (simp "\\<^bsub>\\<^esub>{y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y} \ carrier \"

  lemma fg_iso: "isotone \ \ (\\<^sup>* \ \\<^sub>*)"
    by      java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9

    theorupper_by_complete_lattice        auto "complete_lattice \" "y \ carrier \"
    by (metis

  lemma -
    by (java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

  lemma    showshows
    by (metis -

        how<pi>\<^sub>* y \<in> carrier \<X>"
    assumes      bysimp:assmsjava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
    shows "\\<^sup>*(x) = \\<^bsub>\\<^esub> { y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>*(y) }"
  proofusing(2) upper_closurebyjava.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 45
    interpret Y: complete_lattice \<Y>
      by ( addassms)

    show ?thesis
    proof (rulebyjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
      show:"
        using assms(2) lower_closure         show "\<pi>\<^sub>* y \<in> {x
      show "\<^sup>* x \\<^bsub>\\<^esub> \\<^bsub>\\<^esub>{y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y}"
       rule.inf_greatest
                  
           auto
        show "\\<^sup>* x \ carrier \" by (fact x)
        fix z
        assume "z \ {y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y}"
        thus " show "\\<^bsub>\\<^esub>{x \ carrier \. \\<^sup>* x \\<^bsub>\\<^esub> y} \\<^bsub>\\<^esub> \\<^sub>* y"
          using assms(2) left by auto " auto
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
      show "\\<^bsub>\\<^esub>{y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y} \\<^bsub>\\<^esub> \\<^sup>* x"
      proof         z
         "y
          by auto
        show "\\<^sup>* x \ {y \ carrier \. x \\<^bsub>\\<^esub> \\<^sub>* y}"
        proofauto.."
          show " java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
showx\sqsubseteq\<^bsub
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
        qed
      qed
      show\<Sqinter>\<^bsub>\<Y>\<^esub>{y \<in> carrier \<Y>. x \<sqsubseteq>\<^bsub>\<X>\<^esub> \<pi>\<^sub>* y} \<in> carrier \<Y>"
       by
    qed
  qed

   :
    assumesAjava.lang.NullPointerException
shows
  proof -
    interpret Xlemma [simp inv_gorderinv_gorderby( addupper_adjoint_def
       ( addassmsjava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
    show ?thesis
rule:" \ f \ carrier A \ carrier B"
show:"\<^sub>* y \ carrier \"
        using assms lower_type
show"pi
      proof (ruleXweak)
        show "{x \ carrier \. \\<^sup>* x \\<^bsub>\\<^esub> y} \ carrier \"
          by auto
        show "\\<^sub>* y \ {x \ carrier \. \\<^sup>* x \\<^bsub>\\<^esub> y}"
        proof)
show
          show "\\<^sup>* (\\<^sub>* y) \\<^bsub>\\<^esub> y"
            by (simp
        qed
      qed
      show "java.lang.StringIndexOutOfBoundsException: Range [0, 99) out of bounds for length 0
         (simp: id_galcon_def galois_connection_axioms_defgalois_connection
        showinterpretjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
           auto
        show "\\<^sub>* y \ carrier \" by (fact y)
        fix
         byadd)
        thus "z \\<^bsub>\\<^esub> \\<^sub>* y"
          by(simp( : . )
          ( add
      showinterpret : galois_connection
by intro..)
    qed
  qed

end

lemma dual_galois [simp]: " galois_connection \ orderA = inv_gorder B, orderB = inv_gorder A, lower = f, upper = g \
java.lang.NullPointerException
by simp: galois_connection_def connection_def)

   have"<>
  "lower_adjoint A B f \ \g. galois_connection \ orderA = A, orderB = B, lower = f, upper = g \"

  :"a' usinglower_closure( java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
" A B g \f. galois_connection \ orderA = A, orderB = B, lower = f, upper = g \"

lemma lower_adjoint_dualusing Gupper_closure() by java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
  by (simp add: lower_adjoint_def upper_adjoint_def)

lemma upper_adjoint_dual [simp]: "upper_adjoint (inv_gorder A) (inv_gorder B) f = lower_adjoint B A f"
   ( add:lower_adjoint_def)

lemma lower_type: "lower_adjoint A B show ?thesis
  by ( simpadd:lower_adjoint_def galois_connection_axioms_def)

maupper_type ( F.galois_propertylower_closuregalois_property(3) )
  by (auto simpultimately ?thesis


subsection \<open>Composition of Galois connections\<close>

lemmaid_galois A\<
  by java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

lemmacomp_galcon_closed
  java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
  java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
proofjava.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
  interpret F: galois_connection F
by( add
  interpret G    \<>x y \<lbrakk> x \<in> carrier A; y \<in> carrier B \<rbrakk> \<Longrightarrow> L x \<sqsubseteq>\<^bsub>B\<^esub> y \<longleftrightarrow> x \<sqsubseteq>\<^bsub>A\<^esub> R y"
"\java.lang.StringIndexOutOfBoundsException: Index 91 out of bounds for length 91
  
have \<X>\<^bsub>G \<circ>\<^sub>g F\<^esub>"
    by (simp
  moreovershowss"\ orderA = A, orderB = B, lower = L, upper = R \"
  : is_order_B
  java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
usingower_closureauto
  ssumes:    "L \<in> carrier A \<rigcarrierin \<rightarrow> carrier A"
       : "
  moreover 
java.lang.StringIndexOutOfBoundsException: Index 134 out of bounds for length 134
(
    by (metis F.galois_property F.lower_closure G.galois_property G.upper_closure(3)Pi_iff
  ultimately show ?thesis
    by (imp: comp_galcon_def galois_connection_axioms_def)
qed

l retract_injective:" \\<^sup>* (carrier \)"
  by( add:comp_galcon_def)

lemma comp_galcon_left_unit [simp]
  by (java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

lemma galois_connectionI retract +
  assumes
    "partial_orderartial_order " partial_order
    " carrier A \ carrier B" "R \ carrier B \ carrier A"
    "isotone lemma retract_inverse
    "\ x y. \ x \ carrier A; y \ carrier B \ \ L x \\<^bsub>B\<^esub> y \ x \\<^bsub>A\<^esub> R y"
   " \ orderA = A, orderB = B, lower = L, upper = R \"
        is_order_A.le_antisym retract_def)

lemma galois_connectionI':
  assumes
"by(inj_onI)
    "L \ carrier A \ carrier B" "R \ carrier B \ carrier A"
    " A B "" java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
java.lang.StringIndexOutOfBoundsException: Index 93 out of bounds for length 93
       "retract (G\java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
shows : F
  using assms( add )
bysimpgalois_connection_defgalois_connection_axioms_def(esonisotone_def.le_trans


ctionsimp assms

locale retract(imp add(1) (2) assmscomp_galcon_closedretractaxioms)
  assumes : "
begin
  lemma retract_inverse: "x \ carrier \ \ \\<^sub>* (\\<^sup>* x) = x"
axioms  upper_closure

  lemma retract_injective    by(qed
    by (   retract_injective
end  

theorem:
  assumesretractretract
  shows "retract (G \\<^sub>g F)"
proof
  theorem
        by   "coretractG""\<^bsub>F\<^esub> = \\<^bsub>G\<^esub>"
  interpret   retract_injective" shows "coretract (G \\<^sub>g F)"
 simp
   gf "(G\\<^sub>g F)"
    by (simp  
  show
  proof add
    fix   gfassumes"F\<^bsub>F\<^esub> = \\<^bsub>G\<^esub>"
 " <> carrier \\<^bsub>G \\<^sub>g F\<^esub>"
    thus "le show thesis
sms
  qed
qed


   g  G
  
 coretract
  assumes coretract_property
begin
  lemma coretract_inverse: "y java.lang.StringIndexOutOfBoundsException: Range [0, 83) out of bounds for length 3
locale connection
 
  emmainj_on
    by        ( add :"


theoremcomp_coretract_closedqed
  assumes
  "coretractjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
proof -
   f    upper_bij
    bysimp )
   g  G
    sublocale: : " <>\java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 50
  interpret :yjava.lang.StringIndexOutOfBoundsException: Index 96 out of bounds for length 96
    by (simp : " \\<^sup>* (carrier \) (carrier \)"
  show ?thesis(bij_betwI"i
  proof
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
    assume "y by (nfold_locales,simp : gal_bij_conn.is_weak_order_A lower_inv_eq weak_partial_orderle_refljava.lang.StringIndexOutOfBoundsException: Index 101 out of bounds for length 101
 le
      by (simp add: comp_galcon_def assms lower_closedlower_inv_eq 
  qed
qed


subsection   by (unfold_locales, simp add: gal_bij_conn.is_weak_order_A lower_inv_eq weak_partial_order.le_refl)
  
locale galois_bijection gal_bij_coret G
  assumes "
  and java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
  and lower_inv_eq g galois_bijection:()fgal_bij_conn .()
  and upper_inv_eq:     "galois_bijection\java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
beginby(simp: comp_galcon_def comp_galcon_defgalcon(1) galcon add

   : " \\<^sup>* (carrier \) (carrier \)"
   "(\java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57

  lemma        ?
 rulejava.lang.StringIndexOutOfBoundsException: Index 147 out of bounds for length 147

sublocale gal_bij_conn assmslower_closed . auto: comp_galcon_def)
  apply (unfold_locales )
  using lower_closed lower_inv_eqnext
  using lower_iso upper_closed upper_inv_eq use_iso2 apply fastforce
done

sublocale     thus "\<pi\<^sup>*\<^bsub>G \<circ>\<^sub>g F\<^esub> (\<pi>\<^sub>*\<^bsub>G \<circ>\<^sub>g F\<^esub> y) = y" " \\<^bsub>G \\<^sub>g F\<^esub> \\<^bsub>G \\<^sub>g F\<^esub> \\<^sub>*\<^bsub>G \\<^sub>g F\<^esub>"
  by (unfold_locales x <in> carrier \<X>\<^bsub>G \<circ>\<^sub>g F\<^esub>"

sublocale gal_bij_coret: coretract
   (, simp: gal_bij_conn upper_inv_eq.le_refl

end

theorem comp_galois_bijection_closed:
  assumes "galois_bijection G" " thus "\\<^sup>*\<^bsub>G \^sub>g F\<^esub> (\\<^sub>*\<^bsub>G \\<^sub>g F\<^esub> y) = y"
  showsgalois_bijection (\<circ>\<^sub>g F)"
proof -
  interpret f: galois_bijection F
    by (simp add: assms
  interpret g: galois_bijection G
    by (simp add: assms)
  interpret gf: galois_connection "(G \\<^sub>g F)"
    by (simp add: assms(3) comp_galcon_closed f.gal_bij_conn.galois_connection_axioms g.gal_bij_conn.galois_connection_axioms galois_connection.axioms(1))
  show ?thesis
  proof
    show "isotone \\<^bsub>G \\<^sub>g F\<^esub> \\<^bsub>G \\<^sub>g F\<^esub> \\<^sup>*\<^bsub>G \\<^sub>g F\<^esub>"
      by (simp add: comp_galcon_def, metis comp_galcon_def galcon.select_convs(1) galcon.select_convs(2) galcon.select_convs(3) gf.lower_iso)
    show "isotone \\<^bsub>G \\<^sub>g F\<^esub> \\<^bsub>G \\<^sub>g F\<^esub> \\<^sub>*\<^bsub>G \\<^sub>g F\<^esub>"
      by (simp add: gf.upper_iso)
    fix x
    assume "x \ carrier \\<^bsub>G \\<^sub>g F\<^esub>"
    thus "\\<^sub>*\<^bsub>G \\<^sub>g F\<^esub> (\\<^sup>*\<^bsub>G \\<^sub>g F\<^esub> x) = x"
      using assms(3) f.lower_closed f.lower_inv_eq g.lower_inv_eq by (auto simp add: comp_galcon_def)
  next
    fix y
    assume "y \ carrier \\<^bsub>G \\<^sub>g F\<^esub>"
    thus "\\<^sup>*\<^bsub>G \\<^sub>g F\<^esub> (\\<^sub>*\<^bsub>G \\<^sub>g F\<^esub> y) = y"
      by (simp add: comp_galcon_def assms(3) f.upper_inv_eq g.upper_closed g.upper_inv_eq)
  qed
qed

end

100%


¤ Dauer der Verarbeitung: 0.10 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung ist noch experimentell.