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

Quelle  Lattice.thy   Sprache: Isabelle

 
(*  Title:      HOL/Algebra/Lattice.thy
    Author:     Clemens Ballarin, started 7 November 2003
    Copyright:  Clemens Ballarin

Most congruence rules by Stephan Hohe.
With additional contributions from Alasdair Armstrong and Simon Foster.
*)


(  Title      /Algebrathy:      Ballarin   2003
imports congruence Stephan.
 additional  Alasdair and Foster

 \<open>Lattices\<close>
  
ction

definition
  sup :: "
  where

definition \<open>Supremum and infimum\<close>sup _'set >' java.lang.NullPointerException
  _set
  where "\\<^bsub>L\<^esub>A = (SOME x. greatest L x (Lower L A))"

definition supr :: 
  "('a, 'b) gorder_scheme \ 'c set \ ('c \ 'a) \ 'a "
  where "supr L A f = \\<^bsub>L\<^esub>(f ` A)"

definition infi 
  "('a, 'b) gorder_scheme \ 'c set \ ('c \ 'a) \ 'a "
  where "infi L A f = \\<^bsub>L\<^esub>(f ` A)"

syntax( b 
  "_inf1 "supr  =
    (\<open>(\<open>indent=3 notation=\<open>binder IINF\<close>\<close>IINF\<index> _./ _)\<close> [0, 10] 10) : 
  "_inf"      :: "('a, 'b) gorder_scheme \ pttrn \ 'c set \ 'a \ 'a"
    (\<open>(\<open>indent=3 notation=\<open>binder IINF\<close>\<close>IINF\<index> _:_./ _)\<close> [0, 0, 10] 10)
  "_sup1"     :: "('a, 'b) gorder_scheme \ pttrns \ 'a \ 'a"
    (\<open>(\<open>indent=3 notation=\<open>binder SSUP\<close>\<close>SSUP\<index> _./ _)\<close> [0, 10] 10)
  "_sup"      :: "('a, 'b) gorder_scheme \ pttrn \ 'c set \ 'a \ 'a"
    (\<open>(\<open>indent=3 notation=\<open>binder SSUP\<close>\<close>SSUP\<index> _:_./ _)\<close> [0, 0, 10] 10)
syntax_consts
  "_inf1" "_inf" == infi and
  "_sup1" "_sup" == supr
translations
  "IINF\<^bsub>L\<^esub> x. B" == "CONST infi L CONST UNIV (%x. B)"
  "IINF\<^bsub>L\<^esub> x:A. B" == "CONST infi L A (%x. B)"
  "SSUP\<^bsub>L\<^esub> x. B" == "CONST supr L CONST UNIV (%x. B)"
  "SSUP\<^bsub>L\<^esub> x:A. B" == "CONST supr L A (%x. B)"

definition
  join :: "[_, 'a, 'a] => 'a" (infixl \<open>\<squnion>\<index>\<close> 65)
  where "x \\<^bsub>L\<^esub> y = \\<^bsub>L\<^esub>{x, y}"

definition
  meet :: "[_, 'a, 'a] => 'a" (infixl \<open>\<sqinter>\<index>\<close> 70)
  where "x \\<^bsub>L\<^esub> y = \\<^bsub>L\<^esub>{x, y}"

definition
  LEAST_FP :: "('a, 'b) gorder_scheme \ ('a \ 'a) \ 'a" (\LFP\\) where
  "LEAST_FP L f = \\<^bsub>L\<^esub> {u \ carrier L. f u \\<^bsub>L\<^esub> u}" \ \least fixed point\

definition
  GREATEST_FP:: "('a, 'b) gorder_scheme \ ('a \ 'a) \ 'a" (\GFP\\) where
  "GREATEST_FP L f = \\<^bsub>L\<^esub> {u \ carrier L. u \\<^bsub>L\<^esub> f u}" \ \greatest fixed point\


subsection \<open>Dual operators\<close>

lemma sup_dual [simp]: 
  "\\<^bsub>inv_gorder L\<^esub>A = \\<^bsub>L\<^esub>A"
  by (simp add: sup_def inf_def)

lemma inf_dual [simp]: 
  "\\<^bsub>inv_gorder L\<^esub>A = \\<^bsub>L\<^esub>A"
  by (simp add: sup_def inf_def)

lemma join_dual [simp]:
  "p \\<^bsub>inv_gorder L\<^esub> q = p \\<^bsub>L\<^esub> q"
  by (simp add:join_def meet_def)

lemma meet_dual [simp]:
  "p \\<^bsub>inv_gorder L\<^esub> q = p \\<^bsub>L\<^esub> q"
  by (simp add:join_def meet_def)

lemma top_dual [simp]:
  "\\<^bsub>inv_gorder L\<^esub> = \\<^bsub>L\<^esub>"
  by (simp add: top_def bottom_def)

lemma bottom_dual [simp]:
  "\\<^bsub>inv_gorder L\<^esub> = \\<^bsub>L\<^esub>"
  by (simp add: top_def bottom_def)

lemma LFP_dual [simp]:
  "LEAST_FP (inv_gorder L) f = GREATEST_FP L f"
  by (simp add:LEAST_FP_def GREATEST_FP_def)

lemma GFP_dual [simp]:
  "GREATEST_FP (inv_gorder L) f = LEAST_FP L f"
  by (simp add:LEAST_FP_def GREATEST_FP_def)


subsection \<open>Lattices\<close>

locale weak_upper_semilattice = weak_partial_order +
  assumes sup_of_two_exists:
    "[| x \ carrier L; y \ carrier L |] ==> \s. least L s (Upper L {x, y})"

locale weak_lower_semilattice = weak_partial_order +
  assumes inf_of_two_exists:
    "[| x \ carrier L; y \ carrier L |] ==> \s. greatest L s (Lower L {x, y})"

locale weak_lattice = weak_upper_semilattice + weak_lower_semilattice

lemma (in weak_lattice) dual_weak_lattice:
  "weak_lattice (inv_gorder L)"
proof -
  interpret dual: weak_partial_order "inv_gorder L"
    by (metis dual_weak_order)
  show ?thesis
  proof qed (simp_all add: inf_of_two_exists sup_of_two_exists)
qed


subsubsection \<open>Supremum\<close>

lemma (in weak_upper_semilattice) joinI:
  "[| !!l. least L l (Upper L {x, y}) ==> P l; x \ carrier L; y \ carrier L |]
  ==> P (x \<squnion> y)"
( sup_def "infi L =\\<^bsub>L\<^esub>(f ` A)"
 :x\<in> carrier L"  "y \<in> carrier L"
    and P:(<open
  with sup_of_two_exists obtain s where "least L s (Upper L {x, y})" by fast
  with L show "P (SOME l. least L l (Upper L {x, y}))"
    by (fast intro: someI2 P)
qed

lemma (in weak_upper_semilattice) join_closed [simpjava.lang.StringIndexOutOfBoundsException: Index 116 out of bounds for length 116
syjava.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
  by  "_sup1" "_sup" == supr

lemma (in weak_upper_semilattice) join_cong_l:
  assumes carr: "x \ carrier L" "x' \ carrier L" "y \ carrier L"
java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
 
proof (rule joinIwhere
  fix   fix a :[ 'a, 'a]=a infixl

      have seq: "{x, y} {.=} {x', y}" by (rule set_eq_pairI)

  assume leasta: "least L a (Upper L {x, y})"
  assume "least L b (Upper L {x', y})"
  with carr
      have leastb: "least L b (Upper L {x, y})"
  LEAST_FP f =

  from leasta leastb
      GREATEST_FP"',b gorder_scheme \ ('a \ 'a) \ 'a" (\GFP\\) where
qed (ule )+

lemma \<open>Dual operators\<close>
  assumes : "x\in carrier L" "y\ carrier L" "y' \ carrier L"
    and  "\<Squ>\<^bsub>inv_gorder L\<^esub>A = \<Sqinter>\<^bsub>L\<^esub>A"( addsup_def )
  shows x\<squnion> y .= x \<squnion> y'"
 (rule, rule joinIbysimp:sup_definf_def
f a b
    " \\<^bsub>inv_gorder L\<^esub> q = p \\<^bsub>L\<^esub> q"
also carr'
      have "{
    "{' }={,y}"by
  finally
      have seq: "{x, p \\<^bsub>inv_gorder L\<^esub> q = p \\<^bsub>L\<^esub> q"

  assume leasta: "least L a (Upper L {x, y})"
  assume "least L b (Upper L {x, y'})"
  with
have"least L ( L {x, y})"
      by( add least_Upper_cong_r _ seq]java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51

  java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
show= b  rule
qed (   simp: GREATEST_FP_def

lemmaGREATEST_FP   LEAST_FP
" \ carrier L ==> least L x (Upper L {x})"
  by java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

lemma   assumessup_of_two_exists
  "x \ carrier L ==> \{x} .= x"
  unfolding sup_def
  by (rule someI2) (auto intro: weak_least_unique weak_lower_semilattice +

 ( weak_partial_order]java.lang.StringIndexOutOfBoundsException: Index 61 out of bounds for length 61
  " \ carrier L \ \{x} \ carrier L"
  unfolding sup_def
  by (rule someI2) (java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

 \<open>Condition on \<open>A\<close>: supremum exists.\<close>

lemma (in( dual_weak_order
  "[| !!.leastL s (pper (insert x A) =>Psjava.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
  least La(UpperA)  \<in> carrier L; A \<subseteq> carrier L |]
  ==> P (java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
proof
assume" \ carrier L" "A \ carrier L"
    andP:"!. L l ( L (insert ) =>Pl"
    and : "least L a ( L A)"
from least_a:" \ carrier L" by simp
  from L sup_of_two_exists least_a sup_of_two_exists  where Uppery)  fast
  obtain s where least_s: "least L s with L show "P ( l. leastUppery}"
 l (Upperinsert x A))
  proof (rule someI2)
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
    proof (rule  "|x
       z
      lemma (in weak_upper_semilattice) join_cong_l
      then "
      proof
            and xx': ""
          by (simp(ule joinI, joinI
      next
        assume "z \ A"
        with L least_s least_a show ?thesis
by(ule_tac le_trans y =a]) (auto: least_Upper_above)
      qed
    next   : "least UpperL{,}"
       y
      assume y:    carr
       "\sqsubseteq y
      proof      by simp:least_Upper_cong_r[   ])
fix
        assume : z \<in> {a, x}"
        then "
        proof
          ave y' " \ Upper L A"
by(eson Upper_antimono in_monosubset_insertI
assume" =a
             "x \ y .= x \ y'"
        next
          assume z\<in> {x}"
           y L show by blast
        qed
 "y,x}{= {' }"by(ntroset_eq_pairI leasta "east L a ( {,}"
    next
      from L show "insert x A \ carrier L" by simp
      from least_s show "east b(Upper L {,y}"
    qed
  qed rule
qed

lemma (in weak_upper_semilattice) finite_sup_least:
  "| finite A;A
proof (induct set: finite " .=b ( weak_least_unique)
case
  then
next
  case (insert x A)
  show  x\<> L =>leastUpperjava.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49

    case True \<in> carrier L ==> \<Squnion>{x} .= x"
with show
      by simp (simp
        *The above is; least_cong make loop
        Would\<
  next
    False
    with insert have "least L (\A) (Upper L A)" by simp
    with _ show
      by (rulejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
  qed[ !.leastUpper x )=>Ps;
qed L a( L A) x 

lemma=>P (<qunion>insert  A)"
assumes!l.least ( x A)=>Pljava.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60
    and xA P:"!. L lUpperL( )=>Pljava.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
shows\<Squnion> (insert x A))"
proof (cases "A = {}")
  case True with P and xA show ?thesis
    by (imp : finite_sup_least
next
  case False with P and xA show ?thesis
    by (simp add:sup_insertI finite_sup_least)
qed

lemma (in weak_upper_semilattice) finite_sup_closed [simp]:
  "[| finite A; A \ carrier L; A \ {} |] ==> \A \ carrier L"
 show "east L s ( L(nsertA)java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
  case empty then showjava.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 35
next
  case insert then show ?caseby (imp : least_Upper_above least_s)
    by - (         L least_s show
qed

lemma       java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
  "[| x \ carrier L; y \ carrier L |] ==> x \ x \ y"
  by (rule joinI (ule [OF], rule Upper_memIjava.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57

lemma (in weak_upper_semilattice)         showz
  "[ y: y
  by (ruleby( Upper_antimono subset_insertI

lemma (in weak_upper_semilattice) sup_of_two_least y'least_a show thesis fastdest east_le)
  "[| x assumez \ {x}"
proof (unfold  with ?thesis
  assume L: "x
  with obtain where "east L s (pperL{x,y) by fast
  with L show "least L (SOME z. least L z (Upper L {x, y})) (Upper L { java.lang.StringIndexOutOfBoundsException: Range [8, 9) out of bounds for length 8
  by (fast
qed

lemma (
  assumes : "x\ z" "y \ z"
    and x: "x "[| finite A; A \ carrier L; A \ {} |] ==> least L (\A) (Upper L A)"
  shows "x \ y \ z"
proof (rule joinI [proof (induct set: finite
  fix s
  assume "least L s (Upper L {x, y})"
  with
qedinsert

lemma ( "A = })
  assumes "x \ carrier L" "y \ carrier L"
  showsx\<sqsubseteq> y \<longleftrightarrow> (x \<squnion> y) .= y"
  by( assms)assms join_le join_rightle_cong_r local.e_refl)
  
lemma (in weak_upper_semilattice      by simp( add [OF] sup_of_singletonI
  assumes L: "x \ carrier L" "y \ carrier L" "z \ carrier L"
  java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
proof insert least
  \<comment> \<open>The textbook argument in Jacobson I, p 457\<close>_ ?thesis
  fix s
  assume sup: "least L s (Upper L {x, y, z})"
  show" \ (y \ z) .= s"
  proof (rule weak_le_antisym)
     sup " (y \ z) \ s"
      by (fastforce intro!: join_le elim: least_Upper_above P: !l    (pper==Pl
next
    from L show 
     (cases " =})
     (blast!: Upper_memI intro:le_trans join_left  join_closed
  qedsimp_all add:L [OF])
qed (simp_all

text \<open>Commutativity holds for \<open>=\<close>.\<close>

java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
  fixes L structure
  shows"|finite A;
  by (unfold join_def) (simp add: insert_commute set finitejava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26

lemma (in weak_upper_semilattice) weak_join_assoc
  assumes "
  shows "(x \ y) \ z .= x \ (y \ z)"
proof -
  (* FIXME: could be simplified by improved simp: uniform use of .=,
     omit [symmetric] in last step. *)

  have "(x \ y) \ z = z \ (x \ y)" by (simp only: join_comm)
  also from L have "... .= \{z, x, y}" by (simp add: weak_join_assoc_lemma)
  also from L lemma (in weak_upper_semilattice) join_right  "[| x \ carrier L; y \ carrier L |] ==> y \ x \ y"
lemma (in weak_upper_semilattice) sup_of_two_least  "[| x \ carrier L; y \ carrier L |] ==> least L (\{x, y}) (Upper L {x, y})"
  finally  assume L: "x \ carrier L" "y \ carrier L"
qed


subsubsection  with L show "least L (SOME z. least by (fast intro: someI2 weak_least_unique) (* blast fails *)

lemma (in weak_upper_semilattice)join_le
"[!!.greatest L i Lower L {,y} ==> P i;
  x \<in> carrier L; y \<in> carrier L |]
  ==> P (x \<sqinter> y)"
proof x: x \<in> carrier L" and y: "y \<in> carrier L" and z: "z \<in> carrier L"
  assume L: "x \ carrier L" "y \ carrier L"
    and "!.greatest Lg ( {,y)=>P "
  withjava.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
  withshow " ( g. greatest Lower L x,y)"
  by (fastjava.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
qed

lemma (nweak_lower_semilattice [simp
  "[ x\ carrier L; y \ carrier L |] ==> x \ y \ carrier L"
  by (rule meetI) (rule greatest_closed)

lemma (in weak_lower_semilattice)lemmainw) weak_join_assoc_lemma
  assumes carr: "x shows "x \ (y \ z) .= \{x, y, z}"
    and xx': "x .= x'"
  shows "x \ y .= x' \ y"
proof (rule meetI, rule
  fix    sup:leastUpper }"
  from xx' carr
      have"{x,y}.= x' y}  rule

  assume greatestaa (  x }java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
  assume "greatest L b (Lower L {x', y})"
  with
      have greatestb: "greatest L
by( add greatest_Lower_cong_r[F__seq]java.lang.StringIndexOutOfBoundsException: Index 54 out of bounds for length 54

  from(last!:Upper_memI:  join_left join_closed
      show =b  rule)
qed (rule carr(imp_all : L)

lemma (
  assumes carr: "x \ carrier L" "y \ carrier L" "y' \ carrier L"
    and join_comm
  shows \<sqinter> y .= x \<sqinter> y'"
 (rule, rule)
     ( join_defsimp : insert_commute
  have "{x, y} = {ylemma (nweak_upper_semilattice) weak_join_assoc:
  also  carr'
         "(x \ y) \ z .= x \ (y \ z)"
  also have "{y', x} = {x, yp -
  finally
      have seq: "{x, y} {.=} {x, y'}"      omit

  assume greatesta  Lhave".=\{z, x, y}" by (simp add: weak_join_assoc_lemma)
  assumealsofrom  ". \{x, y, z}" by (simp add: insert_commute)
  with from L have ". = x \ (y \ z)" by (simp add: weak_join_assoc_lemma [symmetric])
      have greatestb: "greatest L b (Lower L show? by (simp add:Ljava.lang.StringIndexOutOfBoundsException: Range [39, 40) out of bounds for length 39
      by (simp[|!    Lower} =  ;

  from greatesta greatestb
      show=b  ( weak_greatest_unique
qed (rule (unfold inf_def

lemma (inwith obtain where "reatest L i LowerL{,y) fast
  "x\java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
  by(ule) auto

lemma
  "x\ carrier L ==> \{x} .= x"
  unfolding inf_def
java.lang.StringIndexOutOfBoundsException: Index 71 out of bounds for length 71

lemma (in weak_partial_order) inf_of_singleton_closed:
\<in> carrier L ==> \<Sqinter>{x} \<in> carrier L"
  unfolding inf_def
ule someI2 intro)

text

lemma (in weak_lower_semilattice) java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 30
  "[| !!i. xx'carr
  greatest L a (Lower L A); x \<in> carrier L; A \<subseteq> carrier L |] : "{x } {= {' }"by( java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60
== P(\<Sqinter>(insert x A))"
proof inf_def
  ssume 
    andby simp: greatest_Lower_cong_r[F   ])
  from greatestb
  fromL greatest_a: "a carrierL"byjava.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56
  from L inf_of_two_exists in) meet_cong_r
  java.lang.StringIndexOutOfBoundsException: Index 69 out of bounds for length 69
  show "P (SOME g. greatest L "\<sqinter> y .= x \<sqinter> y'"
  proof (ule someI2)
    show "greatest L i (Lower L ab
  have{ y} y " fast
       z
      assume "z \ insert x A"
       "\ z"
      proof "{' x ={x,y} ast
        assume "z = x" then show ?thesis
           simp:  [OF] L La
      next
        assume "z \ A"
withgreatest_a
          by (rule_tacassume"reatest L b ( x,y'}"
      qed       greatestbL b(Lower}"
    next
      fix y
      assume y: "y \ Lower L (insert x A)"
      show "y \ i"
proof greatest_leOF],  Lower_memI)
        fix z
        assume zqed rule)java.lang.StringIndexOutOfBoundsException: Range [16, 17) out of bounds for length 16
        then show "y \ z"
        proof
          have y': "y \ Lower L A"
            by (meson Lower_antimono   ( greatest_LowerI
          assume "z =lemma (in weak_partialorderweak_inf_of_singleton [simp]:
          with y' greatest_a show ?thesis inf_def
        next
          assume" \ {x}"
withshow last
qed
      qed Lower_closed [THEN subsetD, OF y])
    next
fromshow insert
      from greatest_i show "i
qed
  qed (rule P)
qed

lemma (in weak_lower_semilattice) finite_inf_greatest:
  "[ finite A; A \ carrier L; A \ {} |] ==> greatest L (\A) (Lower L A)"
proof induct finitejava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
  case    L:" \ carrier L" "A \ carrier L"
next
     greatest_a   Lower
  show ?case
 proof ( "A = {})
    case True
    with show?java.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
bysimpaddOF
        inf_of_singleton_closed inf_of_singletonI)

    case Falseproof( someI2
from  thesis
    proof (rule_tac inf_insertI)
      fromproof (ule greatest_LowerI
    qed simp_allz\<in> insert x A"
     then show
qed

lemmain) finite_inf_insertI
  assumes P: "!!i. greatest (imp: greatest_Lower_below [OF greatest_i] L La)
     xA"inite " " \ carrier L" "A \ carrier L"
  shows P(<> (nsert
proof (cases "A = {}")
  caseTrue with  and xA thesis
    by (simp
next
       y
 add:  finite_inf_greatest
qedshow

lemma(in) finite_inf_closed]:
  "[ z
nduct: finite)
  casethenshow" \ z"
next
insertshow?
    by (rule_tac finite_inf_insertI) (simp_all)
qed

lemma (in           "z="
  "[| x \ carrier L; y \ carrier L |] ==> x \ y \ x"
  by (rule meetI [folded

lower_semilattice:
  "[| x java.lang.StringIndexOutOfBoundsException: Range [0, 13) out of bounds for length 11
  by (rule meetI

lemma ( weak_lower_semilattice:
  "[| x \ carrier L; y \ carrier L |] ==>
         greatest_i " \ carrier L" by simp
proof    java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
  assume L: "xlemma (in weak_) finite_inf_greatest:
withobtainwhere L s (ower L {,}) byfast
  with
  show "reatest (.greatest L {x, y})))java.lang.StringIndexOutOfBoundsException: Index 76 out of bounds for length 76
show
qed

lemma (in    withshow thesis
  assumes sub: "z \ x" "z \ y"
    and"x \<in> carrier L" and y: "y \<in> carrier L" and z: "z \<in> carrier L"
  shows          inf_of_singletonI
proof False
  fix i
  assume "greatest L i ( insert ?thesis
with sub z  "z \ i" by (fast elim: greatest_le intro: Lower_memI)
qed

lemma  insert "greatest L (\A) (Lower L A)" by simp
  assumes simp_all
  java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
  by (meson assms(1) assms P:"!. greatest L i Lower L (insert x A) =>Pi"
  
lemma (in weak_lower_semilattice) weak_meet_assoc_lemma:
  assumes L: "x \ carrier L" "y \ carrier L" "z \ carrier L"
  shows "x \ (y \ z) .= \{x, y, z}"
proofrule)
  txt \<open>The textbook argument in Jacobson I, p 457\<close>
  fix i
  assume inf: "greatest L i (Lower L {x, y, z})"
  show "x \ (y \ z) .= i"
  proof (rule weak_le_antisym)
by(imp add: finite_inf_greatest)
      by (astforce!:  elim)
  next False  P and show
    frominf "x\ (y \ z) \ i"
    by (erule_tac
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
qedsimp_all greatest_closed)
qed (simp_all induct:finite)

lemma meet_comm:
  fixes L (structure)
  showsjava.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
  bynext

lemma ) meet_left
    "[| x \  L; y \<in> carrier L |] ==> x \<sqinter> y \<sqsubseteq> x"
   "(x
proof -
  (* FIXME: improved simp, see weak_join_assoc above *)
 have ( \<sqinter> y) \<sqinter> z = z \<sqinter> (x \<sqinter> y)" by (simp only: meet_comm)
  also from L    (ule meetI meet_defblast: )
  also from L have (in ) inf_of_two_greatest
  also from L have ".e greatest L (\{x, y}) (Lower L {x, y})"
  finally ?thesis add L)
qed

text \<open>Total orders are lattices.\<close>

   L "\ carrier L" "y \ carrier L"
proof
   x java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
assume:" \ carrier L" "y \ carrier L"
  show "\s. least L s (Upper L {x, y})"
   -
    note total L
    moreover
    {
assume" <> y"
      with L have "least L y (Upper L {x, y})"
        by   subz\sqsubseteq x" " \<sqsubseteq> y"
    }
  shows
    {
      assumey\<sqsubseteq> x"
with " L x (Upper {,y)"
        by (rule_tac least_UpperI   Lower)
    }
  ultimately ?thesis
  qed
next
  fix x y
  assume L: l (inweak_lattice:
  show".greatest L i LowerL{x y)java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
  -
    note total L
lemma weak_lower_semilattice:
    {
mejava.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
      with L have "greatest L yproof( finite_inf_insertI)
         rule_tac) auto
     i
    moreover
    {
      assume "x "
      with    (rule)
        by ( greatest_LowerI
    }
     showby blast
  qed inf "
qed


subsection      (blast intro! Lower_memI intro meet_left meet_closed

locale (imp_all add L)
java.lang.StringIndexOutOfBoundsException: Range [0, 2) out of bounds for length 0
     "x \ y = y \ x"
  weak_partial_order_top
begin

lemma bottom_meet\in L \<Longrightarrow> \<bottom> \<sqinter> x .= \<bottom>"
  by

lemma bottom_join: "x \ carrier L \ \ \ x .= x"
  by (metis join_closed join_right least_def)

 bottom_weak_eq
  "\ b \ carrier L; \ x. x \ carrier L \ b \ x \ \ b .= \"
  by (show "\s. least L s (Upper L {x, y})"

lemma     total
    java.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12

lemma top_meet: "x java.lang.StringIndexOutOfBoundsException: Range [0, 69) out of bounds for length 39
by (etis le_refl meet_closed meet_le meet_right top_higher)

next
     x java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9

end

sublocale weak_bounded_lattice \<subseteq> weak_partial_order ..


subsection \<open>Lattices where \<open>eq\<close> is the Equality\<close>

locale upper_semilattice = partial_order +
  assumes
    "[| x \ carrier L; y \ carrier L |] ==> \s. least L s (Upper L {x, y})"

sublocale upper_semilattice \<subseteq> weak?: weak_upper_semilattice
  by unfold_locales    

locale lower_semilattice =  L xLower}java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49
  assumes inf_of_two_exists:
    "ultimately show ?thesisbyblast

sublocale
  by unfold_locales inf_of_two_exists

locale \<open>Weak Bounded Lattices\<close>

> weak_lattice

lemmain) dual_lattice
  "lattice (inv_gorder L)"
proof -
  interpret dual: weak_lattice
    by (metis dual_weak_lattice)

  show ?thesis
    apply (unfold_locales)
    apply (simp_all add: inf_of_two_exists sup_of_two_exists)
    apply (rule eq_is_equal : "x \ carrier L \ \ \ x .= \"
  done
qed
  
 (n lattice
  assumes   metis join_closed join_right least_def)
  shows "x \ y \ x = (x \ y)"
    "<>b \ carrier L; \ x. x \ carrier L \ b \ x \ \ b .= \"

lemma (in lattice) le_iff_meet:
  assumes top_join:" \ carrier L \ \ \ x .= \"
  shows join_closed top_closed weak_le_antisym
  java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 0

text

sublocale
l top_weak_eq"<>
    
text \<open>Functions that preserve joins and meets\<close>
  
definition join_pres : "a,')gorder_scheme
"join_pres X java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

definition meet_pres :: "('a, 'c) gorder_scheme \ ('b, 'd) gorder_scheme \ ('a \ 'b) \ bool" where
"meet_presjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

lemma join_pres_isotone sup_of_two_exists
assumes \<in> carrier X \<rightarrow> carrier Y" "join_pres X Y f"
  showsX Yf
carrier X. f (x \\<^bsub>X\<^esub> y) = f x \\<^bsub>Y\<^esub> f y)"

definition meet_pres :: "('a, 'c) gorder_scheme \ ('b, 'd) gorder_scheme \ ('a \ 'b) \ bool" where
"meet_pres X Y f \ lattice X \ lattice Y \ (\ x \ carrier X. \ y \ carrier X. f (x \\<^bsub>X\<^esub> y) = f x \\<^bsub>Y\<^esub> f y)"

lemma join_pres_isotone:
  assumes "f \ carrier X \ carrier Y" "join_pres X Y f"
  shows "isotone X Y f"
proof (rule isotoneI)
  show "weak_partial_order X" "weak_partial_order Y"
    using assms unfolding join_pres_def lattice_def upper_semilattice_def lower_semilattice_def
    by (meson partial_order.axioms(1))+
  show "\x y. \x \ carrier X; y \ carrier X; x \\<^bsub>X\<^esub> y\ \ f x \\<^bsub>Y\<^esub> f y"
    by (metis (no_types, lifting) PiE assms join_pres_def lattice.le_iff_meet)
qed

lemma meet_pres_isotone:
  assumes "f \ carrier X \ carrier Y" "meet_pres X Y f"
  shows "isotone X Y f"
proof (rule isotoneI)
  show "weak_partial_order X" "weak_partial_order Y"
    using assms unfolding meet_pres_def lattice_def upper_semilattice_def lower_semilattice_def
    by (meson partial_order.axioms(1))+
  show "\x y. \x \ carrier X; y \ carrier X; x \\<^bsub>X\<^esub> y\ \ f x \\<^bsub>Y\<^esub> f y"
    by (metis (no_types, lifting) PiE assms lattice.le_iff_join meet_pres_def)
qed


subsection \<open>Bounded Lattices\<close>

locale bounded_lattice = 
  lattice + 
  weak_partial_order_bottom + 
  weak_partial_order_top

sublocale bounded_lattice \<subseteq> weak_bounded_lattice ..

context bounded_lattice
begin

lemma bottom_eq:  
  "\ b \ carrier L; \ x. x \ carrier L \ b \ x \ \ b = \"
  by (metis bottom_closed bottom_lower le_antisym)

lemma top_eq:  "\ t \ carrier L; \ x. x \ carrier L \ x \ t \ \ t = \"
  by (metis le_antisym top_closed top_higher)

end

hide_const (open) Lattice.inf
hide_const (open) Lattice.sup

end

98%


¤ Diese beiden folgenden Angebotsgruppen bietet das Unternehmen0.4Angebot  Wie Sie bei der Firma Beratungs- und Dienstleistungen beauftragen können  ¤

*Eine klare Vorstellung vom Zielzustand






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.