theory_file
stringlengths 5
95
| lemma_name
stringlengths 5
255
| lemma_command
stringlengths 17
12k
⌀ | lemma_object
stringlengths 5
38.6k
| template
stringlengths 7
34.2k
| symbols
listlengths 0
85
| types
listlengths 0
85
| defs
listlengths 0
60
| output_key
stringclasses 1
value | input
stringlengths 20
44.8k
| output
stringlengths 22
38.7k
|
|---|---|---|---|---|---|---|---|---|---|---|
Regular_Tree_Relations/Util/FSet_Utils
|
FSet_Utils.ftrancl_map_prod_mono
| null |
map_both ?f |`| ?R|\<^sup>+| |\<subseteq>| (map_both ?f |`| ?R)|\<^sup>+|
|
?H1 (?H2 (?H3 x_1) (?H4 x_2)) (?H5 (?H2 (?H3 x_1) x_2))
|
[
"FSet_Utils.ftrancl",
"Term_Context.map_both",
"FSet.fimage",
"FSet.fsubset_eq"
] |
[
"('a \\<times> 'a) fset \\<Rightarrow> ('a \\<times> 'a) fset",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<times> 'a \\<Rightarrow> 'b \\<times> 'b",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a fset \\<Rightarrow> 'b fset",
"'a fset \\<Rightarrow> 'a fset \\<Rightarrow> bool"
] |
[
"abbreviation fsubset_eq :: \"'a fset \\<Rightarrow> 'a fset \\<Rightarrow> bool\" (infix \"|\\<subseteq>|\" 50) where \"xs |\\<subseteq>| ys \\<equiv> xs \\<le> ys\""
] |
lemma_object
|
###symbols
FSet_Utils.ftrancl :::: ('a \<times> 'a) fset \<Rightarrow> ('a \<times> 'a) fset
Term_Context.map_both :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a \<times> 'a \<Rightarrow> 'b \<times> 'b
FSet.fimage :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a fset \<Rightarrow> 'b fset
FSet.fsubset_eq :::: 'a fset \<Rightarrow> 'a fset \<Rightarrow> bool
###defs
abbreviation fsubset_eq :: "'a fset \<Rightarrow> 'a fset \<Rightarrow> bool" (infix "|\<subseteq>|" 50) where "xs |\<subseteq>| ys \<equiv> xs \<le> ys"
|
###output
map_both ?f |`| ?R|\<^sup>+| |\<subseteq>| (map_both ?f |`| ?R)|\<^sup>+|###end
|
CoCon/Discussion_Confidentiality/Discussion_NCPC
|
Discussion_NCPC.iaction_mono
| null |
iaction ?\<Delta> ?s ?vl ?s1.0 ?vl1.0 \<Longrightarrow> (\<And>s vl s1 vl1. ?\<Delta> s vl s1 vl1 \<Longrightarrow> ?\<Delta>' s vl s1 vl1) \<Longrightarrow> iaction ?\<Delta>' ?s ?vl ?s1.0 ?vl1.0
|
\<lbrakk> ?H1 x_1 x_2 x_3 x_4 x_5; \<And>y_0 y_1 y_2 y_3. x_1 y_0 y_1 y_2 y_3 \<Longrightarrow> x_6 y_0 y_1 y_2 y_3\<rbrakk> \<Longrightarrow> ?H1 x_6 x_2 x_3 x_4 x_5
|
[
"Discussion_NCPC.iaction"
] |
[
"('a \\<Rightarrow> 'b \\<Rightarrow> state \\<Rightarrow> String.literal list \\<Rightarrow> bool) \\<Rightarrow> 'a \\<Rightarrow> 'b \\<Rightarrow> state \\<Rightarrow> String.literal list \\<Rightarrow> bool"
] |
[] |
lemma_object
|
###symbols
Discussion_NCPC.iaction :::: ('a \<Rightarrow> 'b \<Rightarrow> state \<Rightarrow> String.literal list \<Rightarrow> bool) \<Rightarrow> 'a \<Rightarrow> 'b \<Rightarrow> state \<Rightarrow> String.literal list \<Rightarrow> bool
###defs
|
###output
iaction ?\<Delta> ?s ?vl ?s1.0 ?vl1.0 \<Longrightarrow> (\<And>s vl s1 vl1. ?\<Delta> s vl s1 vl1 \<Longrightarrow> ?\<Delta>' s vl s1 vl1) \<Longrightarrow> iaction ?\<Delta>' ?s ?vl ?s1.0 ?vl1.0###end
|
Combinatorial_Q_Analogues/Q_Pochhammer_Infinite
|
Q_Pochhammer_Infinite.has_prod_euler_phi
|
lemma has_prod_euler_phi:
"norm q < 1 \<Longrightarrow> (\<lambda>n. 1 - q ^ Suc n) has_prod euler_phi q"
|
norm ?q < 1 \<Longrightarrow> (\<lambda>n. (1:: ?'a) - ?q ^ Suc n) has_prod euler_phi ?q
|
?H1 x_1 < ?H2 \<Longrightarrow> ?H3 (\<lambda>y_0. ?H4 ?H5 (?H6 x_1 (?H7 y_0))) (?H8 x_1)
|
[
"Q_Pochhammer_Infinite.euler_phi",
"Nat.Suc",
"Power.power_class.power",
"Groups.minus_class.minus",
"Infinite_Products.has_prod",
"Groups.one_class.one",
"Real_Vector_Spaces.norm_class.norm"
] |
[
"'a \\<Rightarrow> 'a",
"nat \\<Rightarrow> nat",
"'a \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"(nat \\<Rightarrow> 'a) \\<Rightarrow> 'a \\<Rightarrow> bool",
"'a",
"'a \\<Rightarrow> real"
] |
[
"definition euler_phi :: \"'a :: {real_normed_field, banach, heine_borel} \\<Rightarrow> 'a\" where\n \"euler_phi q = qpochhammer_inf q q\"",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"primrec power :: \"'a \\<Rightarrow> nat \\<Rightarrow> 'a\" (infixr \"^\" 80)\n where\n power_0: \"a ^ 0 = 1\"\n | power_Suc: \"a ^ Suc n = a * a ^ n\"",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"class one =\n fixes one :: 'a (\"1\")",
"class norm =\n fixes norm :: \"'a \\<Rightarrow> real\""
] |
lemma_object
|
###symbols
Q_Pochhammer_Infinite.euler_phi :::: 'a \<Rightarrow> 'a
Nat.Suc :::: nat \<Rightarrow> nat
Power.power_class.power :::: 'a \<Rightarrow> nat \<Rightarrow> 'a
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Infinite_Products.has_prod :::: (nat \<Rightarrow> 'a) \<Rightarrow> 'a \<Rightarrow> bool
Groups.one_class.one :::: 'a
Real_Vector_Spaces.norm_class.norm :::: 'a \<Rightarrow> real
###defs
definition euler_phi :: "'a :: {real_normed_field, banach, heine_borel} \<Rightarrow> 'a" where
"euler_phi q = qpochhammer_inf q q"
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
primrec power :: "'a \<Rightarrow> nat \<Rightarrow> 'a" (infixr "^" 80)
where
power_0: "a ^ 0 = 1"
| power_Suc: "a ^ Suc n = a * a ^ n"
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
class one =
fixes one :: 'a ("1")
class norm =
fixes norm :: "'a \<Rightarrow> real"
|
###output
norm ?q < 1 \<Longrightarrow> (\<lambda>n. (1:: ?'a) - ?q ^ Suc n) has_prod euler_phi ?q###end
|
Virtual_Substitution/ExecutiblePolyProps
|
ExecutiblePolyProps.const_lookup_suc
|
lemma const_lookup_suc : "isolate_variable_sparse (Const p :: real mpoly) x (Suc i) = 0"
|
isolate_variable_sparse (Const ?p) ?x (Suc ?i) = 0
|
?H1 (?H2 x_1) x_2 (?H3 x_3) = ?H4
|
[
"Groups.zero_class.zero",
"Nat.Suc",
"MPoly_Type.Const",
"MPolyExtension.isolate_variable_sparse"
] |
[
"'a",
"nat \\<Rightarrow> nat",
"'a \\<Rightarrow> 'a mpoly",
"'a mpoly \\<Rightarrow> nat \\<Rightarrow> nat \\<Rightarrow> 'a mpoly"
] |
[
"class zero =\n fixes zero :: 'a (\"0\")",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\""
] |
lemma_object
|
###symbols
Groups.zero_class.zero :::: 'a
Nat.Suc :::: nat \<Rightarrow> nat
MPoly_Type.Const :::: 'a \<Rightarrow> 'a mpoly
MPolyExtension.isolate_variable_sparse :::: 'a mpoly \<Rightarrow> nat \<Rightarrow> nat \<Rightarrow> 'a mpoly
###defs
class zero =
fixes zero :: 'a ("0")
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
|
###output
isolate_variable_sparse (Const ?p) ?x (Suc ?i) = 0###end
|
Refine_Imperative_HOL/Sepref_Rules
|
Sepref_Rules.fref_PRE_D1
|
lemma fref_PRE_D1:
assumes "(f,h) \<in> fref (comp_PRE S1 Q (\<lambda>x _. P x) X) R S"
shows "(f,h) \<in> fref (\<lambda>x. Q x \<and> P x) R S"
|
(?f, ?h) \<in> [comp_PRE ?S1.0 ?Q (\<lambda>x _. ?P x) ?X]\<^sub>f ?R \<rightarrow> ?S \<Longrightarrow> (?f, ?h) \<in> [\<lambda>x. ?Q x \<and> ?P x]\<^sub>f ?R \<rightarrow> ?S
|
(x_1, x_2) \<in> ?H1 (?H2 x_3 x_4 (\<lambda>y_0 y_1. x_5 y_0) x_6) x_7 x_8 \<Longrightarrow> (x_1, x_2) \<in> ?H1 (\<lambda>y_2. x_4 y_2 \<and> x_5 y_2) x_7 x_8
|
[
"Sepref_Rules.comp_PRE",
"Sepref_Rules.fref"
] |
[
"('a \\<times> 'b) set \\<Rightarrow> ('b \\<Rightarrow> bool) \\<Rightarrow> ('b \\<Rightarrow> 'a \\<Rightarrow> bool) \\<Rightarrow> ('b \\<Rightarrow> bool) \\<Rightarrow> 'b \\<Rightarrow> bool",
"('a \\<Rightarrow> bool) \\<Rightarrow> ('b \\<times> 'a) set \\<Rightarrow> ('c \\<times> 'd) set \\<Rightarrow> (('b \\<Rightarrow> 'c) \\<times> ('a \\<Rightarrow> 'd)) set"
] |
[
"definition \"comp_PRE R P Q S \\<equiv> \\<lambda>x. S x \\<longrightarrow> (P x \\<and> (\\<forall>y. (y,x)\\<in>R \\<longrightarrow> Q x y))\"",
"definition fref :: \"('c \\<Rightarrow> bool) \\<Rightarrow> ('a \\<times> 'c) set \\<Rightarrow> ('b \\<times> 'd) set\n \\<Rightarrow> (('a \\<Rightarrow> 'b) \\<times> ('c \\<Rightarrow> 'd)) set\"\n (\"[_]\\<^sub>f _ \\<rightarrow> _\" [0,60,60] 60) \n where \"[P]\\<^sub>f R \\<rightarrow> S \\<equiv> {(f,g). \\<forall>x y. P y \\<and> (x,y)\\<in>R \\<longrightarrow> (f x, g y)\\<in>S}\""
] |
lemma_object
|
###symbols
Sepref_Rules.comp_PRE :::: ('a \<times> 'b) set \<Rightarrow> ('b \<Rightarrow> bool) \<Rightarrow> ('b \<Rightarrow> 'a \<Rightarrow> bool) \<Rightarrow> ('b \<Rightarrow> bool) \<Rightarrow> 'b \<Rightarrow> bool
Sepref_Rules.fref :::: ('a \<Rightarrow> bool) \<Rightarrow> ('b \<times> 'a) set \<Rightarrow> ('c \<times> 'd) set \<Rightarrow> (('b \<Rightarrow> 'c) \<times> ('a \<Rightarrow> 'd)) set
###defs
definition "comp_PRE R P Q S \<equiv> \<lambda>x. S x \<longrightarrow> (P x \<and> (\<forall>y. (y,x)\<in>R \<longrightarrow> Q x y))"
definition fref :: "('c \<Rightarrow> bool) \<Rightarrow> ('a \<times> 'c) set \<Rightarrow> ('b \<times> 'd) set
\<Rightarrow> (('a \<Rightarrow> 'b) \<times> ('c \<Rightarrow> 'd)) set"
("[_]\<^sub>f _ \<rightarrow> _" [0,60,60] 60)
where "[P]\<^sub>f R \<rightarrow> S \<equiv> {(f,g). \<forall>x y. P y \<and> (x,y)\<in>R \<longrightarrow> (f x, g y)\<in>S}"
|
###output
(?f, ?h) \<in> [comp_PRE ?S1.0 ?Q (\<lambda>x _. ?P x) ?X]\<^sub>f ?R \<rightarrow> ?S \<Longrightarrow> (?f, ?h) \<in> [\<lambda>x. ?Q x \<and> ?P x]\<^sub>f ?R \<rightarrow> ?S###end
|
Sort_Encodings/M
|
Map.fun_upd_restrict
| null |
(?m |` ?D)(?x := ?y) = (?m |` (?D - { ?x}))(?x := ?y)
|
?H1 (?H2 x_1 x_2) x_3 x_4 = ?H1 (?H2 x_1 (?H3 x_2 (?H4 x_3 ?H5))) x_3 x_4
|
[
"Set.empty",
"Set.insert",
"Groups.minus_class.minus",
"Map.restrict_map",
"Fun.fun_upd"
] |
[
"'a set",
"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"('a \\<Rightarrow> 'b option) \\<Rightarrow> 'a set \\<Rightarrow> 'a \\<Rightarrow> 'b option",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> 'b \\<Rightarrow> 'a \\<Rightarrow> 'b"
] |
[
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"definition insert :: \"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set\"\n where insert_compr: \"insert a B = {x. x = a \\<or> x \\<in> B}\"",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"definition\n restrict_map :: \"('a \\<rightharpoonup> 'b) \\<Rightarrow> 'a set \\<Rightarrow> ('a \\<rightharpoonup> 'b)\" (infixl \"|`\" 110) where\n \"m|`A = (\\<lambda>x. if x \\<in> A then m x else None)\"",
"definition fun_upd :: \"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> 'b \\<Rightarrow> ('a \\<Rightarrow> 'b)\"\n where \"fun_upd f a b = (\\<lambda>x. if x = a then b else f x)\""
] |
lemma_object
|
###symbols
Set.empty :::: 'a set
Set.insert :::: 'a \<Rightarrow> 'a set \<Rightarrow> 'a set
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Map.restrict_map :::: ('a \<Rightarrow> 'b option) \<Rightarrow> 'a set \<Rightarrow> 'a \<Rightarrow> 'b option
Fun.fun_upd :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> 'b \<Rightarrow> 'a \<Rightarrow> 'b
###defs
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
definition insert :: "'a \<Rightarrow> 'a set \<Rightarrow> 'a set"
where insert_compr: "insert a B = {x. x = a \<or> x \<in> B}"
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
definition
restrict_map :: "('a \<rightharpoonup> 'b) \<Rightarrow> 'a set \<Rightarrow> ('a \<rightharpoonup> 'b)" (infixl "|`" 110) where
"m|`A = (\<lambda>x. if x \<in> A then m x else None)"
definition fun_upd :: "('a \<Rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> 'b \<Rightarrow> ('a \<Rightarrow> 'b)"
where "fun_upd f a b = (\<lambda>x. if x = a then b else f x)"
|
###output
(?m |` ?D)(?x := ?y) = (?m |` (?D - { ?x}))(?x := ?y)###end
|
pGCL/Healthiness
|
Healthiness.lfp_loop_greatest
|
lemma lfp_loop_greatest:
fixes P::"'s expect"
assumes lb: "\<And>R. \<lambda>s. \<guillemotleft>G\<guillemotright> s * wp body R s + \<guillemotleft>\<N> G\<guillemotright> s * P s \<tturnstile> R \<Longrightarrow> sound R \<Longrightarrow> Q \<tturnstile> R"
and hb: "healthy (wp body)"
and sP: "sound P"
and sQ: "sound Q"
shows "Q \<tturnstile> lfp_exp (\<lambda>Q s. \<guillemotleft>G\<guillemotright> s * wp body Q s + \<guillemotleft>\<N> G\<guillemotright> s * P s)"
|
(\<And>R. \<lambda>s. \<guillemotleft> ?G \<guillemotright> s * wp ?body R s + \<guillemotleft> \<N> ?G \<guillemotright> s * ?P s \<tturnstile> R \<Longrightarrow> sound R \<Longrightarrow> ?Q \<tturnstile> R) \<Longrightarrow> healthy (wp ?body) \<Longrightarrow> sound ?P \<Longrightarrow> sound ?Q \<Longrightarrow> ?Q \<tturnstile> lfp_exp (\<lambda>Q s. \<guillemotleft> ?G \<guillemotright> s * wp ?body Q s + \<guillemotleft> \<N> ?G \<guillemotright> s * ?P s)
|
\<lbrakk>\<And>y_0. \<lbrakk> ?H1 (\<lambda>y_1. ?H2 (?H3 (?H4 x_1 y_1) (?H5 x_2 y_0 y_1)) (?H3 (?H4 (?H6 x_1) y_1) (x_3 y_1))) y_0; ?H7 y_0\<rbrakk> \<Longrightarrow> ?H1 x_4 y_0; ?H8 (?H5 x_2); ?H7 x_3; ?H7 x_4\<rbrakk> \<Longrightarrow> ?H1 x_4 (?H9 (\<lambda>y_2 y_3. ?H2 (?H3 (?H4 x_1 y_3) (?H5 x_2 y_2 y_3)) (?H3 (?H4 (?H6 x_1) y_3) (x_3 y_3))))
|
[
"Induction.lfp_exp",
"Transformers.healthy",
"Expectations.sound",
"Expectations.negate",
"Embedding.wp",
"Expectations.embed_bool",
"Groups.times_class.times",
"Groups.plus_class.plus",
"Expectations.entails"
] |
[
"(('a \\<Rightarrow> real) \\<Rightarrow> 'a \\<Rightarrow> real) \\<Rightarrow> 'a \\<Rightarrow> real",
"(('a \\<Rightarrow> real) \\<Rightarrow> 'a \\<Rightarrow> real) \\<Rightarrow> bool",
"('a \\<Rightarrow> real) \\<Rightarrow> bool",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a \\<Rightarrow> bool",
"(bool \\<Rightarrow> ('a \\<Rightarrow> real) \\<Rightarrow> 'a \\<Rightarrow> real) \\<Rightarrow> ('a \\<Rightarrow> real) \\<Rightarrow> 'a \\<Rightarrow> real",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a \\<Rightarrow> real",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"('a \\<Rightarrow> real) \\<Rightarrow> ('a \\<Rightarrow> real) \\<Rightarrow> bool"
] |
[
"definition lfp_exp :: \"'s trans \\<Rightarrow> 's expect\"\nwhere \"lfp_exp t = Inf_exp {P. sound P \\<and> t P \\<le> P}\"",
"definition\n healthy :: \"(('s \\<Rightarrow> real) \\<Rightarrow> ('s \\<Rightarrow> real)) \\<Rightarrow> bool\"\nwhere\n \"healthy t \\<longleftrightarrow> feasible t \\<and> mono_trans t \\<and> scaling t\"",
"definition sound :: \"('s \\<Rightarrow> real) \\<Rightarrow> bool\"\nwhere \"sound P \\<equiv> bounded P \\<and> nneg P\"",
"definition negate :: \"('s \\<Rightarrow> bool) \\<Rightarrow> 's \\<Rightarrow> bool\" (\"\\<N>\")\nwhere \"negate P = (\\<lambda>s. \\<not> P s)\"",
"definition\n wp :: \"'s prog \\<Rightarrow> 's trans\"\nwhere\n \"wp pr \\<equiv> pr True\"",
"definition\n embed_bool :: \"('s \\<Rightarrow> bool) \\<Rightarrow> 's \\<Rightarrow> real\" (\"\\<guillemotleft> _ \\<guillemotright>\" 1000)\nwhere\n \"\\<guillemotleft>P\\<guillemotright> \\<equiv> (\\<lambda>s. if P s then 1 else 0)\"",
"class times =\n fixes times :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"*\" 70)",
"class plus =\n fixes plus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"+\" 65)",
"abbreviation entails :: \"('s \\<Rightarrow> real) \\<Rightarrow> ('s \\<Rightarrow> real) \\<Rightarrow> bool\" (\"_ \\<tturnstile> _\" 50)\nwhere \"P \\<tturnstile> Q \\<equiv> P \\<le> Q\""
] |
lemma_object
|
###symbols
Induction.lfp_exp :::: (('a \<Rightarrow> real) \<Rightarrow> 'a \<Rightarrow> real) \<Rightarrow> 'a \<Rightarrow> real
Transformers.healthy :::: (('a \<Rightarrow> real) \<Rightarrow> 'a \<Rightarrow> real) \<Rightarrow> bool
Expectations.sound :::: ('a \<Rightarrow> real) \<Rightarrow> bool
Expectations.negate :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a \<Rightarrow> bool
Embedding.wp :::: (bool \<Rightarrow> ('a \<Rightarrow> real) \<Rightarrow> 'a \<Rightarrow> real) \<Rightarrow> ('a \<Rightarrow> real) \<Rightarrow> 'a \<Rightarrow> real
Expectations.embed_bool :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a \<Rightarrow> real
Groups.times_class.times :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Groups.plus_class.plus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Expectations.entails :::: ('a \<Rightarrow> real) \<Rightarrow> ('a \<Rightarrow> real) \<Rightarrow> bool
###defs
definition lfp_exp :: "'s trans \<Rightarrow> 's expect"
where "lfp_exp t = Inf_exp {P. sound P \<and> t P \<le> P}"
definition
healthy :: "(('s \<Rightarrow> real) \<Rightarrow> ('s \<Rightarrow> real)) \<Rightarrow> bool"
where
"healthy t \<longleftrightarrow> feasible t \<and> mono_trans t \<and> scaling t"
definition sound :: "('s \<Rightarrow> real) \<Rightarrow> bool"
where "sound P \<equiv> bounded P \<and> nneg P"
definition negate :: "('s \<Rightarrow> bool) \<Rightarrow> 's \<Rightarrow> bool" ("\<N>")
where "negate P = (\<lambda>s. \<not> P s)"
definition
wp :: "'s prog \<Rightarrow> 's trans"
where
"wp pr \<equiv> pr True"
definition
embed_bool :: "('s \<Rightarrow> bool) \<Rightarrow> 's \<Rightarrow> real" ("\<guillemotleft> _ \<guillemotright>" 1000)
where
"\<guillemotleft>P\<guillemotright> \<equiv> (\<lambda>s. if P s then 1 else 0)"
class times =
fixes times :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "*" 70)
class plus =
fixes plus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "+" 65)
abbreviation entails :: "('s \<Rightarrow> real) \<Rightarrow> ('s \<Rightarrow> real) \<Rightarrow> bool" ("_ \<tturnstile> _" 50)
where "P \<tturnstile> Q \<equiv> P \<le> Q"
|
###output
(\<And>R. \<lambda>s. \<guillemotleft> ?G \<guillemotright> s * wp ?body R s + \<guillemotleft> \<N> ?G \<guillemotright> s * ?P s \<tturnstile> R \<Longrightarrow> sound R \<Longrightarrow> ?Q \<tturnstile> R) \<Longrightarrow> healthy (wp ?body) \<Longrightarrow> sound ?P \<Longrightarrow> sound ?Q \<Longrightarrow> ?Q \<tturnstile> lfp_exp (\<lambda>Q s. \<guillemotleft> ?G \<guillemotright> s * wp ?body Q s + \<guillemotleft> \<N> ?G \<guillemotright> s * ?P s)###end
|
Grothendieck_Schemes/Topological_Space
|
Topological_Spaces.tendsto_within_subset
| null |
filterlim ?f ?l (at ?x within ?S) \<Longrightarrow> ?T \<subseteq> ?S \<Longrightarrow> filterlim ?f ?l (at ?x within ?T)
|
\<lbrakk> ?H1 x_1 x_2 (?H2 x_3 x_4); ?H3 x_5 x_4\<rbrakk> \<Longrightarrow> ?H1 x_1 x_2 (?H2 x_3 x_5)
|
[
"Set.subset_eq",
"Topological_Spaces.topological_space_class.at_within",
"Filter.filterlim"
] |
[
"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool",
"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a filter",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'b filter \\<Rightarrow> 'a filter \\<Rightarrow> bool"
] |
[
"abbreviation subset_eq :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool\"\n where \"subset_eq \\<equiv> less_eq\"",
"class topological_space = \"open\" +\n assumes open_UNIV [simp, intro]: \"open UNIV\"\n assumes open_Int [intro]: \"open S \\<Longrightarrow> open T \\<Longrightarrow> open (S \\<inter> T)\"\n assumes open_Union [intro]: \"\\<forall>S\\<in>K. open S \\<Longrightarrow> open (\\<Union>K)\"\nbegin",
"definition filterlim :: \"('a \\<Rightarrow> 'b) \\<Rightarrow> 'b filter \\<Rightarrow> 'a filter \\<Rightarrow> bool\" where\n \"filterlim f F2 F1 \\<longleftrightarrow> filtermap f F1 \\<le> F2\""
] |
lemma_object
|
###symbols
Set.subset_eq :::: 'a set \<Rightarrow> 'a set \<Rightarrow> bool
Topological_Spaces.topological_space_class.at_within :::: 'a \<Rightarrow> 'a set \<Rightarrow> 'a filter
Filter.filterlim :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'b filter \<Rightarrow> 'a filter \<Rightarrow> bool
###defs
abbreviation subset_eq :: "'a set \<Rightarrow> 'a set \<Rightarrow> bool"
where "subset_eq \<equiv> less_eq"
class topological_space = "open" +
assumes open_UNIV [simp, intro]: "open UNIV"
assumes open_Int [intro]: "open S \<Longrightarrow> open T \<Longrightarrow> open (S \<inter> T)"
assumes open_Union [intro]: "\<forall>S\<in>K. open S \<Longrightarrow> open (\<Union>K)"
begin
definition filterlim :: "('a \<Rightarrow> 'b) \<Rightarrow> 'b filter \<Rightarrow> 'a filter \<Rightarrow> bool" where
"filterlim f F2 F1 \<longleftrightarrow> filtermap f F1 \<le> F2"
|
###output
filterlim ?f ?l (at ?x within ?S) \<Longrightarrow> ?T \<subseteq> ?S \<Longrightarrow> filterlim ?f ?l (at ?x within ?T)###end
|
SIFPL/HuntSands
|
HuntSands.Sec2
|
lemma Sec2:
"(p,G,c,H):HS \<Longrightarrow>
(\<exists> \<Phi> . \<Turnstile> c : (Sec (Q p H) (EQ G q) (EQ H q) \<Phi>))"
|
(?p, ?G, ?c, ?H) \<in> HS \<Longrightarrow> \<exists>\<Phi>. \<Turnstile> ?c : Sec (Q ?p ?H) (EQ ?G ?q) (EQ ?H ?q) \<Phi>
|
(x_1, x_2, x_3, x_4) \<in> ?H1 \<Longrightarrow> \<exists>y_0. ?H2 x_3 (?H3 (?H4 x_1 x_4) (?H5 x_2 x_5) (?H5 x_4 x_5) y_0)
|
[
"HuntSands.EQ",
"HuntSands.Q",
"HuntSands.Sec",
"VDM.VDM_valid",
"HuntSands.HS"
] |
[
"(Var \\<Rightarrow> L) \\<Rightarrow> L \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool",
"L \\<Rightarrow> (Var \\<Rightarrow> L) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool",
"((Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool) \\<Rightarrow> ((Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool) \\<Rightarrow> ((Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool) \\<Rightarrow> ((Var \\<Rightarrow> Val) \\<times> (Var \\<Rightarrow> Val) \\<Rightarrow> bool) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool",
"IMP \\<Rightarrow> ((Var \\<Rightarrow> Val) \\<Rightarrow> (Var \\<Rightarrow> Val) \\<Rightarrow> bool) \\<Rightarrow> bool",
"(L \\<times> (Var \\<Rightarrow> L) \\<times> IMP \\<times> (Var \\<Rightarrow> L)) set"
] |
[
"definition EQ:: \"CONTEXT \\<Rightarrow> L \\<Rightarrow> State \\<Rightarrow> State \\<Rightarrow> bool\"\nwhere \"EQ G p = (\\<lambda> s t . \\<forall> x . LEQ (G x) p \\<longrightarrow> s x = t x)\"",
"definition Q::\"L \\<Rightarrow> CONTEXT \\<Rightarrow> VDMAssn\"\nwhere \"Q p H = (\\<lambda> s t . \\<forall> x . (\\<not> LEQ p (H x)) \\<longrightarrow> t x = s x)\"",
"definition Sec :: \"VDMAssn \\<Rightarrow> (State \\<Rightarrow> State \\<Rightarrow> bool) \\<Rightarrow>\n (State \\<Rightarrow> State \\<Rightarrow> bool) \\<Rightarrow> TT \\<Rightarrow> VDMAssn\"\nwhere \"Sec A R S \\<Phi> s t = (A s t \\<and>\n (\\<forall> r . R s r \\<longrightarrow> \\<Phi>(t,r)) \\<and> (\\<forall> r . \\<Phi>(r,s) \\<longrightarrow> S r t))\"",
"definition VDM_valid :: \"IMP \\<Rightarrow> VDMAssn \\<Rightarrow> bool\"\n (\" \\<Turnstile> _ : _ \" [100,100] 100)\nwhere \"\\<Turnstile> c : A = (\\<forall> s t . (s,c \\<Down> t) \\<longrightarrow> A s t)\"",
"inductive_set HS::\"(L \\<times> CONTEXT \\<times> IMP \\<times> CONTEXT) set\"\nwhere\nHS_Skip: \"(p,G,Skip,G):HS\"\n\n| HS_Assign:\n \"(G,e,t):HS_E \\<Longrightarrow> (p,G,Assign x e,upd G x (LUB p t)):HS\"\n\n| HS_Seq:\n \"\\<lbrakk>(p,G,c,K):HS; (p,K,d,H):HS\\<rbrakk> \\<Longrightarrow> (p,G, Comp c d,H):HS\"\n\n| HS_If:\n \"\\<lbrakk>(G,b,t):HS_B; (LUB p t,G,c,H):HS; (LUB p t,G,d,H):HS\\<rbrakk> \\<Longrightarrow>\n (p,G,Iff b c d,H):HS\"\n\n| HS_If_alg:\n \"\\<lbrakk>(G,b,p):HS_B; (p,G,c,H):HS; (p,G,d,H):HS\\<rbrakk> \\<Longrightarrow>\n (p,G,Iff b c d,H):HS\"\n\n| HS_While:\n \"\\<lbrakk>(G,b,t):HS_B; (LUB p t,G,c,H):HS;H=G\\<rbrakk> \\<Longrightarrow>\n (p,G,While b c,H):HS\"\n\n| HS_Sub:\n \"\\<lbrakk> (pp,GG,c,HH):HS; LEQ p pp; \\<forall> x . LEQ (G x) (GG x); \n \\<forall> x . LEQ (HH x) (H x)\\<rbrakk> \\<Longrightarrow>\n (p,G,c,H):HS\""
] |
lemma_object
|
###symbols
HuntSands.EQ :::: (Var \<Rightarrow> L) \<Rightarrow> L \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool
HuntSands.Q :::: L \<Rightarrow> (Var \<Rightarrow> L) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool
HuntSands.Sec :::: ((Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool) \<Rightarrow> ((Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool) \<Rightarrow> ((Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool) \<Rightarrow> ((Var \<Rightarrow> Val) \<times> (Var \<Rightarrow> Val) \<Rightarrow> bool) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool
VDM.VDM_valid :::: IMP \<Rightarrow> ((Var \<Rightarrow> Val) \<Rightarrow> (Var \<Rightarrow> Val) \<Rightarrow> bool) \<Rightarrow> bool
HuntSands.HS :::: (L \<times> (Var \<Rightarrow> L) \<times> IMP \<times> (Var \<Rightarrow> L)) set
###defs
definition EQ:: "CONTEXT \<Rightarrow> L \<Rightarrow> State \<Rightarrow> State \<Rightarrow> bool"
where "EQ G p = (\<lambda> s t . \<forall> x . LEQ (G x) p \<longrightarrow> s x = t x)"
definition Q::"L \<Rightarrow> CONTEXT \<Rightarrow> VDMAssn"
where "Q p H = (\<lambda> s t . \<forall> x . (\<not> LEQ p (H x)) \<longrightarrow> t x = s x)"
definition Sec :: "VDMAssn \<Rightarrow> (State \<Rightarrow> State \<Rightarrow> bool) \<Rightarrow>
(State \<Rightarrow> State \<Rightarrow> bool) \<Rightarrow> TT \<Rightarrow> VDMAssn"
where "Sec A R S \<Phi> s t = (A s t \<and>
(\<forall> r . R s r \<longrightarrow> \<Phi>(t,r)) \<and> (\<forall> r . \<Phi>(r,s) \<longrightarrow> S r t))"
definition VDM_valid :: "IMP \<Rightarrow> VDMAssn \<Rightarrow> bool"
(" \<Turnstile> _ : _ " [100,100] 100)
where "\<Turnstile> c : A = (\<forall> s t . (s,c \<Down> t) \<longrightarrow> A s t)"
inductive_set HS::"(L \<times> CONTEXT \<times> IMP \<times> CONTEXT) set"
where
HS_Skip: "(p,G,Skip,G):HS"
| HS_Assign:
"(G,e,t):HS_E \<Longrightarrow> (p,G,Assign x e,upd G x (LUB p t)):HS"
| HS_Seq:
"\<lbrakk>(p,G,c,K):HS; (p,K,d,H):HS\<rbrakk> \<Longrightarrow> (p,G, Comp c d,H):HS"
| HS_If:
"\<lbrakk>(G,b,t):HS_B; (LUB p t,G,c,H):HS; (LUB p t,G,d,H):HS\<rbrakk> \<Longrightarrow>
(p,G,Iff b c d,H):HS"
| HS_If_alg:
"\<lbrakk>(G,b,p):HS_B; (p,G,c,H):HS; (p,G,d,H):HS\<rbrakk> \<Longrightarrow>
(p,G,Iff b c d,H):HS"
| HS_While:
"\<lbrakk>(G,b,t):HS_B; (LUB p t,G,c,H):HS;H=G\<rbrakk> \<Longrightarrow>
(p,G,While b c,H):HS"
| HS_Sub:
"\<lbrakk> (pp,GG,c,HH):HS; LEQ p pp; \<forall> x . LEQ (G x) (GG x);
\<forall> x . LEQ (HH x) (H x)\<rbrakk> \<Longrightarrow>
(p,G,c,H):HS"
|
###output
(?p, ?G, ?c, ?H) \<in> HS \<Longrightarrow> \<exists>\<Phi>. \<Turnstile> ?c : Sec (Q ?p ?H) (EQ ?G ?q) (EQ ?H ?q) \<Phi>###end
|
UTP/utp/utp
|
utp_var.pr_var_vwb_lens
| null |
vwb_lens ?x \<Longrightarrow> vwb_lens (& ?x)
|
?H1 x_1 \<Longrightarrow> ?H1 (?H2 x_1)
|
[
"utp_var.pr_var",
"Lens_Laws.vwb_lens"
] |
[
"('a \\<Longrightarrow> 'b) \\<Rightarrow> 'a \\<Longrightarrow> 'b",
"('a \\<Longrightarrow> 'b) \\<Rightarrow> bool"
] |
[] |
lemma_object
|
###symbols
utp_var.pr_var :::: ('a \<Longrightarrow> 'b) \<Rightarrow> 'a \<Longrightarrow> 'b
Lens_Laws.vwb_lens :::: ('a \<Longrightarrow> 'b) \<Rightarrow> bool
###defs
|
###output
vwb_lens ?x \<Longrightarrow> vwb_lens (& ?x)###end
|
Stateful_Protocol_Composition_and_Typing/Labeled_Stateful_Strands
|
Labeled_Stateful_Strands.trms\<^sub>s\<^sub>s\<^sub>t_unlabel_dual_subst_cons
| null |
trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t (dual\<^sub>l\<^sub>s\<^sub>s\<^sub>t (?a # ?A \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<sigma>)) = trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (snd ?a \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p ?\<sigma>) \<union> trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t (dual\<^sub>l\<^sub>s\<^sub>s\<^sub>t (?A \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<sigma>))
|
?H1 (?H2 (?H3 (?H4 x_1 x_2) x_3)) = ?H5 (?H6 (?H7 (?H8 x_1) x_3)) (?H1 (?H2 (?H3 x_2 x_3)))
|
[
"Product_Type.prod.snd",
"Stateful_Strands.subst_apply_stateful_strand_step",
"Stateful_Strands.trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p",
"Set.union",
"List.list.Cons",
"Labeled_Stateful_Strands.subst_apply_labeled_stateful_strand",
"Labeled_Stateful_Strands.dual\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t",
"Labeled_Stateful_Strands.trms\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t"
] |
[
"'a \\<times> 'b \\<Rightarrow> 'b",
"('a, 'b) stateful_strand_step \\<Rightarrow> ('b \\<Rightarrow> ('a, 'b) Term.term) \\<Rightarrow> ('a, 'b) stateful_strand_step",
"('a, 'b) stateful_strand_step \\<Rightarrow> ('a, 'b) Term.term set",
"'a set \\<Rightarrow> 'a set \\<Rightarrow> 'a set",
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"('a strand_label \\<times> ('b, 'c) stateful_strand_step) list \\<Rightarrow> ('c \\<Rightarrow> ('b, 'c) Term.term) \\<Rightarrow> ('a strand_label \\<times> ('b, 'c) stateful_strand_step) list",
"('a strand_label \\<times> ('b, 'c) stateful_strand_step) list \\<Rightarrow> ('a strand_label \\<times> ('b, 'c) stateful_strand_step) list",
"('a \\<times> ('b, 'c) stateful_strand_step) list \\<Rightarrow> ('b, 'c) Term.term set"
] |
[
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"fun subst_apply_stateful_strand_step::\n \"('a,'b) stateful_strand_step \\<Rightarrow> ('a,'b) subst \\<Rightarrow> ('a,'b) stateful_strand_step\"\n (infix \"\\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p\" 51) where\n \"send\\<langle>ts\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = send\\<langle>ts \\<cdot>\\<^sub>l\\<^sub>i\\<^sub>s\\<^sub>t \\<theta>\\<rangle>\"\n| \"receive\\<langle>ts\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = receive\\<langle>ts \\<cdot>\\<^sub>l\\<^sub>i\\<^sub>s\\<^sub>t \\<theta>\\<rangle>\"\n| \"\\<langle>a: t \\<doteq> s\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = \\<langle>a: (t \\<cdot> \\<theta>) \\<doteq> (s \\<cdot> \\<theta>)\\<rangle>\"\n| \"\\<langle>a: t \\<in> s\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = \\<langle>a: (t \\<cdot> \\<theta>) \\<in> (s \\<cdot> \\<theta>)\\<rangle>\"\n| \"insert\\<langle>t,s\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = insert\\<langle>t \\<cdot> \\<theta>, s \\<cdot> \\<theta>\\<rangle>\"\n| \"delete\\<langle>t,s\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = delete\\<langle>t \\<cdot> \\<theta>, s \\<cdot> \\<theta>\\<rangle>\"\n| \"\\<forall>X\\<langle>\\<or>\\<noteq>: F \\<or>\\<notin>: G\\<rangle> \\<cdot>\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta> = \\<forall>X\\<langle>\\<or>\\<noteq>: (F \\<cdot>\\<^sub>p\\<^sub>a\\<^sub>i\\<^sub>r\\<^sub>s rm_vars (set X) \\<theta>) \\<or>\\<notin>: (G \\<cdot>\\<^sub>p\\<^sub>a\\<^sub>i\\<^sub>r\\<^sub>s rm_vars (set X) \\<theta>)\\<rangle>\"",
"fun trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p where\n \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (Send ts) = set ts\"\n| \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (Receive ts) = set ts\"\n| \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (Equality _ t t') = {t,t'}\"\n| \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (Insert t t') = {t,t'}\"\n| \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (Delete t t') = {t,t'}\"\n| \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (InSet _ t t') = {t,t'}\"\n| \"trms\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p (NegChecks _ F F') = trms\\<^sub>p\\<^sub>a\\<^sub>i\\<^sub>r\\<^sub>s F \\<union> trms\\<^sub>p\\<^sub>a\\<^sub>i\\<^sub>r\\<^sub>s F'\"",
"abbreviation union :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> 'a set\" (infixl \"\\<union>\" 65)\n where \"union \\<equiv> sup\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"definition subst_apply_labeled_stateful_strand::\n \"('a,'b,'c) labeled_stateful_strand \\<Rightarrow> ('a,'b) subst \\<Rightarrow> ('a,'b,'c) labeled_stateful_strand\"\n (infix \"\\<cdot>\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t\" 51) where\n \"S \\<cdot>\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t \\<theta> \\<equiv> map (\\<lambda>x. x \\<cdot>\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta>) S\"",
"abbreviation trms\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t where \"trms\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t S \\<equiv> trms\\<^sub>s\\<^sub>s\\<^sub>t (unlabel S)\""
] |
lemma_object
|
###symbols
Product_Type.prod.snd :::: 'a \<times> 'b \<Rightarrow> 'b
Stateful_Strands.subst_apply_stateful_strand_step :::: ('a, 'b) stateful_strand_step \<Rightarrow> ('b \<Rightarrow> ('a, 'b) Term.term) \<Rightarrow> ('a, 'b) stateful_strand_step
Stateful_Strands.trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p :::: ('a, 'b) stateful_strand_step \<Rightarrow> ('a, 'b) Term.term set
Set.union :::: 'a set \<Rightarrow> 'a set \<Rightarrow> 'a set
List.list.Cons :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a list
Labeled_Stateful_Strands.subst_apply_labeled_stateful_strand :::: ('a strand_label \<times> ('b, 'c) stateful_strand_step) list \<Rightarrow> ('c \<Rightarrow> ('b, 'c) Term.term) \<Rightarrow> ('a strand_label \<times> ('b, 'c) stateful_strand_step) list
Labeled_Stateful_Strands.dual\<^sub>l\<^sub>s\<^sub>s\<^sub>t :::: ('a strand_label \<times> ('b, 'c) stateful_strand_step) list \<Rightarrow> ('a strand_label \<times> ('b, 'c) stateful_strand_step) list
Labeled_Stateful_Strands.trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t :::: ('a \<times> ('b, 'c) stateful_strand_step) list \<Rightarrow> ('b, 'c) Term.term set
###defs
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
fun subst_apply_stateful_strand_step::
"('a,'b) stateful_strand_step \<Rightarrow> ('a,'b) subst \<Rightarrow> ('a,'b) stateful_strand_step"
(infix "\<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p" 51) where
"send\<langle>ts\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = send\<langle>ts \<cdot>\<^sub>l\<^sub>i\<^sub>s\<^sub>t \<theta>\<rangle>"
| "receive\<langle>ts\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = receive\<langle>ts \<cdot>\<^sub>l\<^sub>i\<^sub>s\<^sub>t \<theta>\<rangle>"
| "\<langle>a: t \<doteq> s\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = \<langle>a: (t \<cdot> \<theta>) \<doteq> (s \<cdot> \<theta>)\<rangle>"
| "\<langle>a: t \<in> s\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = \<langle>a: (t \<cdot> \<theta>) \<in> (s \<cdot> \<theta>)\<rangle>"
| "insert\<langle>t,s\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = insert\<langle>t \<cdot> \<theta>, s \<cdot> \<theta>\<rangle>"
| "delete\<langle>t,s\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = delete\<langle>t \<cdot> \<theta>, s \<cdot> \<theta>\<rangle>"
| "\<forall>X\<langle>\<or>\<noteq>: F \<or>\<notin>: G\<rangle> \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta> = \<forall>X\<langle>\<or>\<noteq>: (F \<cdot>\<^sub>p\<^sub>a\<^sub>i\<^sub>r\<^sub>s rm_vars (set X) \<theta>) \<or>\<notin>: (G \<cdot>\<^sub>p\<^sub>a\<^sub>i\<^sub>r\<^sub>s rm_vars (set X) \<theta>)\<rangle>"
fun trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p where
"trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (Send ts) = set ts"
| "trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (Receive ts) = set ts"
| "trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (Equality _ t t') = {t,t'}"
| "trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (Insert t t') = {t,t'}"
| "trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (Delete t t') = {t,t'}"
| "trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (InSet _ t t') = {t,t'}"
| "trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (NegChecks _ F F') = trms\<^sub>p\<^sub>a\<^sub>i\<^sub>r\<^sub>s F \<union> trms\<^sub>p\<^sub>a\<^sub>i\<^sub>r\<^sub>s F'"
abbreviation union :: "'a set \<Rightarrow> 'a set \<Rightarrow> 'a set" (infixl "\<union>" 65)
where "union \<equiv> sup"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
definition subst_apply_labeled_stateful_strand::
"('a,'b,'c) labeled_stateful_strand \<Rightarrow> ('a,'b) subst \<Rightarrow> ('a,'b,'c) labeled_stateful_strand"
(infix "\<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t" 51) where
"S \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta> \<equiv> map (\<lambda>x. x \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta>) S"
abbreviation trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t where "trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t S \<equiv> trms\<^sub>s\<^sub>s\<^sub>t (unlabel S)"
|
###output
trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t (dual\<^sub>l\<^sub>s\<^sub>s\<^sub>t (?a # ?A \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<sigma>)) = trms\<^sub>s\<^sub>s\<^sub>t\<^sub>p (snd ?a \<cdot>\<^sub>s\<^sub>s\<^sub>t\<^sub>p ?\<sigma>) \<union> trms\<^sub>l\<^sub>s\<^sub>s\<^sub>t (dual\<^sub>l\<^sub>s\<^sub>s\<^sub>t (?A \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<sigma>))###end
|
Finite_Fields/Finite_Fields_Preliminary_Results
|
Finite_Fields_Preliminary_Results.divides_hom
|
lemma divides_hom:
assumes "h \<in> ring_iso R S"
assumes "domain R" "domain S"
assumes "x \<in> carrier R" "y \<in> carrier R"
shows "x divides\<^bsub>R\<^esub> y \<longleftrightarrow> (h x) divides\<^bsub>S\<^esub> (h y)" (is "?lhs \<longleftrightarrow> ?rhs")
|
?h \<in> ring_iso ?R ?S \<Longrightarrow> domain ?R \<Longrightarrow> domain ?S \<Longrightarrow> ?x \<in> carrier ?R \<Longrightarrow> ?y \<in> carrier ?R \<Longrightarrow> ?x divides\<^bsub> ?R\<^esub> ?y = ?h ?x divides\<^bsub> ?S\<^esub> ?h ?y
|
\<lbrakk>x_1 \<in> ?H1 x_2 x_3; ?H2 x_2; ?H3 x_3; x_4 \<in> ?H4 x_2; x_5 \<in> ?H4 x_2\<rbrakk> \<Longrightarrow> ?H5 x_2 x_4 x_5 = ?H6 x_3 (x_1 x_4) (x_1 x_5)
|
[
"Divisibility.factor",
"Congruence.partial_object.carrier",
"Ring.domain",
"QuotRing.ring_iso"
] |
[
"('a, 'b) monoid_scheme \\<Rightarrow> 'a \\<Rightarrow> 'a \\<Rightarrow> bool",
"('a, 'b) partial_object_scheme \\<Rightarrow> 'a set",
"('a, 'b) ring_scheme \\<Rightarrow> bool",
"('a, 'b) ring_scheme \\<Rightarrow> ('c, 'd) ring_scheme \\<Rightarrow> ('a \\<Rightarrow> 'c) set"
] |
[
"definition factor :: \"[_, 'a, 'a] \\<Rightarrow> bool\" (infix \"divides\\<index>\" 65)\n where \"a divides\\<^bsub>G\\<^esub> b \\<longleftrightarrow> (\\<exists>c\\<in>carrier G. b = a \\<otimes>\\<^bsub>G\\<^esub> c)\"",
"definition\n ring_iso :: \"_ \\<Rightarrow> _ \\<Rightarrow> ('a \\<Rightarrow> 'b) set\"\n where \"ring_iso R S = { h. h \\<in> ring_hom R S \\<and> bij_betw h (carrier R) (carrier S) }\""
] |
lemma_object
|
###symbols
Divisibility.factor :::: ('a, 'b) monoid_scheme \<Rightarrow> 'a \<Rightarrow> 'a \<Rightarrow> bool
Congruence.partial_object.carrier :::: ('a, 'b) partial_object_scheme \<Rightarrow> 'a set
Ring.domain :::: ('a, 'b) ring_scheme \<Rightarrow> bool
QuotRing.ring_iso :::: ('a, 'b) ring_scheme \<Rightarrow> ('c, 'd) ring_scheme \<Rightarrow> ('a \<Rightarrow> 'c) set
###defs
definition factor :: "[_, 'a, 'a] \<Rightarrow> bool" (infix "divides\<index>" 65)
where "a divides\<^bsub>G\<^esub> b \<longleftrightarrow> (\<exists>c\<in>carrier G. b = a \<otimes>\<^bsub>G\<^esub> c)"
definition
ring_iso :: "_ \<Rightarrow> _ \<Rightarrow> ('a \<Rightarrow> 'b) set"
where "ring_iso R S = { h. h \<in> ring_hom R S \<and> bij_betw h (carrier R) (carrier S) }"
|
###output
?h \<in> ring_iso ?R ?S \<Longrightarrow> domain ?R \<Longrightarrow> domain ?S \<Longrightarrow> ?x \<in> carrier ?R \<Longrightarrow> ?y \<in> carrier ?R \<Longrightarrow> ?x divides\<^bsub> ?R\<^esub> ?y = ?h ?x divides\<^bsub> ?S\<^esub> ?h ?y###end
|
Shadow_SC_DOM/classes/ShadowRootClass
|
ShadowRootClass.known_ptrs_new_ptr
|
lemma known_ptrs_new_ptr:
"object_ptr_kinds h' = object_ptr_kinds h |\<union>| {|new_ptr|} \<Longrightarrow> known_ptr new_ptr \<Longrightarrow>
a_known_ptrs h \<Longrightarrow> a_known_ptrs h'"
|
object_ptr_kinds ?h' = object_ptr_kinds ?h |\<union>| {| ?new_ptr|} \<Longrightarrow> ShadowRootClass.known_ptr ?new_ptr \<Longrightarrow> ShadowRootClass.known_ptrs ?h \<Longrightarrow> ShadowRootClass.known_ptrs ?h'
|
\<lbrakk> ?H1 x_1 = ?H2 (?H3 x_2) (?H4 x_3 ?H5); ?H6 x_3; ?H7 x_2\<rbrakk> \<Longrightarrow> ?H8 x_1
|
[
"ShadowRootClass.known_ptrs",
"ShadowRootClass.known_ptr",
"FSet.fempty",
"FSet.finsert",
"FSet.funion",
"ObjectClass.object_ptr_kinds"
] |
[
"(_) heap \\<Rightarrow> bool",
"(_) object_ptr \\<Rightarrow> bool",
"'a fset",
"'a \\<Rightarrow> 'a fset \\<Rightarrow> 'a fset",
"'a fset \\<Rightarrow> 'a fset \\<Rightarrow> 'a fset",
"(_) heap \\<Rightarrow> (_) object_ptr fset"
] |
[
"abbreviation fempty :: \"'a fset\" (\"{||}\") where \"{||} \\<equiv> bot\"",
"abbreviation funion :: \"'a fset \\<Rightarrow> 'a fset \\<Rightarrow> 'a fset\" (infixl \"|\\<union>|\" 65) where \"xs |\\<union>| ys \\<equiv> sup xs ys\""
] |
lemma_object
|
###symbols
ShadowRootClass.known_ptrs :::: (_) heap \<Rightarrow> bool
ShadowRootClass.known_ptr :::: (_) object_ptr \<Rightarrow> bool
FSet.fempty :::: 'a fset
FSet.finsert :::: 'a \<Rightarrow> 'a fset \<Rightarrow> 'a fset
FSet.funion :::: 'a fset \<Rightarrow> 'a fset \<Rightarrow> 'a fset
ObjectClass.object_ptr_kinds :::: (_) heap \<Rightarrow> (_) object_ptr fset
###defs
abbreviation fempty :: "'a fset" ("{||}") where "{||} \<equiv> bot"
abbreviation funion :: "'a fset \<Rightarrow> 'a fset \<Rightarrow> 'a fset" (infixl "|\<union>|" 65) where "xs |\<union>| ys \<equiv> sup xs ys"
|
###output
object_ptr_kinds ?h' = object_ptr_kinds ?h |\<union>| {| ?new_ptr|} \<Longrightarrow> ShadowRootClass.known_ptr ?new_ptr \<Longrightarrow> ShadowRootClass.known_ptrs ?h \<Longrightarrow> ShadowRootClass.known_ptrs ?h'###end
|
Coinductive/Coinductive
|
Coinductive_List.lappend_lnull1
| null |
lnull ?xs \<Longrightarrow> lappend ?xs ?ys = ?ys
|
?H1 x_1 \<Longrightarrow> ?H2 x_1 x_2 = x_2
|
[
"Coinductive_List.lappend",
"Coinductive_List.llist.lnull"
] |
[
"'a llist \\<Rightarrow> 'a llist \\<Rightarrow> 'a llist",
"'a llist \\<Rightarrow> bool"
] |
[
"codatatype (lset: 'a) llist =\n lnull: LNil\n | LCons (lhd: 'a) (ltl: \"'a llist\")\nfor\n map: lmap\n rel: llist_all2\nwhere\n \"lhd LNil = undefined\"\n| \"ltl LNil = LNil\""
] |
lemma_object
|
###symbols
Coinductive_List.lappend :::: 'a llist \<Rightarrow> 'a llist \<Rightarrow> 'a llist
Coinductive_List.llist.lnull :::: 'a llist \<Rightarrow> bool
###defs
codatatype (lset: 'a) llist =
lnull: LNil
| LCons (lhd: 'a) (ltl: "'a llist")
for
map: lmap
rel: llist_all2
where
"lhd LNil = undefined"
| "ltl LNil = LNil"
|
###output
lnull ?xs \<Longrightarrow> lappend ?xs ?ys = ?ys###end
|
Slicing/JinjaVM/SemanticsWF
|
SemanticsWF.stkss_cong
|
lemma stkss_cong [cong]:
"\<lbrakk> P = P';
cs = cs';
\<And>a b. \<lbrakk> a < length cs;
b < stkLength P (fst(cs ! (length cs - Suc a)))
(fst(snd(cs ! (length cs - Suc a))))
(snd(snd(cs ! (length cs - Suc a)))) \<rbrakk>
\<Longrightarrow> stk (a, b) = stk' (a, b) \<rbrakk>
\<Longrightarrow> stkss P cs stk = stkss P' cs' stk'"
|
?P = ?P' \<Longrightarrow> ?cs = ?cs' \<Longrightarrow> (\<And>a b. a < length ?cs \<Longrightarrow> b < stkLength ?P (fst (?cs ! (length ?cs - Suc a))) (fst (snd (?cs ! (length ?cs - Suc a)))) (snd (snd (?cs ! (length ?cs - Suc a)))) \<Longrightarrow> ?stk (a, b) = ?stk' (a, b)) \<Longrightarrow> stkss ?P ?cs ?stk = stkss ?P' ?cs' ?stk'
|
\<lbrakk>x_1 = x_2; x_3 = x_4; \<And>y_0 y_1. \<lbrakk>y_0 < ?H1 x_3; y_1 < ?H2 x_1 (?H3 (?H4 x_3 (?H5 (?H1 x_3) (?H6 y_0)))) (?H7 (?H8 (?H4 x_3 (?H5 (?H1 x_3) (?H6 y_0))))) (?H9 (?H8 (?H4 x_3 (?H5 (?H1 x_3) (?H6 y_0)))))\<rbrakk> \<Longrightarrow> x_5 (y_0, y_1) = x_6 (y_0, y_1)\<rbrakk> \<Longrightarrow> ?H10 x_1 x_3 x_5 = ?H10 x_2 x_4 x_6
|
[
"JVMCFG.stkss",
"Product_Type.prod.snd",
"Nat.Suc",
"Groups.minus_class.minus",
"List.nth",
"Product_Type.prod.fst",
"JVMCFG.stkLength",
"List.length"
] |
[
"wf_jvmprog \\<Rightarrow> (char list \\<times> char list \\<times> nat) list \\<Rightarrow> (nat \\<times> nat \\<Rightarrow> 'a) \\<Rightarrow> 'a list list",
"'a \\<times> 'b \\<Rightarrow> 'b",
"nat \\<Rightarrow> nat",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a list \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a \\<times> 'b \\<Rightarrow> 'a",
"wf_jvmprog \\<Rightarrow> char list \\<Rightarrow> char list \\<Rightarrow> nat \\<Rightarrow> nat",
"'a list \\<Rightarrow> nat"
] |
[
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"primrec (nonexhaustive) nth :: \"'a list => nat => 'a\" (infixl \"!\" 100) where\nnth_Cons: \"(x # xs) ! n = (case n of 0 \\<Rightarrow> x | Suc k \\<Rightarrow> xs ! k)\"\n \\<comment> \\<open>Warning: simpset does not contain this definition, but separate\n theorems for \\<open>n = 0\\<close> and \\<open>n = Suc k\\<close>\\<close>",
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"abbreviation length :: \"'a list \\<Rightarrow> nat\" where\n\"length \\<equiv> size\""
] |
lemma_object
|
###symbols
JVMCFG.stkss :::: wf_jvmprog \<Rightarrow> (char list \<times> char list \<times> nat) list \<Rightarrow> (nat \<times> nat \<Rightarrow> 'a) \<Rightarrow> 'a list list
Product_Type.prod.snd :::: 'a \<times> 'b \<Rightarrow> 'b
Nat.Suc :::: nat \<Rightarrow> nat
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
List.nth :::: 'a list \<Rightarrow> nat \<Rightarrow> 'a
Product_Type.prod.fst :::: 'a \<times> 'b \<Rightarrow> 'a
JVMCFG.stkLength :::: wf_jvmprog \<Rightarrow> char list \<Rightarrow> char list \<Rightarrow> nat \<Rightarrow> nat
List.length :::: 'a list \<Rightarrow> nat
###defs
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
primrec (nonexhaustive) nth :: "'a list => nat => 'a" (infixl "!" 100) where
nth_Cons: "(x # xs) ! n = (case n of 0 \<Rightarrow> x | Suc k \<Rightarrow> xs ! k)"
\<comment> \<open>Warning: simpset does not contain this definition, but separate
theorems for \<open>n = 0\<close> and \<open>n = Suc k\<close>\<close>
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
abbreviation length :: "'a list \<Rightarrow> nat" where
"length \<equiv> size"
|
###output
?P = ?P' \<Longrightarrow> ?cs = ?cs' \<Longrightarrow> (\<And>a b. a < length ?cs \<Longrightarrow> b < stkLength ?P (fst (?cs ! (length ?cs - Suc a))) (fst (snd (?cs ! (length ?cs - Suc a)))) (snd (snd (?cs ! (length ?cs - Suc a)))) \<Longrightarrow> ?stk (a, b) = ?stk' (a, b)) \<Longrightarrow> stkss ?P ?cs ?stk = stkss ?P' ?cs' ?stk'###end
|
S_Finite_Measure_Monad/QuasiBorel
|
QuasiBorel.exp_qbs_space
| null |
qbs_space (?X \<Rightarrow>\<^sub>Q ?Y) = {f. \<forall>\<alpha>\<in>qbs_Mx ?X. f \<circ> \<alpha> \<in> qbs_Mx ?Y}
|
?H1 (?H2 x_1 x_2) = ?H3 (\<lambda>y_0. \<forall>y_1\<in> ?H4 x_1. ?H5 y_0 y_1 \<in> ?H6 x_2)
|
[
"Fun.comp",
"QuasiBorel.qbs_Mx",
"Set.Collect",
"QuasiBorel.exp_qbs",
"QuasiBorel.qbs_space"
] |
[
"('a \\<Rightarrow> 'b) \\<Rightarrow> ('c \\<Rightarrow> 'a) \\<Rightarrow> 'c \\<Rightarrow> 'b",
"'a quasi_borel \\<Rightarrow> (real \\<Rightarrow> 'a) set",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a set",
"'a quasi_borel \\<Rightarrow> 'b quasi_borel \\<Rightarrow> ('a \\<Rightarrow> 'b) quasi_borel",
"'a quasi_borel \\<Rightarrow> 'a set"
] |
[
"definition comp :: \"('b \\<Rightarrow> 'c) \\<Rightarrow> ('a \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> 'c\" (infixl \"\\<circ>\" 55)\n where \"f \\<circ> g = (\\<lambda>x. f (g x))\"",
"definition qbs_Mx :: \"'a quasi_borel \\<Rightarrow> (real \\<Rightarrow> 'a) set\" where\n \"qbs_Mx X \\<equiv> snd (Rep_quasi_borel X)\"",
"definition exp_qbs :: \"['a quasi_borel, 'b quasi_borel] \\<Rightarrow> ('a \\<Rightarrow> 'b) quasi_borel\" (infixr \"\\<Rightarrow>\\<^sub>Q\" 61) where\n\"X \\<Rightarrow>\\<^sub>Q Y \\<equiv> Abs_quasi_borel ({f. \\<forall>\\<alpha> \\<in> qbs_Mx X. f \\<circ> \\<alpha> \\<in> qbs_Mx Y}, {g. \\<forall>\\<alpha>\\<in> borel_measurable borel. \\<forall>\\<beta>\\<in> qbs_Mx X. (\\<lambda>r. g (\\<alpha> r) (\\<beta> r)) \\<in> qbs_Mx Y})\"",
"definition qbs_space :: \"'a quasi_borel \\<Rightarrow> 'a set\" where\n \"qbs_space X \\<equiv> fst (Rep_quasi_borel X)\""
] |
lemma_object
|
###symbols
Fun.comp :::: ('a \<Rightarrow> 'b) \<Rightarrow> ('c \<Rightarrow> 'a) \<Rightarrow> 'c \<Rightarrow> 'b
QuasiBorel.qbs_Mx :::: 'a quasi_borel \<Rightarrow> (real \<Rightarrow> 'a) set
Set.Collect :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a set
QuasiBorel.exp_qbs :::: 'a quasi_borel \<Rightarrow> 'b quasi_borel \<Rightarrow> ('a \<Rightarrow> 'b) quasi_borel
QuasiBorel.qbs_space :::: 'a quasi_borel \<Rightarrow> 'a set
###defs
definition comp :: "('b \<Rightarrow> 'c) \<Rightarrow> ('a \<Rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> 'c" (infixl "\<circ>" 55)
where "f \<circ> g = (\<lambda>x. f (g x))"
definition qbs_Mx :: "'a quasi_borel \<Rightarrow> (real \<Rightarrow> 'a) set" where
"qbs_Mx X \<equiv> snd (Rep_quasi_borel X)"
definition exp_qbs :: "['a quasi_borel, 'b quasi_borel] \<Rightarrow> ('a \<Rightarrow> 'b) quasi_borel" (infixr "\<Rightarrow>\<^sub>Q" 61) where
"X \<Rightarrow>\<^sub>Q Y \<equiv> Abs_quasi_borel ({f. \<forall>\<alpha> \<in> qbs_Mx X. f \<circ> \<alpha> \<in> qbs_Mx Y}, {g. \<forall>\<alpha>\<in> borel_measurable borel. \<forall>\<beta>\<in> qbs_Mx X. (\<lambda>r. g (\<alpha> r) (\<beta> r)) \<in> qbs_Mx Y})"
definition qbs_space :: "'a quasi_borel \<Rightarrow> 'a set" where
"qbs_space X \<equiv> fst (Rep_quasi_borel X)"
|
###output
qbs_space (?X \<Rightarrow>\<^sub>Q ?Y) = {f. \<forall>\<alpha>\<in>qbs_Mx ?X. f \<circ> \<alpha> \<in> qbs_Mx ?Y}###end
|
Refine_Imperative_HOL/Sepref_HOL_Bindings
|
Sepref_HOL_Bindings.list_assn_aux_append_conv2
|
lemma list_assn_aux_append_conv2:
"list_assn R l (m1@m2) = (\<exists>\<^sub>Al1 l2. list_assn R l1 m1 * list_assn R l2 m2 * \<up>(l=l1@l2))"
|
list_assn ?R ?l (?m1.0 @ ?m2.0) = (\<exists>\<^sub>Al1 l2. list_assn ?R l1 ?m1.0 * list_assn ?R l2 ?m2.0 * \<up> (?l = l1 @ l2))
|
?H1 x_1 x_2 (?H2 x_3 x_4) = ?H3 (\<lambda>y_0. ?H3 (\<lambda>y_1. ?H4 (?H4 (?H1 x_1 y_0 x_3) (?H1 x_1 y_1 x_4)) (?H5 (x_2 = ?H6 y_0 y_1))))
|
[
"Assertions.pure_assn",
"Groups.times_class.times",
"Assertions.ex_assn",
"List.append",
"Sepref_HOL_Bindings.list_assn"
] |
[
"bool \\<Rightarrow> assn",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"('a \\<Rightarrow> assn) \\<Rightarrow> assn",
"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"('a \\<Rightarrow> 'b \\<Rightarrow> assn) \\<Rightarrow> 'a list \\<Rightarrow> 'b list \\<Rightarrow> assn"
] |
[
"definition pure_assn :: \"bool \\<Rightarrow> assn\" (\"\\<up>\") where\n \"\\<up>b \\<equiv> Abs_assn (pure_assn_raw b)\"",
"class times =\n fixes times :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"*\" 70)",
"definition ex_assn :: \"('a \\<Rightarrow> assn) \\<Rightarrow> assn\" (binder \"\\<exists>\\<^sub>A\" 11)\n where \"(\\<exists>\\<^sub>Ax. P x) \\<equiv> Abs_assn (\\<lambda>h. \\<exists>x. h\\<Turnstile>P x)\"",
"primrec append :: \"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list\" (infixr \"@\" 65) where\nappend_Nil: \"[] @ ys = ys\" |\nappend_Cons: \"(x#xs) @ ys = x # xs @ ys\"",
"fun list_assn :: \"('a \\<Rightarrow> 'c \\<Rightarrow> assn) \\<Rightarrow> 'a list \\<Rightarrow> 'c list \\<Rightarrow> assn\" where\n \"list_assn P [] [] = emp\"\n| \"list_assn P (a#as) (c#cs) = P a c * list_assn P as cs\"\n| \"list_assn _ _ _ = False\""
] |
lemma_object
|
###symbols
Assertions.pure_assn :::: bool \<Rightarrow> assn
Groups.times_class.times :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Assertions.ex_assn :::: ('a \<Rightarrow> assn) \<Rightarrow> assn
List.append :::: 'a list \<Rightarrow> 'a list \<Rightarrow> 'a list
Sepref_HOL_Bindings.list_assn :::: ('a \<Rightarrow> 'b \<Rightarrow> assn) \<Rightarrow> 'a list \<Rightarrow> 'b list \<Rightarrow> assn
###defs
definition pure_assn :: "bool \<Rightarrow> assn" ("\<up>") where
"\<up>b \<equiv> Abs_assn (pure_assn_raw b)"
class times =
fixes times :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "*" 70)
definition ex_assn :: "('a \<Rightarrow> assn) \<Rightarrow> assn" (binder "\<exists>\<^sub>A" 11)
where "(\<exists>\<^sub>Ax. P x) \<equiv> Abs_assn (\<lambda>h. \<exists>x. h\<Turnstile>P x)"
primrec append :: "'a list \<Rightarrow> 'a list \<Rightarrow> 'a list" (infixr "@" 65) where
append_Nil: "[] @ ys = ys" |
append_Cons: "(x#xs) @ ys = x # xs @ ys"
fun list_assn :: "('a \<Rightarrow> 'c \<Rightarrow> assn) \<Rightarrow> 'a list \<Rightarrow> 'c list \<Rightarrow> assn" where
"list_assn P [] [] = emp"
| "list_assn P (a#as) (c#cs) = P a c * list_assn P as cs"
| "list_assn _ _ _ = False"
|
###output
list_assn ?R ?l (?m1.0 @ ?m2.0) = (\<exists>\<^sub>Al1 l2. list_assn ?R l1 ?m1.0 * list_assn ?R l2 ?m2.0 * \<up> (?l = l1 @ l2))###end
|
UTP/utp/utp_rel
|
utp_rel.bool_seqr_laws(1)
|
lemma bool_seqr_laws [usubst]:
fixes x :: "(bool \<Longrightarrow> '\<alpha>)"
shows
"\<And> P Q \<sigma>. \<sigma>($x \<mapsto>\<^sub>s True) \<dagger> (P ;; Q) = \<sigma> \<dagger> (P\<lbrakk>True/$x\<rbrakk> ;; Q)"
"\<And> P Q \<sigma>. \<sigma>($x \<mapsto>\<^sub>s False) \<dagger> (P ;; Q) = \<sigma> \<dagger> (P\<lbrakk>False/$x\<rbrakk> ;; Q)"
"\<And> P Q \<sigma>. \<sigma>($x\<acute> \<mapsto>\<^sub>s True) \<dagger> (P ;; Q) = \<sigma> \<dagger> (P ;; Q\<lbrakk>True/$x\<acute>\<rbrakk>)"
"\<And> P Q \<sigma>. \<sigma>($x\<acute> \<mapsto>\<^sub>s False) \<dagger> (P ;; Q) = \<sigma> \<dagger> (P ;; Q\<lbrakk>False/$x\<acute>\<rbrakk>)"
|
?\<sigma>($ ?x \<mapsto>\<^sub>s True) \<dagger> (?P ;; ?Q) = ?\<sigma> \<dagger> (?P\<lbrakk>True/$ ?x\<rbrakk> ;; ?Q)
|
?H1 (?H2 x_1 (?H3 x_2) ?H4) (?H5 x_3 x_4) = ?H1 x_1 (?H5 (?H6 (?H7 ?H8 (?H9 x_2) ?H10) x_3) x_4)
|
[
"Fun.id",
"utp_rel.seqr",
"utp_pred.True_upred",
"utp_var.in_var",
"utp_subst.subst_upd_uvar",
"utp_subst.subst"
] |
[
"'a \\<Rightarrow> 'a",
"('a, 'b) urel \\<Rightarrow> ('b, 'c) urel \\<Rightarrow> ('a, 'c) urel",
"'a upred",
"('a \\<Longrightarrow> 'b) \\<Rightarrow> 'a \\<Longrightarrow> 'b \\<times> 'c",
"('a \\<Rightarrow> 'b) \\<Rightarrow> ('c \\<Longrightarrow> 'b) \\<Rightarrow> ('c, 'a) uexpr \\<Rightarrow> 'a \\<Rightarrow> 'b",
"('a \\<Rightarrow> 'b) \\<Rightarrow> ('c, 'b) uexpr \\<Rightarrow> ('c, 'a) uexpr"
] |
[
"definition id :: \"'a \\<Rightarrow> 'a\"\n where \"id = (\\<lambda>x. x)\""
] |
lemma_object
|
###symbols
Fun.id :::: 'a \<Rightarrow> 'a
utp_rel.seqr :::: ('a, 'b) urel \<Rightarrow> ('b, 'c) urel \<Rightarrow> ('a, 'c) urel
utp_pred.True_upred :::: 'a upred
utp_var.in_var :::: ('a \<Longrightarrow> 'b) \<Rightarrow> 'a \<Longrightarrow> 'b \<times> 'c
utp_subst.subst_upd_uvar :::: ('a \<Rightarrow> 'b) \<Rightarrow> ('c \<Longrightarrow> 'b) \<Rightarrow> ('c, 'a) uexpr \<Rightarrow> 'a \<Rightarrow> 'b
utp_subst.subst :::: ('a \<Rightarrow> 'b) \<Rightarrow> ('c, 'b) uexpr \<Rightarrow> ('c, 'a) uexpr
###defs
definition id :: "'a \<Rightarrow> 'a"
where "id = (\<lambda>x. x)"
|
###output
?\<sigma>($ ?x \<mapsto>\<^sub>s True) \<dagger> (?P ;; ?Q) = ?\<sigma> \<dagger> (?P\<lbrakk>True/$ ?x\<rbrakk> ;; ?Q)###end
|
CZH_Elementary_Categories/czh_ecategories/CZH_ECAT_SS
|
CZH_ECAT_SS.the_cat_scospan_Obj_\<bb>I
| null |
?a = \<bb>\<^sub>S\<^sub>S \<Longrightarrow> ?a \<in>\<^sub>\<circ> \<rightarrow>\<bullet>\<leftarrow>\<^sub>C\<lparr>Obj\<rparr>
|
x_1 = ?H1 \<Longrightarrow> ?H2 x_1 (?H3 ?H4 ?H5)
|
[
"CZH_DG_Digraph.Obj",
"CZH_ECAT_SS.the_cat_scospan",
"ZFC_Cardinals.app",
"CZH_Sets_Sets.vmember",
"CZH_ECAT_SS.\\<bb>\\<^sub>S\\<^sub>S"
] |
[
"V",
"V",
"V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> bool",
"V"
] |
[
"definition app :: \"[V,V] \\<Rightarrow> V\"\n where \"app f x \\<equiv> THE y. \\<langle>x,y\\<rangle> \\<in> elts f\""
] |
lemma_object
|
###symbols
CZH_DG_Digraph.Obj :::: V
CZH_ECAT_SS.the_cat_scospan :::: V
ZFC_Cardinals.app :::: V \<Rightarrow> V \<Rightarrow> V
CZH_Sets_Sets.vmember :::: V \<Rightarrow> V \<Rightarrow> bool
CZH_ECAT_SS.\<bb>\<^sub>S\<^sub>S :::: V
###defs
definition app :: "[V,V] \<Rightarrow> V"
where "app f x \<equiv> THE y. \<langle>x,y\<rangle> \<in> elts f"
|
###output
?a = \<bb>\<^sub>S\<^sub>S \<Longrightarrow> ?a \<in>\<^sub>\<circ> \<rightarrow>\<bullet>\<leftarrow>\<^sub>C\<lparr>Obj\<rparr>###end
|
Automated_Stateful_Protocol_Verification/Transactions
|
Transactions.transaction_strand_subst_subsets(4)
|
lemma transaction_strand_subst_subsets[simp]:
"set (transaction_receive T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>) \<subseteq> set (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)"
"set (transaction_checks T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>) \<subseteq> set (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)"
"set (transaction_updates T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>) \<subseteq> set (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)"
"set (transaction_send T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>) \<subseteq> set (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)"
"set (unlabel (transaction_receive T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)) \<subseteq> set (unlabel (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>))"
"set (unlabel (transaction_checks T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)) \<subseteq> set (unlabel (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>))"
"set (unlabel (transaction_updates T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)) \<subseteq> set (unlabel (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>))"
"set (unlabel (transaction_send T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>)) \<subseteq> set (unlabel (transaction_strand T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta>))"
|
set (transaction_send ?T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<theta>) \<subseteq> set (transaction_strand ?T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<theta>)
|
?H1 (?H2 (?H3 (?H4 x_1) x_2)) (?H2 (?H3 (?H5 x_1) x_2))
|
[
"Transactions.transaction_strand",
"Transactions.prot_transaction.transaction_send",
"Labeled_Stateful_Strands.subst_apply_labeled_stateful_strand",
"List.list.set",
"Set.subset_eq"
] |
[
"('a, 'b, 'c, 'd) prot_transaction \\<Rightarrow> ('d strand_label \\<times> (('a, 'b, 'c, 'd) prot_fun, (('a, 'b, 'c, 'd) prot_fun, 'b prot_atom) Term.term \\<times> nat) stateful_strand_step) list",
"('a, 'b, 'c, 'd) prot_transaction \\<Rightarrow> ('d strand_label \\<times> (('a, 'b, 'c, 'd) prot_fun, (('a, 'b, 'c, 'd) prot_fun, 'b prot_atom) Term.term \\<times> nat) stateful_strand_step) list",
"('a strand_label \\<times> ('b, 'c) stateful_strand_step) list \\<Rightarrow> ('c \\<Rightarrow> ('b, 'c) Term.term) \\<Rightarrow> ('a strand_label \\<times> ('b, 'c) stateful_strand_step) list",
"'a list \\<Rightarrow> 'a set",
"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"definition transaction_strand where\n \"transaction_strand T \\<equiv>\n transaction_receive T@transaction_checks T@\n transaction_updates T@transaction_send T\"",
"datatype ('a,'b,'c,'d) prot_transaction =\n Transaction\n (transaction_decl: \"unit \\<Rightarrow> (('a,'b,'c,'d) prot_var \\<times> 'a set) list\")\n (transaction_fresh: \"('a,'b,'c,'d) prot_var list\")\n (transaction_receive: \"('a,'b,'c,'d) prot_strand\")\n (transaction_checks: \"('a,'b,'c,'d) prot_strand\")\n (transaction_updates: \"('a,'b,'c,'d) prot_strand\")\n (transaction_send: \"('a,'b,'c,'d) prot_strand\")",
"definition subst_apply_labeled_stateful_strand::\n \"('a,'b,'c) labeled_stateful_strand \\<Rightarrow> ('a,'b) subst \\<Rightarrow> ('a,'b,'c) labeled_stateful_strand\"\n (infix \"\\<cdot>\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t\" 51) where\n \"S \\<cdot>\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t \\<theta> \\<equiv> map (\\<lambda>x. x \\<cdot>\\<^sub>l\\<^sub>s\\<^sub>s\\<^sub>t\\<^sub>p \\<theta>) S\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"abbreviation subset_eq :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool\"\n where \"subset_eq \\<equiv> less_eq\""
] |
lemma_object
|
###symbols
Transactions.transaction_strand :::: ('a, 'b, 'c, 'd) prot_transaction \<Rightarrow> ('d strand_label \<times> (('a, 'b, 'c, 'd) prot_fun, (('a, 'b, 'c, 'd) prot_fun, 'b prot_atom) Term.term \<times> nat) stateful_strand_step) list
Transactions.prot_transaction.transaction_send :::: ('a, 'b, 'c, 'd) prot_transaction \<Rightarrow> ('d strand_label \<times> (('a, 'b, 'c, 'd) prot_fun, (('a, 'b, 'c, 'd) prot_fun, 'b prot_atom) Term.term \<times> nat) stateful_strand_step) list
Labeled_Stateful_Strands.subst_apply_labeled_stateful_strand :::: ('a strand_label \<times> ('b, 'c) stateful_strand_step) list \<Rightarrow> ('c \<Rightarrow> ('b, 'c) Term.term) \<Rightarrow> ('a strand_label \<times> ('b, 'c) stateful_strand_step) list
List.list.set :::: 'a list \<Rightarrow> 'a set
Set.subset_eq :::: 'a set \<Rightarrow> 'a set \<Rightarrow> bool
###defs
definition transaction_strand where
"transaction_strand T \<equiv>
transaction_receive T@transaction_checks T@
transaction_updates T@transaction_send T"
datatype ('a,'b,'c,'d) prot_transaction =
Transaction
(transaction_decl: "unit \<Rightarrow> (('a,'b,'c,'d) prot_var \<times> 'a set) list")
(transaction_fresh: "('a,'b,'c,'d) prot_var list")
(transaction_receive: "('a,'b,'c,'d) prot_strand")
(transaction_checks: "('a,'b,'c,'d) prot_strand")
(transaction_updates: "('a,'b,'c,'d) prot_strand")
(transaction_send: "('a,'b,'c,'d) prot_strand")
definition subst_apply_labeled_stateful_strand::
"('a,'b,'c) labeled_stateful_strand \<Rightarrow> ('a,'b) subst \<Rightarrow> ('a,'b,'c) labeled_stateful_strand"
(infix "\<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t" 51) where
"S \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t \<theta> \<equiv> map (\<lambda>x. x \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t\<^sub>p \<theta>) S"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
abbreviation subset_eq :: "'a set \<Rightarrow> 'a set \<Rightarrow> bool"
where "subset_eq \<equiv> less_eq"
|
###output
set (transaction_send ?T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<theta>) \<subseteq> set (transaction_strand ?T \<cdot>\<^sub>l\<^sub>s\<^sub>s\<^sub>t ?\<theta>)###end
|
DFS_Framework/Impl/Structural/General_DFS_Structure
|
General_DFS_Structure.DFS_code_unfold(2)
| null |
Let (GHOST ?m) ?f = ?f ?m
|
Let (?H1 x_1) x_2 = x_2 x_1
|
[
"DFS_Framework_Refine_Aux.GHOST"
] |
[
"'a \\<Rightarrow> 'a"
] |
[] |
lemma_object
|
###symbols
DFS_Framework_Refine_Aux.GHOST :::: 'a \<Rightarrow> 'a
###defs
|
###output
Let (GHOST ?m) ?f = ?f ?m###end
|
CZH_Elementary_Categories/czh_ecategories/CZH_ECAT_PCategory
|
CZH_ECAT_PCategory.cf_up_ArrMap_vdomain
| null |
\<D>\<^sub>\<circ> (cf_up ?I ?\<AA> ?\<CC> ?\<phi>\<lparr>ArrMap\<rparr>) = ?\<CC>\<lparr>Arr\<rparr>
|
?H1 (?H2 (?H3 x_1 x_2 x_3 x_4) ?H4) = ?H2 x_3 ?H5
|
[
"CZH_DG_Digraph.Arr",
"CZH_DG_DGHM.ArrMap",
"CZH_ECAT_PCategory.cf_up",
"ZFC_Cardinals.app",
"CZH_Sets_BRelations.app_vdomain"
] |
[
"V",
"V",
"V \\<Rightarrow> (V \\<Rightarrow> V) \\<Rightarrow> V \\<Rightarrow> (V \\<Rightarrow> V) \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V"
] |
[
"definition app :: \"[V,V] \\<Rightarrow> V\"\n where \"app f x \\<equiv> THE y. \\<langle>x,y\\<rangle> \\<in> elts f\""
] |
lemma_object
|
###symbols
CZH_DG_Digraph.Arr :::: V
CZH_DG_DGHM.ArrMap :::: V
CZH_ECAT_PCategory.cf_up :::: V \<Rightarrow> (V \<Rightarrow> V) \<Rightarrow> V \<Rightarrow> (V \<Rightarrow> V) \<Rightarrow> V
ZFC_Cardinals.app :::: V \<Rightarrow> V \<Rightarrow> V
CZH_Sets_BRelations.app_vdomain :::: V \<Rightarrow> V
###defs
definition app :: "[V,V] \<Rightarrow> V"
where "app f x \<equiv> THE y. \<langle>x,y\<rangle> \<in> elts f"
|
###output
\<D>\<^sub>\<circ> (cf_up ?I ?\<AA> ?\<CC> ?\<phi>\<lparr>ArrMap\<rparr>) = ?\<CC>\<lparr>Arr\<rparr>###end
|
Heard_Of/lastvoting/LastVotingProof
|
LastVotingProof.highestStampRcvd_exists
|
lemma highestStampRcvd_exists:
assumes nempty: "valStampsRcvd msgs \<noteq> {}"
obtains p v where "msgs p = Some (ValStamp v (highestStampRcvd msgs))"
|
valStampsRcvd ?msgs \<noteq> {} \<Longrightarrow> (\<And>p v. ?msgs p = Some (ValStamp v (highestStampRcvd ?msgs)) \<Longrightarrow> ?thesis) \<Longrightarrow> ?thesis
|
\<lbrakk> ?H1 x_1 \<noteq> ?H2; \<And>y_0 y_1. x_1 y_0 = ?H3 (?H4 y_1 (?H5 x_1)) \<Longrightarrow> x_2\<rbrakk> \<Longrightarrow> x_2
|
[
"LastVotingDefs.highestStampRcvd",
"LastVotingDefs.msg.ValStamp",
"Option.option.Some",
"Set.empty",
"LastVotingDefs.valStampsRcvd"
] |
[
"(Proc \\<Rightarrow> 'a msg option) \\<Rightarrow> nat",
"'a \\<Rightarrow> nat \\<Rightarrow> 'a msg",
"'a \\<Rightarrow> 'a option",
"'a set",
"(Proc \\<Rightarrow> 'a msg option) \\<Rightarrow> Proc set"
] |
[
"datatype 'a option =\n None\n | Some (the: 'a)",
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\""
] |
lemma_object
|
###symbols
LastVotingDefs.highestStampRcvd :::: (Proc \<Rightarrow> 'a msg option) \<Rightarrow> nat
LastVotingDefs.msg.ValStamp :::: 'a \<Rightarrow> nat \<Rightarrow> 'a msg
Option.option.Some :::: 'a \<Rightarrow> 'a option
Set.empty :::: 'a set
LastVotingDefs.valStampsRcvd :::: (Proc \<Rightarrow> 'a msg option) \<Rightarrow> Proc set
###defs
datatype 'a option =
None
| Some (the: 'a)
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
|
###output
valStampsRcvd ?msgs \<noteq> {} \<Longrightarrow> (\<And>p v. ?msgs p = Some (ValStamp v (highestStampRcvd ?msgs)) \<Longrightarrow> ?thesis) \<Longrightarrow> ?thesis###end
|
Ordinary_Differential_Equations/Refinement/Refine_Interval
|
Refine_Interval.split_ivls_at_halfspace_impl
| null |
DIM_precond TYPE(?'a) ?D \<Longrightarrow> (?Xi, ?X) \<in> clw_rel lvivl_rel \<Longrightarrow> (?sctni, ?sctn) \<in> \<langle>lv_rel\<rangle>sctn_rel \<Longrightarrow> (nres_of (dFORWEAK_LIST ?Xi (dRETURN []) (\<lambda>xa. split_ivl_at_halfspace_impl ?D ?sctni xa \<bind> (\<lambda>(a, b). dRETURN (filter_empty_ivls_impl (list_all2 (\<le>)) ([a] @ [b])))) (\<lambda>xa y. dRETURN (y @ xa))), split_ivls_at_halfspace $ ?sctn $ ?X) \<in> \<langle>clw_rel lvivl_rel\<rangle>nres_rel
|
\<lbrakk> ?H1 TYPE(?'a) x_1; (x_2, x_3) \<in> ?H2 ?H3; (x_4, x_5) \<in> ?H4 ?H5 ?H6\<rbrakk> \<Longrightarrow> (?H7 (?H8 x_2 (?H9 ?H10) (\<lambda>y_0. ?H11 (?H12 x_1 x_4 y_0) (?H13 (\<lambda>y_1 y_2. ?H9 (?H14 (?H15 (\<le>)) (?H16 (?H17 y_1 ?H10) (?H17 y_2 ?H10)))))) (\<lambda>y_3 y_4. ?H9 (?H16 y_4 y_3))), ?H18 (?H19 ?H20 x_5) x_3) \<in> ?H21 ?H22 (?H2 ?H3)
|
[
"Refine_Basic.nres_rel",
"Refine_Interval.split_ivls_at_halfspace",
"Autoref_Tagging.APP",
"List.list.Cons",
"List.append",
"List.list.list_all2",
"Refine_Interval.filter_empty_ivls_impl",
"Product_Type.prod.case_prod",
"Refine_Interval.split_ivl_at_halfspace_impl",
"Refine_Det.dbind",
"List.list.Nil",
"Refine_Det.dres.dRETURN",
"Weak_Set.dFORWEAK_LIST",
"Refine_Transfer.nres_of",
"Refine_Vector_List.lv_rel",
"Refine_Hyperplane.sctn_rel",
"Relators.relAPP",
"Refine_Interval.lvivl_rel",
"Refine_Unions.clw_rel",
"Refine_Vector_List.DIM_precond"
] |
[
"('a \\<times> 'b) set \\<Rightarrow> ('a nres \\<times> 'b nres) set",
"'a sctn \\<Rightarrow> 'a set \\<Rightarrow> 'a set nres",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> 'b",
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"('a \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> 'a list \\<Rightarrow> 'b list \\<Rightarrow> bool",
"('a \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> ('a \\<times> 'b) list \\<Rightarrow> ('a \\<times> 'b) list",
"('a \\<Rightarrow> 'b \\<Rightarrow> 'c) \\<Rightarrow> 'a \\<times> 'b \\<Rightarrow> 'c",
"nat \\<Rightarrow> real list sctn \\<Rightarrow> real list \\<times> real list \\<Rightarrow> ((real list \\<times> real list) \\<times> real list \\<times> real list) dres",
"'a dres \\<Rightarrow> ('a \\<Rightarrow> 'b dres) \\<Rightarrow> 'b dres",
"'a list",
"'a \\<Rightarrow> 'a dres",
"'a list \\<Rightarrow> 'b dres \\<Rightarrow> ('a \\<Rightarrow> 'b dres) \\<Rightarrow> ('b \\<Rightarrow> 'b \\<Rightarrow> 'b dres) \\<Rightarrow> 'b dres",
"'a dres \\<Rightarrow> 'a nres",
"(real list \\<times> 'a) set",
"('a \\<times> 'b) set \\<Rightarrow> ('a sctn \\<times> 'b sctn) set",
"(('a \\<times> 'b) set \\<Rightarrow> 'c) \\<Rightarrow> ('a \\<times> 'b) set \\<Rightarrow> 'c",
"((real list \\<times> real list) \\<times> 'a set) set",
"('a \\<times> 'b set) set \\<Rightarrow> ('a list \\<times> 'b set) set",
"'a itself \\<Rightarrow> nat \\<Rightarrow> bool"
] |
[
"definition nres_rel where \n nres_rel_def_internal: \"nres_rel R \\<equiv> {(c,a). c \\<le> \\<Down>R a}\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec append :: \"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list\" (infixr \"@\" 65) where\nappend_Nil: \"[] @ ys = ys\" |\nappend_Cons: \"(x#xs) @ ys = x # xs @ ys\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"function dbind where \n \"dbind dFAIL _ = dFAIL\"\n| \"dbind dSUCCEED _ = dSUCCEED\"\n| \"dbind (dRETURN x) f = f x\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype 'a dres = \n dSUCCEEDi \\<comment> \\<open>No result\\<close>\n| dFAILi \\<comment> \\<open>Failure\\<close>\n| dRETURN 'a \\<comment> \\<open>Regular result\\<close>",
"definition \"nres_of r \\<equiv> case r of\n dSUCCEEDi \\<Rightarrow> SUCCEED\n| dFAILi \\<Rightarrow> FAIL\n| dRETURN x \\<Rightarrow> RETURN x\""
] |
lemma_object
|
###symbols
Refine_Basic.nres_rel :::: ('a \<times> 'b) set \<Rightarrow> ('a nres \<times> 'b nres) set
Refine_Interval.split_ivls_at_halfspace :::: 'a sctn \<Rightarrow> 'a set \<Rightarrow> 'a set nres
Autoref_Tagging.APP :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> 'b
List.list.Cons :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a list
List.append :::: 'a list \<Rightarrow> 'a list \<Rightarrow> 'a list
List.list.list_all2 :::: ('a \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> 'a list \<Rightarrow> 'b list \<Rightarrow> bool
Refine_Interval.filter_empty_ivls_impl :::: ('a \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> ('a \<times> 'b) list \<Rightarrow> ('a \<times> 'b) list
Product_Type.prod.case_prod :::: ('a \<Rightarrow> 'b \<Rightarrow> 'c) \<Rightarrow> 'a \<times> 'b \<Rightarrow> 'c
Refine_Interval.split_ivl_at_halfspace_impl :::: nat \<Rightarrow> real list sctn \<Rightarrow> real list \<times> real list \<Rightarrow> ((real list \<times> real list) \<times> real list \<times> real list) dres
Refine_Det.dbind :::: 'a dres \<Rightarrow> ('a \<Rightarrow> 'b dres) \<Rightarrow> 'b dres
List.list.Nil :::: 'a list
Refine_Det.dres.dRETURN :::: 'a \<Rightarrow> 'a dres
Weak_Set.dFORWEAK_LIST :::: 'a list \<Rightarrow> 'b dres \<Rightarrow> ('a \<Rightarrow> 'b dres) \<Rightarrow> ('b \<Rightarrow> 'b \<Rightarrow> 'b dres) \<Rightarrow> 'b dres
Refine_Transfer.nres_of :::: 'a dres \<Rightarrow> 'a nres
Refine_Vector_List.lv_rel :::: (real list \<times> 'a) set
Refine_Hyperplane.sctn_rel :::: ('a \<times> 'b) set \<Rightarrow> ('a sctn \<times> 'b sctn) set
Relators.relAPP :::: (('a \<times> 'b) set \<Rightarrow> 'c) \<Rightarrow> ('a \<times> 'b) set \<Rightarrow> 'c
Refine_Interval.lvivl_rel :::: ((real list \<times> real list) \<times> 'a set) set
Refine_Unions.clw_rel :::: ('a \<times> 'b set) set \<Rightarrow> ('a list \<times> 'b set) set
Refine_Vector_List.DIM_precond :::: 'a itself \<Rightarrow> nat \<Rightarrow> bool
###defs
definition nres_rel where
nres_rel_def_internal: "nres_rel R \<equiv> {(c,a). c \<le> \<Down>R a}"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec append :: "'a list \<Rightarrow> 'a list \<Rightarrow> 'a list" (infixr "@" 65) where
append_Nil: "[] @ ys = ys" |
append_Cons: "(x#xs) @ ys = x # xs @ ys"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
function dbind where
"dbind dFAIL _ = dFAIL"
| "dbind dSUCCEED _ = dSUCCEED"
| "dbind (dRETURN x) f = f x"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype 'a dres =
dSUCCEEDi \<comment> \<open>No result\<close>
| dFAILi \<comment> \<open>Failure\<close>
| dRETURN 'a \<comment> \<open>Regular result\<close>
definition "nres_of r \<equiv> case r of
dSUCCEEDi \<Rightarrow> SUCCEED
| dFAILi \<Rightarrow> FAIL
| dRETURN x \<Rightarrow> RETURN x"
|
###output
DIM_precond TYPE(?'a) ?D \<Longrightarrow> (?Xi, ?X) \<in> clw_rel lvivl_rel \<Longrightarrow> (?sctni, ?sctn) \<in> \<langle>lv_rel\<rangle>sctn_rel \<Longrightarrow> (nres_of (dFORWEAK_LIST ?Xi (dRETURN []) (\<lambda>xa. split_ivl_at_halfspace_impl ?D ?sctni xa \<bind> (\<lambda>(a, b). dRETURN (filter_empty_ivls_impl (list_all2 (\<le>)) ([a] @ [b])))) (\<lambda>xa y. dRETURN (y @ xa))), split_ivls_at_halfspace $ ?sctn $ ?X) \<in> \<langle>clw_rel lvivl_rel\<rangle>nres_rel###end
|
CZH_Universal_Constructions/czh_ucategories/CZH_UCAT_Limit_Equalizer
|
CZH_UCAT_Limit_Equalizer.is_cat_coequalizerI
| null |
?\<epsilon> : \<Up>\<rightarrow>\<Up>\<^sub>C\<^sub>F ?\<CC> (\<bb>\<^sub>P\<^sub>L ?F) (\<aa>\<^sub>P\<^sub>L ?F) ?F ?\<bb> ?\<aa> ?F' >\<^sub>C\<^sub>F\<^sub>.\<^sub>c\<^sub>o\<^sub>l\<^sub>i\<^sub>m ?E : \<Up>\<^sub>C (\<bb>\<^sub>P\<^sub>L ?F) (\<aa>\<^sub>P\<^sub>L ?F) ?F \<mapsto>\<mapsto>\<^sub>C\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> vsv ?F' \<Longrightarrow> ?F \<in>\<^sub>\<circ> Vset ?\<alpha> \<Longrightarrow> ?F \<noteq> []\<^sub>\<circ> \<Longrightarrow> \<D>\<^sub>\<circ> ?F' = ?F \<Longrightarrow> (\<And>\<ff>. \<ff> \<in>\<^sub>\<circ> ?F \<Longrightarrow> ?F'\<lparr>\<ff>\<rparr> : ?\<bb> \<mapsto>\<^bsub> ?\<CC>\<^esub> ?\<aa>) \<Longrightarrow> ?\<epsilon> : (?\<aa>, ?\<bb>, ?F, ?F') >\<^sub>C\<^sub>F\<^sub>.\<^sub>c\<^sub>o\<^sub>e\<^sub>q ?E : \<Up>\<^sub>C \<mapsto>\<mapsto>\<^sub>C\<^bsub> ?\<alpha>\<^esub> ?\<CC>
|
\<lbrakk> ?H1 x_1 (?H2 (?H3 x_2) (?H4 x_2) x_2) x_3 (?H5 x_3 (?H3 x_2) (?H4 x_2) x_2 x_4 x_5 x_6) x_7 x_8; ?H6 x_6; ?H7 x_2 (?H8 x_1); x_2 \<noteq> ?H9; ?H10 x_6 = x_2; \<And>y_0. ?H7 y_0 x_2 \<Longrightarrow> ?H11 x_3 x_4 x_5 (?H12 x_6 y_0)\<rbrakk> \<Longrightarrow> ?H13 x_1 x_5 x_4 x_2 x_6 x_3 x_7 x_8
|
[
"CZH_UCAT_Limit_Equalizer.is_cat_coequalizer",
"ZFC_Cardinals.app",
"CZH_DG_Digraph.is_arr",
"CZH_Sets_BRelations.app_vdomain",
"CZH_Sets_FSequences.vempty_vfsequence",
"ZFC_in_HOL.Vset",
"CZH_Sets_Sets.vmember",
"CZH_Sets_BRelations.vsv",
"CZH_ECAT_Parallel.the_cf_parallel",
"CZH_ECAT_Parallel.\\<aa>\\<^sub>P\\<^sub>L",
"CZH_ECAT_Parallel.\\<bb>\\<^sub>P\\<^sub>L",
"CZH_ECAT_Parallel.the_cat_parallel",
"CZH_UCAT_Limit.is_cat_colimit"
] |
[
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> bool",
"V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> bool",
"V \\<Rightarrow> V",
"V",
"V \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> bool",
"V \\<Rightarrow> bool",
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V",
"V \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> bool"
] |
[
"definition app :: \"[V,V] \\<Rightarrow> V\"\n where \"app f x \\<equiv> THE y. \\<langle>x,y\\<rangle> \\<in> elts f\"",
"abbreviation Vset :: \"V \\<Rightarrow> V\" where \"Vset \\<equiv> Vfrom 0\""
] |
lemma_object
|
###symbols
CZH_UCAT_Limit_Equalizer.is_cat_coequalizer :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> bool
ZFC_Cardinals.app :::: V \<Rightarrow> V \<Rightarrow> V
CZH_DG_Digraph.is_arr :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> bool
CZH_Sets_BRelations.app_vdomain :::: V \<Rightarrow> V
CZH_Sets_FSequences.vempty_vfsequence :::: V
ZFC_in_HOL.Vset :::: V \<Rightarrow> V
CZH_Sets_Sets.vmember :::: V \<Rightarrow> V \<Rightarrow> bool
CZH_Sets_BRelations.vsv :::: V \<Rightarrow> bool
CZH_ECAT_Parallel.the_cf_parallel :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V
CZH_ECAT_Parallel.\<aa>\<^sub>P\<^sub>L :::: V \<Rightarrow> V
CZH_ECAT_Parallel.\<bb>\<^sub>P\<^sub>L :::: V \<Rightarrow> V
CZH_ECAT_Parallel.the_cat_parallel :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V
CZH_UCAT_Limit.is_cat_colimit :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> bool
###defs
definition app :: "[V,V] \<Rightarrow> V"
where "app f x \<equiv> THE y. \<langle>x,y\<rangle> \<in> elts f"
abbreviation Vset :: "V \<Rightarrow> V" where "Vset \<equiv> Vfrom 0"
|
###output
?\<epsilon> : \<Up>\<rightarrow>\<Up>\<^sub>C\<^sub>F ?\<CC> (\<bb>\<^sub>P\<^sub>L ?F) (\<aa>\<^sub>P\<^sub>L ?F) ?F ?\<bb> ?\<aa> ?F' >\<^sub>C\<^sub>F\<^sub>.\<^sub>c\<^sub>o\<^sub>l\<^sub>i\<^sub>m ?E : \<Up>\<^sub>C (\<bb>\<^sub>P\<^sub>L ?F) (\<aa>\<^sub>P\<^sub>L ?F) ?F \<mapsto>\<mapsto>\<^sub>C\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> vsv ?F' \<Longrightarrow> ?F \<in>\<^sub>\<circ> Vset ?\<alpha> \<Longrightarrow> ?F \<noteq> []\<^sub>\<circ> \<Longrightarrow> \<D>\<^sub>\<circ> ?F' = ?F \<Longrightarrow> (\<And>\<ff>. \<ff> \<in>\<^sub>\<circ> ?F \<Longrightarrow> ?F'\<lparr>\<ff>\<rparr> : ?\<bb> \<mapsto>\<^bsub> ?\<CC>\<^esub> ?\<aa>) \<Longrightarrow> ?\<epsilon> : (?\<aa>, ?\<bb>, ?F, ?F') >\<^sub>C\<^sub>F\<^sub>.\<^sub>c\<^sub>o\<^sub>e\<^sub>q ?E : \<Up>\<^sub>C \<mapsto>\<mapsto>\<^sub>C\<^bsub> ?\<alpha>\<^esub> ?\<CC>###end
|
DFS_Framework/Examples/Feedback_Arcs
|
Feedback_Arcs.find_fas_correct
|
lemma find_fas_correct:
assumes "graph G"
assumes "finite ((g_E G)\<^sup>* `` g_V0 G)"
shows "find_fas G \<le> SPEC (is_fas G)"
|
graph ?G \<Longrightarrow> finite ((g_E ?G)\<^sup>* `` g_V0 ?G) \<Longrightarrow> find_fas ?G \<le> SPEC (is_fas ?G)
|
\<lbrakk> ?H1 x_1; ?H2 (?H3 (?H4 (?H5 x_1)) (?H6 x_1))\<rbrakk> \<Longrightarrow> ?H7 x_1 \<le> ?H8 (?H9 x_1)
|
[
"Feedback_Arcs.is_fas",
"Refine_Basic.SPEC",
"Feedback_Arcs.find_fas",
"Digraph.graph_rec.g_V0",
"Digraph.graph_rec.g_E",
"Transitive_Closure.rtrancl",
"Relation.Image",
"Finite_Set.finite",
"Digraph.graph"
] |
[
"('a, 'b) graph_rec_scheme \\<Rightarrow> ('a \\<times> 'a) set \\<Rightarrow> bool",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a nres",
"('a, 'b) graph_rec_scheme \\<Rightarrow> ('a \\<times> 'a) set nres",
"('a, 'b) graph_rec_scheme \\<Rightarrow> 'a set",
"('a, 'b) graph_rec_scheme \\<Rightarrow> ('a \\<times> 'a) set",
"('a \\<times> 'a) set \\<Rightarrow> ('a \\<times> 'a) set",
"('a \\<times> 'b) set \\<Rightarrow> 'a set \\<Rightarrow> 'b set",
"'a set \\<Rightarrow> bool",
"('a, 'b) graph_rec_scheme \\<Rightarrow> bool"
] |
[
"abbreviation \"SPEC \\<Phi> \\<equiv> RES (Collect \\<Phi>)\"",
"inductive_set rtrancl :: \"('a \\<times> 'a) set \\<Rightarrow> ('a \\<times> 'a) set\" (\"(_\\<^sup>*)\" [1000] 999)\n for r :: \"('a \\<times> 'a) set\"\n where\n rtrancl_refl [intro!, Pure.intro!, simp]: \"(a, a) \\<in> r\\<^sup>*\"\n | rtrancl_into_rtrancl [Pure.intro]: \"(a, b) \\<in> r\\<^sup>* \\<Longrightarrow> (b, c) \\<in> r \\<Longrightarrow> (a, c) \\<in> r\\<^sup>*\"",
"definition Image :: \"('a \\<times> 'b) set \\<Rightarrow> 'a set \\<Rightarrow> 'b set\" (infixr \"``\" 90)\n where \"r `` s = {y. \\<exists>x\\<in>s. (x, y) \\<in> r}\"",
"class finite =\n assumes finite_UNIV: \"finite (UNIV :: 'a set)\"\nbegin"
] |
lemma_object
|
###symbols
Feedback_Arcs.is_fas :::: ('a, 'b) graph_rec_scheme \<Rightarrow> ('a \<times> 'a) set \<Rightarrow> bool
Refine_Basic.SPEC :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a nres
Feedback_Arcs.find_fas :::: ('a, 'b) graph_rec_scheme \<Rightarrow> ('a \<times> 'a) set nres
Digraph.graph_rec.g_V0 :::: ('a, 'b) graph_rec_scheme \<Rightarrow> 'a set
Digraph.graph_rec.g_E :::: ('a, 'b) graph_rec_scheme \<Rightarrow> ('a \<times> 'a) set
Transitive_Closure.rtrancl :::: ('a \<times> 'a) set \<Rightarrow> ('a \<times> 'a) set
Relation.Image :::: ('a \<times> 'b) set \<Rightarrow> 'a set \<Rightarrow> 'b set
Finite_Set.finite :::: 'a set \<Rightarrow> bool
Digraph.graph :::: ('a, 'b) graph_rec_scheme \<Rightarrow> bool
###defs
abbreviation "SPEC \<Phi> \<equiv> RES (Collect \<Phi>)"
inductive_set rtrancl :: "('a \<times> 'a) set \<Rightarrow> ('a \<times> 'a) set" ("(_\<^sup>*)" [1000] 999)
for r :: "('a \<times> 'a) set"
where
rtrancl_refl [intro!, Pure.intro!, simp]: "(a, a) \<in> r\<^sup>*"
| rtrancl_into_rtrancl [Pure.intro]: "(a, b) \<in> r\<^sup>* \<Longrightarrow> (b, c) \<in> r \<Longrightarrow> (a, c) \<in> r\<^sup>*"
definition Image :: "('a \<times> 'b) set \<Rightarrow> 'a set \<Rightarrow> 'b set" (infixr "``" 90)
where "r `` s = {y. \<exists>x\<in>s. (x, y) \<in> r}"
class finite =
assumes finite_UNIV: "finite (UNIV :: 'a set)"
begin
|
###output
graph ?G \<Longrightarrow> finite ((g_E ?G)\<^sup>* `` g_V0 ?G) \<Longrightarrow> find_fas ?G \<le> SPEC (is_fas ?G)###end
|
List_Update/List_Factoring
|
List_Factoring.steps'_snoc
|
lemma steps'_snoc: "length rs = length as \<Longrightarrow> n = (length as)
\<Longrightarrow> steps' init (rs@[r]) (as@[a]) (Suc n) = step (steps' init rs as n) r a"
|
length ?rs = length ?as \<Longrightarrow> ?n = length ?as \<Longrightarrow> steps' ?init (?rs @ [ ?r]) (?as @ [ ?a]) (Suc ?n) = step (steps' ?init ?rs ?as ?n) ?r ?a
|
\<lbrakk> ?H1 x_1 = ?H2 x_2; x_3 = ?H2 x_2\<rbrakk> \<Longrightarrow> ?H3 x_4 (?H4 x_1 (?H5 x_5 ?H6)) (?H7 x_2 (?H8 x_6 ?H9)) (?H10 x_3) = ?H11 (?H3 x_4 x_1 x_2 x_3) x_5 x_6
|
[
"Move_to_Front.step",
"Nat.Suc",
"List.list.Nil",
"List.list.Cons",
"List.append",
"List_Factoring.steps'",
"List.length"
] |
[
"'a list \\<Rightarrow> 'a \\<Rightarrow> nat \\<times> nat list \\<Rightarrow> 'a list",
"nat \\<Rightarrow> nat",
"'a list",
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"'a list \\<Rightarrow> 'a list \\<Rightarrow> (nat \\<times> nat list) list \\<Rightarrow> nat \\<Rightarrow> 'a list",
"'a list \\<Rightarrow> nat"
] |
[
"definition step :: \"'a state \\<Rightarrow> 'a \\<Rightarrow> answer \\<Rightarrow> 'a state\" where\n\"step s r a =\n (let (k,sws) = a in mtf2 k r (swaps sws s))\"",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec append :: \"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list\" (infixr \"@\" 65) where\nappend_Nil: \"[] @ ys = ys\" |\nappend_Cons: \"(x#xs) @ ys = x # xs @ ys\"",
"fun steps' where\n \"steps' s _ _ 0 = s\"\n| \"steps' s [] [] (Suc n) = s\"\n| \"steps' s (q#qs) (a#as) (Suc n) = steps' (step s q a) qs as n\"",
"abbreviation length :: \"'a list \\<Rightarrow> nat\" where\n\"length \\<equiv> size\""
] |
lemma_object
|
###symbols
Move_to_Front.step :::: 'a list \<Rightarrow> 'a \<Rightarrow> nat \<times> nat list \<Rightarrow> 'a list
Nat.Suc :::: nat \<Rightarrow> nat
List.list.Nil :::: 'a list
List.list.Cons :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a list
List.append :::: 'a list \<Rightarrow> 'a list \<Rightarrow> 'a list
List_Factoring.steps' :::: 'a list \<Rightarrow> 'a list \<Rightarrow> (nat \<times> nat list) list \<Rightarrow> nat \<Rightarrow> 'a list
List.length :::: 'a list \<Rightarrow> nat
###defs
definition step :: "'a state \<Rightarrow> 'a \<Rightarrow> answer \<Rightarrow> 'a state" where
"step s r a =
(let (k,sws) = a in mtf2 k r (swaps sws s))"
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec append :: "'a list \<Rightarrow> 'a list \<Rightarrow> 'a list" (infixr "@" 65) where
append_Nil: "[] @ ys = ys" |
append_Cons: "(x#xs) @ ys = x # xs @ ys"
fun steps' where
"steps' s _ _ 0 = s"
| "steps' s [] [] (Suc n) = s"
| "steps' s (q#qs) (a#as) (Suc n) = steps' (step s q a) qs as n"
abbreviation length :: "'a list \<Rightarrow> nat" where
"length \<equiv> size"
|
###output
length ?rs = length ?as \<Longrightarrow> ?n = length ?as \<Longrightarrow> steps' ?init (?rs @ [ ?r]) (?as @ [ ?a]) (Suc ?n) = step (steps' ?init ?rs ?as ?n) ?r ?a###end
|
AutoFocus-Stream/AF_Stream
|
AF_Stream.is_Msg_message_af_conv2
|
lemma is_Msg_message_af_conv2: "is_Msg m = (m \<noteq> \<NoMsg>)"
|
is_Msg ?m = (?m \<noteq> NoMsg)
|
?H1 x_1 = (x_1 \<noteq> ?H2)
|
[
"AF_Stream.message_af.NoMsg",
"AF_Stream.is_Msg"
] |
[
"'a message_af",
"'a \\<Rightarrow> bool"
] |
[
"datatype 'a message_af = NoMsg | Msg 'a",
"definition is_Msg :: \"'a \\<Rightarrow> bool\"\n where \"is_Msg x \\<equiv> (\\<not> is_NoMsg x)\""
] |
lemma_object
|
###symbols
AF_Stream.message_af.NoMsg :::: 'a message_af
AF_Stream.is_Msg :::: 'a \<Rightarrow> bool
###defs
datatype 'a message_af = NoMsg | Msg 'a
definition is_Msg :: "'a \<Rightarrow> bool"
where "is_Msg x \<equiv> (\<not> is_NoMsg x)"
|
###output
is_Msg ?m = (?m \<noteq> NoMsg)###end
|
AODV/Aodv_Data
|
Aodv_Data.sqnf_update
|
lemma sqnf_update [simp]: "\<And>rt dip dsn dsk flg hops sip.
rt \<noteq> update rt dip (dsn, dsk, flg, hops, sip, {})
\<Longrightarrow> sqnf (update rt dip (dsn, dsk, flg, hops, sip, {})) dip = dsk"
|
?rt \<noteq> update ?rt ?dip (?dsn, ?dsk, ?flg, ?hops, ?sip, {}) \<Longrightarrow> sqnf (update ?rt ?dip (?dsn, ?dsk, ?flg, ?hops, ?sip, {})) ?dip = ?dsk
|
x_1 \<noteq> ?H1 x_1 x_2 (x_3, x_4, x_5, x_6, x_7, ?H2) \<Longrightarrow> ?H3 (?H1 x_1 x_2 (x_3, x_4, x_5, x_6, x_7, ?H2)) x_2 = x_4
|
[
"Aodv_Data.sqnf",
"Set.empty",
"Aodv_Data.update"
] |
[
"(nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option) \\<Rightarrow> nat \\<Rightarrow> k",
"'a set",
"(nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option) \\<Rightarrow> nat \\<Rightarrow> nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set \\<Rightarrow> nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option"
] |
[
"definition sqnf :: \"rt \\<Rightarrow> ip \\<Rightarrow> k\"\n where \"sqnf rt dip \\<equiv> case \\<sigma>\\<^bsub>route\\<^esub>(rt, dip) of Some r \\<Rightarrow> \\<pi>\\<^sub>3(r) | None \\<Rightarrow> unk\"",
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"definition update :: \"rt \\<Rightarrow> ip \\<Rightarrow> r \\<Rightarrow> rt\"\n where\n \"update rt ip r \\<equiv>\n case \\<sigma>\\<^bsub>route\\<^esub>(rt, ip) of\n None \\<Rightarrow> rt (ip \\<mapsto> r)\n | Some s \\<Rightarrow>\n if \\<pi>\\<^sub>2(s) < \\<pi>\\<^sub>2(r) then rt (ip \\<mapsto> addpre r (\\<pi>\\<^sub>7(s)))\n else if \\<pi>\\<^sub>2(s) = \\<pi>\\<^sub>2(r) \\<and> (\\<pi>\\<^sub>5(s) > \\<pi>\\<^sub>5(r) \\<or> \\<pi>\\<^sub>4(s) = inv)\n then rt (ip \\<mapsto> addpre r (\\<pi>\\<^sub>7(s)))\n else if \\<pi>\\<^sub>3(r) = unk\n then rt (ip \\<mapsto> (\\<pi>\\<^sub>2(s), snd (addpre r (\\<pi>\\<^sub>7(s)))))\n else rt (ip \\<mapsto> addpre s (\\<pi>\\<^sub>7(r)))\""
] |
lemma_object
|
###symbols
Aodv_Data.sqnf :::: (nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option) \<Rightarrow> nat \<Rightarrow> k
Set.empty :::: 'a set
Aodv_Data.update :::: (nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option) \<Rightarrow> nat \<Rightarrow> nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set \<Rightarrow> nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option
###defs
definition sqnf :: "rt \<Rightarrow> ip \<Rightarrow> k"
where "sqnf rt dip \<equiv> case \<sigma>\<^bsub>route\<^esub>(rt, dip) of Some r \<Rightarrow> \<pi>\<^sub>3(r) | None \<Rightarrow> unk"
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
definition update :: "rt \<Rightarrow> ip \<Rightarrow> r \<Rightarrow> rt"
where
"update rt ip r \<equiv>
case \<sigma>\<^bsub>route\<^esub>(rt, ip) of
None \<Rightarrow> rt (ip \<mapsto> r)
| Some s \<Rightarrow>
if \<pi>\<^sub>2(s) < \<pi>\<^sub>2(r) then rt (ip \<mapsto> addpre r (\<pi>\<^sub>7(s)))
else if \<pi>\<^sub>2(s) = \<pi>\<^sub>2(r) \<and> (\<pi>\<^sub>5(s) > \<pi>\<^sub>5(r) \<or> \<pi>\<^sub>4(s) = inv)
then rt (ip \<mapsto> addpre r (\<pi>\<^sub>7(s)))
else if \<pi>\<^sub>3(r) = unk
then rt (ip \<mapsto> (\<pi>\<^sub>2(s), snd (addpre r (\<pi>\<^sub>7(s)))))
else rt (ip \<mapsto> addpre s (\<pi>\<^sub>7(r)))"
|
###output
?rt \<noteq> update ?rt ?dip (?dsn, ?dsk, ?flg, ?hops, ?sip, {}) \<Longrightarrow> sqnf (update ?rt ?dip (?dsn, ?dsk, ?flg, ?hops, ?sip, {})) ?dip = ?dsk###end
|
UTP/utp/utp_pred_laws
|
utp_pred_laws.min_top
| null |
ord.min (\<le>) True ?x = ?x
|
?H1 (\<le>) ?H2 x_1 = x_1
|
[
"utp_pred.True_upred",
"Orderings.ord.min"
] |
[
"'a upred",
"('a \\<Rightarrow> 'a \\<Rightarrow> bool) \\<Rightarrow> 'a \\<Rightarrow> 'a \\<Rightarrow> 'a"
] |
[
"class ord =\n fixes less_eq :: \"'a \\<Rightarrow> 'a \\<Rightarrow> bool\"\n and less :: \"'a \\<Rightarrow> 'a \\<Rightarrow> bool\"\nbegin"
] |
lemma_object
|
###symbols
utp_pred.True_upred :::: 'a upred
Orderings.ord.min :::: ('a \<Rightarrow> 'a \<Rightarrow> bool) \<Rightarrow> 'a \<Rightarrow> 'a \<Rightarrow> 'a
###defs
class ord =
fixes less_eq :: "'a \<Rightarrow> 'a \<Rightarrow> bool"
and less :: "'a \<Rightarrow> 'a \<Rightarrow> bool"
begin
|
###output
ord.min (\<le>) True ?x = ?x###end
|
Coinductive/Coinductive
|
Coinductive_List.mcont2mcont_lzip1
| null |
mcont ?lub ?ord lSup lprefix ?t \<Longrightarrow> mcont ?lub ?ord lSup lprefix (\<lambda>x. lzip (?t x) ?ys1)
|
?H1 x_1 x_2 ?H2 ?H3 x_3 \<Longrightarrow> ?H4 x_1 x_2 ?H5 ?H6 (\<lambda>y_1. ?H7 (x_3 y_1) x_4)
|
[
"Coinductive_List.lzip",
"Coinductive_List.lprefix",
"Coinductive_List.lSup",
"Complete_Partial_Order2.mcont"
] |
[
"'a llist \\<Rightarrow> 'b llist \\<Rightarrow> ('a \\<times> 'b) llist",
"'a llist \\<Rightarrow> 'a llist \\<Rightarrow> bool",
"'a llist set \\<Rightarrow> 'a llist",
"('a set \\<Rightarrow> 'a) \\<Rightarrow> ('a \\<Rightarrow> 'a \\<Rightarrow> bool) \\<Rightarrow> ('b set \\<Rightarrow> 'b) \\<Rightarrow> ('b \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> ('a \\<Rightarrow> 'b) \\<Rightarrow> bool"
] |
[
"primcorec lzip :: \"'a llist \\<Rightarrow> 'b llist \\<Rightarrow> ('a \\<times> 'b) llist\"\nwhere\n \"lnull xs \\<or> lnull ys \\<Longrightarrow> lnull (lzip xs ys)\"\n| \"lhd (lzip xs ys) = (lhd xs, lhd ys)\"\n| \"ltl (lzip xs ys) = lzip (ltl xs) (ltl ys)\"",
"coinductive lprefix :: \"'a llist \\<Rightarrow> 'a llist \\<Rightarrow> bool\" (infix \"\\<sqsubseteq>\" 65)\nwhere\n LNil_lprefix [simp, intro!]: \"LNil \\<sqsubseteq> xs\"\n| Le_LCons: \"xs \\<sqsubseteq> ys \\<Longrightarrow> LCons x xs \\<sqsubseteq> LCons x ys\"",
"primcorec lSup :: \"'a llist set \\<Rightarrow> 'a llist\"\nwhere\n \"lSup A =\n (if \\<forall>x\\<in>A. lnull x then LNil\n else LCons (THE x. x \\<in> lhd ` (A \\<inter> {xs. \\<not> lnull xs})) (lSup (ltl ` (A \\<inter> {xs. \\<not> lnull xs}))))\"",
"definition mcont :: \"('a set \\<Rightarrow> 'a) \\<Rightarrow> ('a \\<Rightarrow> 'a \\<Rightarrow> bool) \\<Rightarrow> ('b set \\<Rightarrow> 'b) \\<Rightarrow> ('b \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> ('a \\<Rightarrow> 'b) \\<Rightarrow> bool\"\nwhere\n \"mcont luba orda lubb ordb f \\<longleftrightarrow>\n monotone orda ordb f \\<and> cont luba orda lubb ordb f\""
] |
lemma_object
|
###symbols
Coinductive_List.lzip :::: 'a llist \<Rightarrow> 'b llist \<Rightarrow> ('a \<times> 'b) llist
Coinductive_List.lprefix :::: 'a llist \<Rightarrow> 'a llist \<Rightarrow> bool
Coinductive_List.lSup :::: 'a llist set \<Rightarrow> 'a llist
Complete_Partial_Order2.mcont :::: ('a set \<Rightarrow> 'a) \<Rightarrow> ('a \<Rightarrow> 'a \<Rightarrow> bool) \<Rightarrow> ('b set \<Rightarrow> 'b) \<Rightarrow> ('b \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> ('a \<Rightarrow> 'b) \<Rightarrow> bool
###defs
primcorec lzip :: "'a llist \<Rightarrow> 'b llist \<Rightarrow> ('a \<times> 'b) llist"
where
"lnull xs \<or> lnull ys \<Longrightarrow> lnull (lzip xs ys)"
| "lhd (lzip xs ys) = (lhd xs, lhd ys)"
| "ltl (lzip xs ys) = lzip (ltl xs) (ltl ys)"
coinductive lprefix :: "'a llist \<Rightarrow> 'a llist \<Rightarrow> bool" (infix "\<sqsubseteq>" 65)
where
LNil_lprefix [simp, intro!]: "LNil \<sqsubseteq> xs"
| Le_LCons: "xs \<sqsubseteq> ys \<Longrightarrow> LCons x xs \<sqsubseteq> LCons x ys"
primcorec lSup :: "'a llist set \<Rightarrow> 'a llist"
where
"lSup A =
(if \<forall>x\<in>A. lnull x then LNil
else LCons (THE x. x \<in> lhd ` (A \<inter> {xs. \<not> lnull xs})) (lSup (ltl ` (A \<inter> {xs. \<not> lnull xs}))))"
definition mcont :: "('a set \<Rightarrow> 'a) \<Rightarrow> ('a \<Rightarrow> 'a \<Rightarrow> bool) \<Rightarrow> ('b set \<Rightarrow> 'b) \<Rightarrow> ('b \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> ('a \<Rightarrow> 'b) \<Rightarrow> bool"
where
"mcont luba orda lubb ordb f \<longleftrightarrow>
monotone orda ordb f \<and> cont luba orda lubb ordb f"
|
###output
mcont ?lub ?ord lSup lprefix ?t \<Longrightarrow> mcont ?lub ?ord lSup lprefix (\<lambda>x. lzip (?t x) ?ys1)###end
|
LTL_to_GBA/LTL_to_GBA_impl
|
LTL_to_GBA_impl.create_name_gba_alt
|
lemma create_name_gba_alt: "create_name_gba \<phi> = do {
nds \<leftarrow> create_graph\<^sub>T \<phi>;
ASSERT (nds_invars nds);
RETURN (gba_rename_ext (\<lambda>_. ()) name (create_gba_from_nodes \<phi> nds))
}"
|
create_name_gba ?\<phi> = create_graph\<^sub>T ?\<phi> \<bind> (\<lambda>nds. ASSERT (nds_invars nds) \<bind> (\<lambda>_. RETURN (gba_rename name (create_gba_from_nodes ?\<phi> nds))))
|
?H1 x_1 = ?H2 (?H3 x_1) (\<lambda>y_0. ?H4 (?H5 (?H6 y_0)) (\<lambda>y_1. ?H7 (?H8 ?H9 (?H10 x_1 y_0))))
|
[
"LTL_to_GBA.create_gba_from_nodes",
"LTL_to_GBA.node.name",
"Automata.gba_rename",
"Refine_Basic.RETURN",
"LTL_to_GBA.nds_invars",
"Refine_Basic.ASSERT",
"LTL_to_GBA.create_graph\\<^sub>T",
"Refine_Basic.bind",
"LTL_to_GBA.create_name_gba"
] |
[
"'a ltlr \\<Rightarrow> 'a node set \\<Rightarrow> ('a node, 'a set) gba_rec",
"('a, 'b) node_scheme \\<Rightarrow> nat",
"('a \\<Rightarrow> 'b) \\<Rightarrow> ('a, 'c, 'd) gba_rec_scheme \\<Rightarrow> ('b, 'c) gba_rec",
"'a \\<Rightarrow> 'a nres",
"('a, 'b) node_scheme set \\<Rightarrow> bool",
"bool \\<Rightarrow> unit nres",
"'a ltlr \\<Rightarrow> 'a node set nres",
"'a nres \\<Rightarrow> ('a \\<Rightarrow> 'b nres) \\<Rightarrow> 'b nres",
"'a ltlr \\<Rightarrow> (nat, 'a set) gba_rec nres"
] |
[
"definition create_gba_from_nodes :: \"'a frml \\<Rightarrow> 'a node set \\<Rightarrow> ('a node, 'a set) gba_rec\"\nwhere \"create_gba_from_nodes \\<phi> qs \\<equiv> \\<lparr>\n g_V = qs,\n g_E = {(q, q'). q\\<in>qs \\<and> q'\\<in>qs \\<and> name q\\<in>incoming q'},\n g_V0 = {q\\<in>qs. expand_init\\<in>incoming q},\n gbg_F = {{q\\<in>qs. \\<mu> U\\<^sub>r \\<eta>\\<in>old q \\<longrightarrow> \\<eta>\\<in>old q}|\\<mu> \\<eta>. \\<mu> U\\<^sub>r \\<eta> \\<in> subfrmlsr \\<phi>},\n gba_L = \\<lambda>q l. q\\<in>qs \\<and> {p. prop\\<^sub>r(p)\\<in>old q}\\<subseteq>l \\<and> {p. nprop\\<^sub>r(p)\\<in>old q} \\<inter> l = {}\n\\<rparr>\"",
"abbreviation \"gba_rename \\<equiv> gba_rename_ext (\\<lambda>_. ())\"",
"definition \"RETURN x \\<equiv> RES {x}\"",
"definition \"nds_invars nds \\<equiv>\n inj_on name nds\n \\<and> finite nds\n \\<and> expand_init \\<notin> name`nds\n \\<and> (\\<forall>nd\\<in>nds.\n finite (old nd)\n \\<and> incoming nd \\<subseteq> insert expand_init (name ` nds))\"",
"definition ASSERT where \"ASSERT \\<equiv> iASSERT RETURN\"",
"definition create_graph\\<^sub>T :: \"'a frml \\<Rightarrow> 'a node set nres\"\nwhere\n \"create_graph\\<^sub>T \\<phi> \\<equiv> do {\n (_, nds) \\<leftarrow> expand\\<^sub>T (\n \\<lparr>\n name = expand_new_name expand_init,\n incoming = {expand_init},\n new = {\\<phi>},\n old = {},\n next = {}\n \\<rparr>::'a node,\n {}::'a node set);\n RETURN nds\n }\"",
"definition bind where \"bind M f \\<equiv> case M of \n FAILi \\<Rightarrow> FAIL |\n RES X \\<Rightarrow> Sup (f`X)\"",
"definition \"create_name_gba \\<phi> \\<equiv> do {\n G \\<leftarrow> create_gba \\<phi>;\n ASSERT (nds_invars (g_V G));\n RETURN (gba_rename name G)\n}\""
] |
lemma_object
|
###symbols
LTL_to_GBA.create_gba_from_nodes :::: 'a ltlr \<Rightarrow> 'a node set \<Rightarrow> ('a node, 'a set) gba_rec
LTL_to_GBA.node.name :::: ('a, 'b) node_scheme \<Rightarrow> nat
Automata.gba_rename :::: ('a \<Rightarrow> 'b) \<Rightarrow> ('a, 'c, 'd) gba_rec_scheme \<Rightarrow> ('b, 'c) gba_rec
Refine_Basic.RETURN :::: 'a \<Rightarrow> 'a nres
LTL_to_GBA.nds_invars :::: ('a, 'b) node_scheme set \<Rightarrow> bool
Refine_Basic.ASSERT :::: bool \<Rightarrow> unit nres
LTL_to_GBA.create_graph\<^sub>T :::: 'a ltlr \<Rightarrow> 'a node set nres
Refine_Basic.bind :::: 'a nres \<Rightarrow> ('a \<Rightarrow> 'b nres) \<Rightarrow> 'b nres
LTL_to_GBA.create_name_gba :::: 'a ltlr \<Rightarrow> (nat, 'a set) gba_rec nres
###defs
definition create_gba_from_nodes :: "'a frml \<Rightarrow> 'a node set \<Rightarrow> ('a node, 'a set) gba_rec"
where "create_gba_from_nodes \<phi> qs \<equiv> \<lparr>
g_V = qs,
g_E = {(q, q'). q\<in>qs \<and> q'\<in>qs \<and> name q\<in>incoming q'},
g_V0 = {q\<in>qs. expand_init\<in>incoming q},
gbg_F = {{q\<in>qs. \<mu> U\<^sub>r \<eta>\<in>old q \<longrightarrow> \<eta>\<in>old q}|\<mu> \<eta>. \<mu> U\<^sub>r \<eta> \<in> subfrmlsr \<phi>},
gba_L = \<lambda>q l. q\<in>qs \<and> {p. prop\<^sub>r(p)\<in>old q}\<subseteq>l \<and> {p. nprop\<^sub>r(p)\<in>old q} \<inter> l = {}
\<rparr>"
abbreviation "gba_rename \<equiv> gba_rename_ext (\<lambda>_. ())"
definition "RETURN x \<equiv> RES {x}"
definition "nds_invars nds \<equiv>
inj_on name nds
\<and> finite nds
\<and> expand_init \<notin> name`nds
\<and> (\<forall>nd\<in>nds.
finite (old nd)
\<and> incoming nd \<subseteq> insert expand_init (name ` nds))"
definition ASSERT where "ASSERT \<equiv> iASSERT RETURN"
definition create_graph\<^sub>T :: "'a frml \<Rightarrow> 'a node set nres"
where
"create_graph\<^sub>T \<phi> \<equiv> do {
(_, nds) \<leftarrow> expand\<^sub>T (
\<lparr>
name = expand_new_name expand_init,
incoming = {expand_init},
new = {\<phi>},
old = {},
next = {}
\<rparr>::'a node,
{}::'a node set);
RETURN nds
}"
definition bind where "bind M f \<equiv> case M of
FAILi \<Rightarrow> FAIL |
RES X \<Rightarrow> Sup (f`X)"
definition "create_name_gba \<phi> \<equiv> do {
G \<leftarrow> create_gba \<phi>;
ASSERT (nds_invars (g_V G));
RETURN (gba_rename name G)
}"
|
###output
create_name_gba ?\<phi> = create_graph\<^sub>T ?\<phi> \<bind> (\<lambda>nds. ASSERT (nds_invars nds) \<bind> (\<lambda>_. RETURN (gba_rename name (create_gba_from_nodes ?\<phi> nds))))###end
|
ConcurrentGC/Tactics
|
Tactics.vcg_sem_simps(322)
| null |
\<not> rel_mem_load_action ?R1.0 ?R2.0 mr_fM (mr_Payload ?x21.0 ?x22.0)
|
\<not> ?H1 x_1 x_2 ?H2 (?H3 x_3 x_4)
|
[
"Model.mem_load_action.mr_Payload",
"Model.mem_load_action.mr_fM",
"Model.mem_load_action.rel_mem_load_action"
] |
[
"'a \\<Rightarrow> 'b \\<Rightarrow> ('b, 'a) mem_load_action",
"('a, 'b) mem_load_action",
"('a \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> ('c \\<Rightarrow> 'd \\<Rightarrow> bool) \\<Rightarrow> ('a, 'c) mem_load_action \\<Rightarrow> ('b, 'd) mem_load_action \\<Rightarrow> bool"
] |
[
"datatype ('field, 'ref) mem_load_action\n = mr_Ref 'ref 'field\n | mr_Payload 'ref 'field\n | mr_Mark 'ref\n | mr_Phase\n | mr_fM\n | mr_fA",
"datatype ('field, 'ref) mem_load_action\n = mr_Ref 'ref 'field\n | mr_Payload 'ref 'field\n | mr_Mark 'ref\n | mr_Phase\n | mr_fM\n | mr_fA",
"datatype ('field, 'ref) mem_load_action\n = mr_Ref 'ref 'field\n | mr_Payload 'ref 'field\n | mr_Mark 'ref\n | mr_Phase\n | mr_fM\n | mr_fA"
] |
lemma_object
|
###symbols
Model.mem_load_action.mr_Payload :::: 'a \<Rightarrow> 'b \<Rightarrow> ('b, 'a) mem_load_action
Model.mem_load_action.mr_fM :::: ('a, 'b) mem_load_action
Model.mem_load_action.rel_mem_load_action :::: ('a \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> ('c \<Rightarrow> 'd \<Rightarrow> bool) \<Rightarrow> ('a, 'c) mem_load_action \<Rightarrow> ('b, 'd) mem_load_action \<Rightarrow> bool
###defs
datatype ('field, 'ref) mem_load_action
= mr_Ref 'ref 'field
| mr_Payload 'ref 'field
| mr_Mark 'ref
| mr_Phase
| mr_fM
| mr_fA
datatype ('field, 'ref) mem_load_action
= mr_Ref 'ref 'field
| mr_Payload 'ref 'field
| mr_Mark 'ref
| mr_Phase
| mr_fM
| mr_fA
datatype ('field, 'ref) mem_load_action
= mr_Ref 'ref 'field
| mr_Payload 'ref 'field
| mr_Mark 'ref
| mr_Phase
| mr_fM
| mr_fA
|
###output
\<not> rel_mem_load_action ?R1.0 ?R2.0 mr_fM (mr_Payload ?x21.0 ?x22.0)###end
|
Verified-Prover/Prover
|
Prover.ss(92)
| null |
fv (FDisj ?f ?g) = fv ?f @ fv ?g
|
?H1 (?H2 x_1 x_2) = ?H3 (?H1 x_1) (?H1 x_2)
|
[
"List.append",
"Prover.form.FDisj",
"Prover.fv"
] |
[
"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"form \\<Rightarrow> form \\<Rightarrow> form",
"form \\<Rightarrow> nat list"
] |
[
"primrec append :: \"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list\" (infixr \"@\" 65) where\nappend_Nil: \"[] @ ys = ys\" |\nappend_Cons: \"(x#xs) @ ys = x # xs @ ys\"",
"datatype form = \n PAtom pred \"var list\"\n | NAtom pred \"var list\"\n | FConj form form\n | FDisj form form\n | FAll form\n | FEx form",
"primrec fv :: \"form => var list\" \\<comment> \\<open>shouldn't need to be more constructive than this\\<close>\nwhere\n \"fv (PAtom p vs) = vs\"\n| \"fv (NAtom p vs) = vs\"\n| \"fv (FConj f g) = (fv f) @ (fv g)\"\n| \"fv (FDisj f g) = (fv f) @ (fv g)\"\n| \"fv (FAll f) = preSuc (fv f)\"\n| \"fv (FEx f) = preSuc (fv f)\""
] |
lemma_object
|
###symbols
List.append :::: 'a list \<Rightarrow> 'a list \<Rightarrow> 'a list
Prover.form.FDisj :::: form \<Rightarrow> form \<Rightarrow> form
Prover.fv :::: form \<Rightarrow> nat list
###defs
primrec append :: "'a list \<Rightarrow> 'a list \<Rightarrow> 'a list" (infixr "@" 65) where
append_Nil: "[] @ ys = ys" |
append_Cons: "(x#xs) @ ys = x # xs @ ys"
datatype form =
PAtom pred "var list"
| NAtom pred "var list"
| FConj form form
| FDisj form form
| FAll form
| FEx form
primrec fv :: "form => var list" \<comment> \<open>shouldn't need to be more constructive than this\<close>
where
"fv (PAtom p vs) = vs"
| "fv (NAtom p vs) = vs"
| "fv (FConj f g) = (fv f) @ (fv g)"
| "fv (FDisj f g) = (fv f) @ (fv g)"
| "fv (FAll f) = preSuc (fv f)"
| "fv (FEx f) = preSuc (fv f)"
|
###output
fv (FDisj ?f ?g) = fv ?f @ fv ?g###end
|
Containers/Examples/TwoSat_Ex
|
TwoSat_Ex.imp_graph_rtrancl_skew_sym
|
lemma imp_graph_rtrancl_skew_sym:
"(l\<^sub>1, l\<^sub>2) \<in> (imp_graph cnf)\<^sup>* \<Longrightarrow> (negate l\<^sub>2, negate l\<^sub>1) \<in> (imp_graph cnf)\<^sup>*"
|
(?l\<^sub>1, ?l\<^sub>2) \<in> (imp_graph ?cnf)\<^sup>* \<Longrightarrow> (negate ?l\<^sub>2, negate ?l\<^sub>1) \<in> (imp_graph ?cnf)\<^sup>*
|
(x_1, x_2) \<in> ?H1 (?H2 x_3) \<Longrightarrow> (?H3 x_2, ?H3 x_1) \<in> ?H1 (?H2 x_3)
|
[
"TwoSat_Ex.negate",
"TwoSat_Ex.imp_graph",
"Transitive_Closure.rtrancl"
] |
[
"lit \\<Rightarrow> lit",
"lit uprod set \\<Rightarrow> (lit \\<times> lit) set",
"('a \\<times> 'a) set \\<Rightarrow> ('a \\<times> 'a) set"
] |
[
"inductive_set rtrancl :: \"('a \\<times> 'a) set \\<Rightarrow> ('a \\<times> 'a) set\" (\"(_\\<^sup>*)\" [1000] 999)\n for r :: \"('a \\<times> 'a) set\"\n where\n rtrancl_refl [intro!, Pure.intro!, simp]: \"(a, a) \\<in> r\\<^sup>*\"\n | rtrancl_into_rtrancl [Pure.intro]: \"(a, b) \\<in> r\\<^sup>* \\<Longrightarrow> (b, c) \\<in> r \\<Longrightarrow> (a, c) \\<in> r\\<^sup>*\""
] |
lemma_object
|
###symbols
TwoSat_Ex.negate :::: lit \<Rightarrow> lit
TwoSat_Ex.imp_graph :::: lit uprod set \<Rightarrow> (lit \<times> lit) set
Transitive_Closure.rtrancl :::: ('a \<times> 'a) set \<Rightarrow> ('a \<times> 'a) set
###defs
inductive_set rtrancl :: "('a \<times> 'a) set \<Rightarrow> ('a \<times> 'a) set" ("(_\<^sup>*)" [1000] 999)
for r :: "('a \<times> 'a) set"
where
rtrancl_refl [intro!, Pure.intro!, simp]: "(a, a) \<in> r\<^sup>*"
| rtrancl_into_rtrancl [Pure.intro]: "(a, b) \<in> r\<^sup>* \<Longrightarrow> (b, c) \<in> r \<Longrightarrow> (a, c) \<in> r\<^sup>*"
|
###output
(?l\<^sub>1, ?l\<^sub>2) \<in> (imp_graph ?cnf)\<^sup>* \<Longrightarrow> (negate ?l\<^sub>2, negate ?l\<^sub>1) \<in> (imp_graph ?cnf)\<^sup>*###end
|
Extended_Finite_State_Machines/EFSM_LTL
|
EFSM_LTL.once_none_nxt_always_none
|
lemma once_none_nxt_always_none: "alw (nxt (state_eq None)) (make_full_observation e None r p t)"
|
alw (nxt (state_eq None)) (make_full_observation ?e None ?r ?p ?t)
|
?H1 (?H2 (?H3 ?H4)) (?H5 x_1 ?H4 x_2 x_3 x_4)
|
[
"EFSM_LTL.make_full_observation",
"Option.option.None",
"EFSM_LTL.state_eq",
"Linear_Temporal_Logic_on_Streams.nxt",
"Linear_Temporal_Logic_on_Streams.alw"
] |
[
"((nat \\<times> nat) \\<times> transition) fset \\<Rightarrow> nat option \\<Rightarrow> nat \\<Rightarrow>f value option \\<Rightarrow> value option list \\<Rightarrow> (String.literal \\<times> value list) stream \\<Rightarrow> state stream",
"'a option",
"nat option \\<Rightarrow> state stream \\<Rightarrow> bool",
"('a stream \\<Rightarrow> 'b) \\<Rightarrow> 'a stream \\<Rightarrow> 'b",
"('a stream \\<Rightarrow> bool) \\<Rightarrow> 'a stream \\<Rightarrow> bool"
] |
[
"primcorec make_full_observation :: \"transition_matrix \\<Rightarrow> cfstate option \\<Rightarrow> registers \\<Rightarrow> outputs \\<Rightarrow> action stream \\<Rightarrow> whitebox_trace\" where\n \"make_full_observation e s d p i = (\n let (s', o', d') = ltl_step e s d (shd i) in\n \\<lparr>statename = s, datastate = d, action=(shd i), output = p\\<rparr>##(make_full_observation e s' d' o' (stl i))\n )\"",
"datatype 'a option =\n None\n | Some (the: 'a)",
"abbreviation state_eq :: \"cfstate option \\<Rightarrow> whitebox_trace \\<Rightarrow> bool\" where\n \"state_eq v s \\<equiv> statename (shd s) = v\"",
"fun nxt where \"nxt \\<phi> xs = \\<phi> (stl xs)\"",
"coinductive alw for \\<phi> where\nalw: \"\\<lbrakk>\\<phi> xs; alw \\<phi> (stl xs)\\<rbrakk> \\<Longrightarrow> alw \\<phi> xs\"\n\n\\<comment> \\<open>weak until:\\<close>"
] |
lemma_object
|
###symbols
EFSM_LTL.make_full_observation :::: ((nat \<times> nat) \<times> transition) fset \<Rightarrow> nat option \<Rightarrow> nat \<Rightarrow>f value option \<Rightarrow> value option list \<Rightarrow> (String.literal \<times> value list) stream \<Rightarrow> state stream
Option.option.None :::: 'a option
EFSM_LTL.state_eq :::: nat option \<Rightarrow> state stream \<Rightarrow> bool
Linear_Temporal_Logic_on_Streams.nxt :::: ('a stream \<Rightarrow> 'b) \<Rightarrow> 'a stream \<Rightarrow> 'b
Linear_Temporal_Logic_on_Streams.alw :::: ('a stream \<Rightarrow> bool) \<Rightarrow> 'a stream \<Rightarrow> bool
###defs
primcorec make_full_observation :: "transition_matrix \<Rightarrow> cfstate option \<Rightarrow> registers \<Rightarrow> outputs \<Rightarrow> action stream \<Rightarrow> whitebox_trace" where
"make_full_observation e s d p i = (
let (s', o', d') = ltl_step e s d (shd i) in
\<lparr>statename = s, datastate = d, action=(shd i), output = p\<rparr>##(make_full_observation e s' d' o' (stl i))
)"
datatype 'a option =
None
| Some (the: 'a)
abbreviation state_eq :: "cfstate option \<Rightarrow> whitebox_trace \<Rightarrow> bool" where
"state_eq v s \<equiv> statename (shd s) = v"
fun nxt where "nxt \<phi> xs = \<phi> (stl xs)"
coinductive alw for \<phi> where
alw: "\<lbrakk>\<phi> xs; alw \<phi> (stl xs)\<rbrakk> \<Longrightarrow> alw \<phi> xs"
\<comment> \<open>weak until:\<close>
|
###output
alw (nxt (state_eq None)) (make_full_observation ?e None ?r ?p ?t)###end
|
Incompleteness/II_Prelims
|
II_Prelims.ShiftP_Mem2
|
lemma ShiftP_Mem2:
assumes "atom u \<sharp> (f,k,del,a,b)"
shows "{ShiftP f k del g, HPair a b IN g} \<turnstile> Ex u ((Var u) IN k AND HaddP del (Var u) a AND HPair (Var u) b IN f)"
|
atom ?u \<sharp> (?f, ?k, ?del, ?a, ?b) \<Longrightarrow> {ShiftP ?f ?k ?del ?g, HPair ?a ?b IN ?g} \<turnstile> SyntaxN.Ex ?u (Var ?u IN ?k AND HaddP ?del (Var ?u) ?a AND HPair (Var ?u) ?b IN ?f)
|
?H1 (?H2 x_1) (x_2, x_3, x_4, x_5, x_6) \<Longrightarrow> ?H3 (?H4 (?H5 x_2 x_3 x_4 x_7) (?H4 (?H6 (?H7 x_5 x_6) x_7) ?H8)) (?H9 x_1 (?H10 (?H6 (?H11 x_1) x_3) (?H10 (?H12 x_4 (?H11 x_1) x_5) (?H6 (?H7 (?H11 x_1) x_6) x_2))))
|
[
"II_Prelims.HaddP",
"SyntaxN.Var",
"SyntaxN.Conj",
"SyntaxN.Ex",
"Set.empty",
"SyntaxN.HPair",
"SyntaxN.Mem",
"II_Prelims.ShiftP",
"Set.insert",
"SyntaxN.hfthm",
"Nominal2_Base.at_base_class.atom",
"Nominal2_Base.pt_class.fresh"
] |
[
"tm \\<Rightarrow> tm \\<Rightarrow> tm \\<Rightarrow> fm",
"name \\<Rightarrow> tm",
"fm \\<Rightarrow> fm \\<Rightarrow> fm",
"name \\<Rightarrow> fm \\<Rightarrow> fm",
"'a set",
"tm \\<Rightarrow> tm \\<Rightarrow> tm",
"tm \\<Rightarrow> tm \\<Rightarrow> fm",
"tm \\<Rightarrow> tm \\<Rightarrow> tm \\<Rightarrow> tm \\<Rightarrow> fm",
"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set",
"fm set \\<Rightarrow> fm \\<Rightarrow> bool",
"'a \\<Rightarrow> atom",
"atom \\<Rightarrow> 'a \\<Rightarrow> bool"
] |
[
"definition Conj :: \"fm \\<Rightarrow> fm \\<Rightarrow> fm\" (infixr \"AND\" 135)\n where \"Conj A B \\<equiv> Neg (Disj (Neg A) (Neg B))\"",
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"definition HPair :: \"tm \\<Rightarrow> tm \\<Rightarrow> tm\"\n where \"HPair a b = Eats (Eats Zero (Eats (Eats Zero b) a)) (Eats (Eats Zero a) a)\"",
"definition insert :: \"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set\"\n where insert_compr: \"insert a B = {x. x = a \\<or> x \\<in> B}\"",
"inductive hfthm :: \"fm set \\<Rightarrow> fm \\<Rightarrow> bool\" (infixl \"\\<turnstile>\" 55)\n where\n Hyp: \"A \\<in> H \\<Longrightarrow> H \\<turnstile> A\"\n | Extra: \"H \\<turnstile> extra_axiom\"\n | Bool: \"A \\<in> boolean_axioms \\<Longrightarrow> H \\<turnstile> A\"\n | Eq: \"A \\<in> equality_axioms \\<Longrightarrow> H \\<turnstile> A\"\n | Spec: \"A \\<in> special_axioms \\<Longrightarrow> H \\<turnstile> A\"\n | HF: \"A \\<in> HF_axioms \\<Longrightarrow> H \\<turnstile> A\"\n | Ind: \"A \\<in> induction_axioms \\<Longrightarrow> H \\<turnstile> A\"\n | MP: \"H \\<turnstile> A IMP B \\<Longrightarrow> H' \\<turnstile> A \\<Longrightarrow> H \\<union> H' \\<turnstile> B\"\n | Exists: \"H \\<turnstile> A IMP B \\<Longrightarrow> atom i \\<sharp> B \\<Longrightarrow> \\<forall>C \\<in> H. atom i \\<sharp> C \\<Longrightarrow> H \\<turnstile> (Ex i A) IMP B\"",
"class at_base = pt +\n fixes atom :: \"'a \\<Rightarrow> atom\"\n assumes atom_eq_iff [simp]: \"atom a = atom b \\<longleftrightarrow> a = b\"\n assumes atom_eqvt: \"p \\<bullet> (atom a) = atom (p \\<bullet> a)\"",
"class pt =\n fixes permute :: \"perm \\<Rightarrow> 'a \\<Rightarrow> 'a\" (\"_ \\<bullet> _\" [76, 75] 75)\n assumes permute_zero [simp]: \"0 \\<bullet> x = x\"\n assumes permute_plus [simp]: \"(p + q) \\<bullet> x = p \\<bullet> (q \\<bullet> x)\"\nbegin"
] |
lemma_object
|
###symbols
II_Prelims.HaddP :::: tm \<Rightarrow> tm \<Rightarrow> tm \<Rightarrow> fm
SyntaxN.Var :::: name \<Rightarrow> tm
SyntaxN.Conj :::: fm \<Rightarrow> fm \<Rightarrow> fm
SyntaxN.Ex :::: name \<Rightarrow> fm \<Rightarrow> fm
Set.empty :::: 'a set
SyntaxN.HPair :::: tm \<Rightarrow> tm \<Rightarrow> tm
SyntaxN.Mem :::: tm \<Rightarrow> tm \<Rightarrow> fm
II_Prelims.ShiftP :::: tm \<Rightarrow> tm \<Rightarrow> tm \<Rightarrow> tm \<Rightarrow> fm
Set.insert :::: 'a \<Rightarrow> 'a set \<Rightarrow> 'a set
SyntaxN.hfthm :::: fm set \<Rightarrow> fm \<Rightarrow> bool
Nominal2_Base.at_base_class.atom :::: 'a \<Rightarrow> atom
Nominal2_Base.pt_class.fresh :::: atom \<Rightarrow> 'a \<Rightarrow> bool
###defs
definition Conj :: "fm \<Rightarrow> fm \<Rightarrow> fm" (infixr "AND" 135)
where "Conj A B \<equiv> Neg (Disj (Neg A) (Neg B))"
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
definition HPair :: "tm \<Rightarrow> tm \<Rightarrow> tm"
where "HPair a b = Eats (Eats Zero (Eats (Eats Zero b) a)) (Eats (Eats Zero a) a)"
definition insert :: "'a \<Rightarrow> 'a set \<Rightarrow> 'a set"
where insert_compr: "insert a B = {x. x = a \<or> x \<in> B}"
inductive hfthm :: "fm set \<Rightarrow> fm \<Rightarrow> bool" (infixl "\<turnstile>" 55)
where
Hyp: "A \<in> H \<Longrightarrow> H \<turnstile> A"
| Extra: "H \<turnstile> extra_axiom"
| Bool: "A \<in> boolean_axioms \<Longrightarrow> H \<turnstile> A"
| Eq: "A \<in> equality_axioms \<Longrightarrow> H \<turnstile> A"
| Spec: "A \<in> special_axioms \<Longrightarrow> H \<turnstile> A"
| HF: "A \<in> HF_axioms \<Longrightarrow> H \<turnstile> A"
| Ind: "A \<in> induction_axioms \<Longrightarrow> H \<turnstile> A"
| MP: "H \<turnstile> A IMP B \<Longrightarrow> H' \<turnstile> A \<Longrightarrow> H \<union> H' \<turnstile> B"
| Exists: "H \<turnstile> A IMP B \<Longrightarrow> atom i \<sharp> B \<Longrightarrow> \<forall>C \<in> H. atom i \<sharp> C \<Longrightarrow> H \<turnstile> (Ex i A) IMP B"
class at_base = pt +
fixes atom :: "'a \<Rightarrow> atom"
assumes atom_eq_iff [simp]: "atom a = atom b \<longleftrightarrow> a = b"
assumes atom_eqvt: "p \<bullet> (atom a) = atom (p \<bullet> a)"
class pt =
fixes permute :: "perm \<Rightarrow> 'a \<Rightarrow> 'a" ("_ \<bullet> _" [76, 75] 75)
assumes permute_zero [simp]: "0 \<bullet> x = x"
assumes permute_plus [simp]: "(p + q) \<bullet> x = p \<bullet> (q \<bullet> x)"
begin
|
###output
atom ?u \<sharp> (?f, ?k, ?del, ?a, ?b) \<Longrightarrow> {ShiftP ?f ?k ?del ?g, HPair ?a ?b IN ?g} \<turnstile> SyntaxN.Ex ?u (Var ?u IN ?k AND HaddP ?del (Var ?u) ?a AND HPair (Var ?u) ?b IN ?f)###end
|
UPF_Firewall/FWNormalisation/NormalisationIPPProofs
|
NormalisationIPPProofs.C_eqLemmas_id(23)
| null |
OnlyTwoNets ?p \<Longrightarrow> NetsCollected2 ?p \<Longrightarrow> NetsCollected ?p \<Longrightarrow> noDenyAll1 ?p \<Longrightarrow> allNetsDistinct ?p \<Longrightarrow> separated ?p
|
\<lbrakk> ?H1 x_1; ?H2 x_1; ?H3 x_1; ?H4 x_1; ?H5 x_1\<rbrakk> \<Longrightarrow> ?H6 x_1
|
[
"FWNormalisationCore.separated",
"FWNormalisationCore.allNetsDistinct",
"FWNormalisationCore.noDenyAll1",
"FWNormalisationCore.NetsCollected",
"FWNormalisationCore.NetsCollected2",
"FWNormalisationCore.OnlyTwoNets"
] |
[
"('a set set, 'b) Combinators list \\<Rightarrow> bool",
"('a set set, 'b) Combinators list \\<Rightarrow> bool",
"('a, 'b) Combinators list \\<Rightarrow> bool",
"('a, 'b) Combinators list \\<Rightarrow> bool",
"('a, 'b) Combinators list \\<Rightarrow> bool",
"('a, 'b) Combinators list \\<Rightarrow> bool"
] |
[] |
lemma_object
|
###symbols
FWNormalisationCore.separated :::: ('a set set, 'b) Combinators list \<Rightarrow> bool
FWNormalisationCore.allNetsDistinct :::: ('a set set, 'b) Combinators list \<Rightarrow> bool
FWNormalisationCore.noDenyAll1 :::: ('a, 'b) Combinators list \<Rightarrow> bool
FWNormalisationCore.NetsCollected :::: ('a, 'b) Combinators list \<Rightarrow> bool
FWNormalisationCore.NetsCollected2 :::: ('a, 'b) Combinators list \<Rightarrow> bool
FWNormalisationCore.OnlyTwoNets :::: ('a, 'b) Combinators list \<Rightarrow> bool
###defs
|
###output
OnlyTwoNets ?p \<Longrightarrow> NetsCollected2 ?p \<Longrightarrow> NetsCollected ?p \<Longrightarrow> noDenyAll1 ?p \<Longrightarrow> allNetsDistinct ?p \<Longrightarrow> separated ?p###end
|
Affine_Arithmetic/Straight_Line_Program
|
Straight_Line_Program.comparator_floatarith_simps(289)
| null |
comparator_floatarith (floatarith.Var ?x) (floatarith.Add ?y ?ya) = Gt
|
?H1 (?H2 x_1) (?H3 x_2 x_3) = ?H4
|
[
"Comparator.order.Gt",
"Approximation.floatarith.Add",
"Approximation.floatarith.Var",
"Straight_Line_Program.comparator_floatarith"
] |
[
"order",
"floatarith \\<Rightarrow> floatarith \\<Rightarrow> floatarith",
"nat \\<Rightarrow> floatarith",
"floatarith \\<Rightarrow> floatarith \\<Rightarrow> order"
] |
[
"datatype floatarith\n = Add floatarith floatarith\n | Minus floatarith\n | Mult floatarith floatarith\n | Inverse floatarith\n | Cos floatarith\n | Arctan floatarith\n | Abs floatarith\n | Max floatarith floatarith\n | Min floatarith floatarith\n | Pi\n | Sqrt floatarith\n | Exp floatarith\n | Powr floatarith floatarith\n | Ln floatarith\n | Power floatarith nat\n | Floor floatarith\n | Var nat\n | Num float",
"datatype floatarith\n = Add floatarith floatarith\n | Minus floatarith\n | Mult floatarith floatarith\n | Inverse floatarith\n | Cos floatarith\n | Arctan floatarith\n | Abs floatarith\n | Max floatarith floatarith\n | Min floatarith floatarith\n | Pi\n | Sqrt floatarith\n | Exp floatarith\n | Powr floatarith floatarith\n | Ln floatarith\n | Power floatarith nat\n | Floor floatarith\n | Var nat\n | Num float"
] |
lemma_object
|
###symbols
Comparator.order.Gt :::: order
Approximation.floatarith.Add :::: floatarith \<Rightarrow> floatarith \<Rightarrow> floatarith
Approximation.floatarith.Var :::: nat \<Rightarrow> floatarith
Straight_Line_Program.comparator_floatarith :::: floatarith \<Rightarrow> floatarith \<Rightarrow> order
###defs
datatype floatarith
= Add floatarith floatarith
| Minus floatarith
| Mult floatarith floatarith
| Inverse floatarith
| Cos floatarith
| Arctan floatarith
| Abs floatarith
| Max floatarith floatarith
| Min floatarith floatarith
| Pi
| Sqrt floatarith
| Exp floatarith
| Powr floatarith floatarith
| Ln floatarith
| Power floatarith nat
| Floor floatarith
| Var nat
| Num float
datatype floatarith
= Add floatarith floatarith
| Minus floatarith
| Mult floatarith floatarith
| Inverse floatarith
| Cos floatarith
| Arctan floatarith
| Abs floatarith
| Max floatarith floatarith
| Min floatarith floatarith
| Pi
| Sqrt floatarith
| Exp floatarith
| Powr floatarith floatarith
| Ln floatarith
| Power floatarith nat
| Floor floatarith
| Var nat
| Num float
|
###output
comparator_floatarith (floatarith.Var ?x) (floatarith.Add ?y ?ya) = Gt###end
|
S_Finite_Measure_Monad/Measure_QuasiBorel_Adjunction
|
Measure_QuasiBorel_Adjunction.qbs_Mx_subset_of_measurable
|
lemma qbs_Mx_subset_of_measurable: "qbs_Mx X \<subseteq> borel \<rightarrow>\<^sub>M qbs_to_measure X"
|
qbs_Mx ?X \<subseteq> borel \<rightarrow>\<^sub>M qbs_to_measure ?X
|
?H1 (?H2 x_1) (?H3 ?H4 (?H5 x_1))
|
[
"Measure_QuasiBorel_Adjunction.qbs_to_measure",
"Borel_Space.topological_space_class.borel",
"Sigma_Algebra.measurable",
"QuasiBorel.qbs_Mx",
"Set.subset_eq"
] |
[
"'a quasi_borel \\<Rightarrow> 'a measure",
"'a measure",
"'a measure \\<Rightarrow> 'b measure \\<Rightarrow> ('a \\<Rightarrow> 'b) set",
"'a quasi_borel \\<Rightarrow> (real \\<Rightarrow> 'a) set",
"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"definition qbs_to_measure :: \"'a quasi_borel \\<Rightarrow> 'a measure\" where\n\"qbs_to_measure X \\<equiv> Abs_measure (qbs_space X, sigma_Mx X, \\<lambda>A. (if A = {} then 0 else if A \\<in> - sigma_Mx X then 0 else \\<infinity>))\"",
"definition qbs_Mx :: \"'a quasi_borel \\<Rightarrow> (real \\<Rightarrow> 'a) set\" where\n \"qbs_Mx X \\<equiv> snd (Rep_quasi_borel X)\"",
"abbreviation subset_eq :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool\"\n where \"subset_eq \\<equiv> less_eq\""
] |
lemma_object
|
###symbols
Measure_QuasiBorel_Adjunction.qbs_to_measure :::: 'a quasi_borel \<Rightarrow> 'a measure
Borel_Space.topological_space_class.borel :::: 'a measure
Sigma_Algebra.measurable :::: 'a measure \<Rightarrow> 'b measure \<Rightarrow> ('a \<Rightarrow> 'b) set
QuasiBorel.qbs_Mx :::: 'a quasi_borel \<Rightarrow> (real \<Rightarrow> 'a) set
Set.subset_eq :::: 'a set \<Rightarrow> 'a set \<Rightarrow> bool
###defs
definition qbs_to_measure :: "'a quasi_borel \<Rightarrow> 'a measure" where
"qbs_to_measure X \<equiv> Abs_measure (qbs_space X, sigma_Mx X, \<lambda>A. (if A = {} then 0 else if A \<in> - sigma_Mx X then 0 else \<infinity>))"
definition qbs_Mx :: "'a quasi_borel \<Rightarrow> (real \<Rightarrow> 'a) set" where
"qbs_Mx X \<equiv> snd (Rep_quasi_borel X)"
abbreviation subset_eq :: "'a set \<Rightarrow> 'a set \<Rightarrow> bool"
where "subset_eq \<equiv> less_eq"
|
###output
qbs_Mx ?X \<subseteq> borel \<rightarrow>\<^sub>M qbs_to_measure ?X###end
|
Multirelations_Heterogeneous/Multirelations
|
Multirelations_Basics.d_lb2
| null |
Dom ?R * Dom ?S \<subseteq> Dom ?S
|
?H1 (?H2 (?H3 x_1) (?H4 x_2)) (?H4 x_2)
|
[
"Multirelations_Basics.Dom",
"Multirelations_Basics.s_prod",
"Set.subset_eq"
] |
[
"('a \\<times> 'b set) set \\<Rightarrow> ('a \\<times> 'a set) set",
"('a \\<times> 'b set) set \\<Rightarrow> ('b \\<times> 'c set) set \\<Rightarrow> ('a \\<times> 'c set) set",
"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"definition Dom :: \"('a,'b) mrel \\<Rightarrow> ('a,'a) mrel\" where\n \"Dom R = {(a,{a}) |a. \\<exists>B. (a,B) \\<in> R}\"",
"definition s_prod :: \"('a,'b) mrel \\<Rightarrow> ('b,'c) mrel \\<Rightarrow> ('a,'c) mrel\" (infixl \"\\<cdot>\" 75) where\n \"R \\<cdot> S = {(a,A). (\\<exists>B. (a,B) \\<in> R \\<and> (\\<exists>f. (\\<forall>b \\<in> B. (b,f b) \\<in> S) \\<and> A = \\<Union>(f ` B)))}\"",
"abbreviation subset_eq :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool\"\n where \"subset_eq \\<equiv> less_eq\""
] |
lemma_object
|
###symbols
Multirelations_Basics.Dom :::: ('a \<times> 'b set) set \<Rightarrow> ('a \<times> 'a set) set
Multirelations_Basics.s_prod :::: ('a \<times> 'b set) set \<Rightarrow> ('b \<times> 'c set) set \<Rightarrow> ('a \<times> 'c set) set
Set.subset_eq :::: 'a set \<Rightarrow> 'a set \<Rightarrow> bool
###defs
definition Dom :: "('a,'b) mrel \<Rightarrow> ('a,'a) mrel" where
"Dom R = {(a,{a}) |a. \<exists>B. (a,B) \<in> R}"
definition s_prod :: "('a,'b) mrel \<Rightarrow> ('b,'c) mrel \<Rightarrow> ('a,'c) mrel" (infixl "\<cdot>" 75) where
"R \<cdot> S = {(a,A). (\<exists>B. (a,B) \<in> R \<and> (\<exists>f. (\<forall>b \<in> B. (b,f b) \<in> S) \<and> A = \<Union>(f ` B)))}"
abbreviation subset_eq :: "'a set \<Rightarrow> 'a set \<Rightarrow> bool"
where "subset_eq \<equiv> less_eq"
|
###output
Dom ?R * Dom ?S \<subseteq> Dom ?S###end
|
CZH_Foundations/czh_sets/CZH_Sets_BRelations
|
CZH_Sets_BRelations.app_vrangeE
|
lemma app_vrangeE[elim]:
assumes "b \<in>\<^sub>\<circ> \<R>\<^sub>\<circ> r"
obtains a where "\<langle>a, b\<rangle> \<in>\<^sub>\<circ> r"
|
?b \<in>\<^sub>\<circ> \<R>\<^sub>\<circ> ?r \<Longrightarrow> (\<And>a. \<langle>a, ?b\<rangle> \<in>\<^sub>\<circ> ?r \<Longrightarrow> ?thesis) \<Longrightarrow> ?thesis
|
\<lbrakk> ?H1 x_1 (?H2 x_2); \<And>y_0. ?H1 (?H3 y_0 x_1) x_2 \<Longrightarrow> x_3\<rbrakk> \<Longrightarrow> x_3
|
[
"ZFC_Cardinals.vpair",
"CZH_Sets_BRelations.app_vrange",
"CZH_Sets_Sets.vmember"
] |
[
"V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> bool"
] |
[
"definition vpair :: \"V \\<Rightarrow> V \\<Rightarrow> V\"\n where \"vpair a b = set {set {a},set {a,b}}\""
] |
lemma_object
|
###symbols
ZFC_Cardinals.vpair :::: V \<Rightarrow> V \<Rightarrow> V
CZH_Sets_BRelations.app_vrange :::: V \<Rightarrow> V
CZH_Sets_Sets.vmember :::: V \<Rightarrow> V \<Rightarrow> bool
###defs
definition vpair :: "V \<Rightarrow> V \<Rightarrow> V"
where "vpair a b = set {set {a},set {a,b}}"
|
###output
?b \<in>\<^sub>\<circ> \<R>\<^sub>\<circ> ?r \<Longrightarrow> (\<And>a. \<langle>a, ?b\<rangle> \<in>\<^sub>\<circ> ?r \<Longrightarrow> ?thesis) \<Longrightarrow> ?thesis###end
|
Coproduct_Measure/Coproduct_Measure
|
Coproduct_Measure.emeasure_coPiM_finite
|
lemma emeasure_coPiM_finite:
assumes "finite I" "A \<in> sets (coPiM I Mi)"
shows "emeasure (coPiM I Mi) A = (\<Sum>i\<in>I. emeasure (Mi i) (Pair i -` A))"
|
finite ?I \<Longrightarrow> ?A \<in> sets (coPiM ?I ?Mi) \<Longrightarrow> emeasure (coPiM ?I ?Mi) ?A = (\<Sum>i\<in> ?I. emeasure (?Mi i) (Pair i -` ?A))
|
\<lbrakk> ?H1 x_1; x_2 \<in> ?H2 (?H3 x_1 x_3)\<rbrakk> \<Longrightarrow> ?H4 (?H3 x_1 x_3) x_2 = ?H5 (\<lambda>y_0. ?H6 (x_3 y_0) (?H7 (Pair y_0) x_2)) x_1
|
[
"Set.vimage",
"Groups_Big.comm_monoid_add_class.sum",
"Sigma_Algebra.emeasure",
"Coproduct_Measure.coPiM",
"Sigma_Algebra.sets",
"Finite_Set.finite"
] |
[
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'b set \\<Rightarrow> 'a set",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a set \\<Rightarrow> 'b",
"'a measure \\<Rightarrow> 'a set \\<Rightarrow> ennreal",
"'a set \\<Rightarrow> ('a \\<Rightarrow> 'b measure) \\<Rightarrow> ('a \\<times> 'b) measure",
"'a measure \\<Rightarrow> 'a set set",
"'a set \\<Rightarrow> bool"
] |
[
"definition vimage :: \"('a \\<Rightarrow> 'b) \\<Rightarrow> 'b set \\<Rightarrow> 'a set\" (infixr \"-`\" 90)\n where \"f -` B \\<equiv> {x. f x \\<in> B}\"",
"definition coPiM :: \"['i set, 'i \\<Rightarrow> 'a measure] \\<Rightarrow> ('i \\<times> 'a) measure\" where\n\"coPiM I Mi \\<equiv> measure_of\n (SIGMA i:I. space (Mi i))\n {A. A\\<subseteq>(SIGMA i:I. space (Mi i)) \\<and> (\\<forall>i\\<in>I. Pair i -` A \\<in> sets (Mi i))}\n (\\<lambda>A. (\\<Sum>\\<^sub>\\<infinity>i\\<in>I. emeasure (Mi i) (Pair i -` A)))\"",
"class finite =\n assumes finite_UNIV: \"finite (UNIV :: 'a set)\"\nbegin"
] |
lemma_object
|
###symbols
Set.vimage :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'b set \<Rightarrow> 'a set
Groups_Big.comm_monoid_add_class.sum :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a set \<Rightarrow> 'b
Sigma_Algebra.emeasure :::: 'a measure \<Rightarrow> 'a set \<Rightarrow> ennreal
Coproduct_Measure.coPiM :::: 'a set \<Rightarrow> ('a \<Rightarrow> 'b measure) \<Rightarrow> ('a \<times> 'b) measure
Sigma_Algebra.sets :::: 'a measure \<Rightarrow> 'a set set
Finite_Set.finite :::: 'a set \<Rightarrow> bool
###defs
definition vimage :: "('a \<Rightarrow> 'b) \<Rightarrow> 'b set \<Rightarrow> 'a set" (infixr "-`" 90)
where "f -` B \<equiv> {x. f x \<in> B}"
definition coPiM :: "['i set, 'i \<Rightarrow> 'a measure] \<Rightarrow> ('i \<times> 'a) measure" where
"coPiM I Mi \<equiv> measure_of
(SIGMA i:I. space (Mi i))
{A. A\<subseteq>(SIGMA i:I. space (Mi i)) \<and> (\<forall>i\<in>I. Pair i -` A \<in> sets (Mi i))}
(\<lambda>A. (\<Sum>\<^sub>\<infinity>i\<in>I. emeasure (Mi i) (Pair i -` A)))"
class finite =
assumes finite_UNIV: "finite (UNIV :: 'a set)"
begin
|
###output
finite ?I \<Longrightarrow> ?A \<in> sets (coPiM ?I ?Mi) \<Longrightarrow> emeasure (coPiM ?I ?Mi) ?A = (\<Sum>i\<in> ?I. emeasure (?Mi i) (Pair i -` ?A))###end
|
Slicing/JinjaVM/JVMCFG
|
JVMCFG.nth_tl
|
lemma nth_tl : "xs \<noteq> [] \<Longrightarrow> tl xs ! n = xs ! (Suc n)"
|
?xs \<noteq> [] \<Longrightarrow> tl ?xs ! ?n = ?xs ! Suc ?n
|
x_1 \<noteq> ?H1 \<Longrightarrow> ?H2 (?H3 x_1) x_2 = ?H2 x_1 (?H4 x_2)
|
[
"Nat.Suc",
"List.list.tl",
"List.nth",
"List.list.Nil"
] |
[
"nat \\<Rightarrow> nat",
"'a list \\<Rightarrow> 'a list",
"'a list \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a list"
] |
[
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec (nonexhaustive) nth :: \"'a list => nat => 'a\" (infixl \"!\" 100) where\nnth_Cons: \"(x # xs) ! n = (case n of 0 \\<Rightarrow> x | Suc k \\<Rightarrow> xs ! k)\"\n \\<comment> \\<open>Warning: simpset does not contain this definition, but separate\n theorems for \\<open>n = 0\\<close> and \\<open>n = Suc k\\<close>\\<close>",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\""
] |
lemma_object
|
###symbols
Nat.Suc :::: nat \<Rightarrow> nat
List.list.tl :::: 'a list \<Rightarrow> 'a list
List.nth :::: 'a list \<Rightarrow> nat \<Rightarrow> 'a
List.list.Nil :::: 'a list
###defs
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec (nonexhaustive) nth :: "'a list => nat => 'a" (infixl "!" 100) where
nth_Cons: "(x # xs) ! n = (case n of 0 \<Rightarrow> x | Suc k \<Rightarrow> xs ! k)"
\<comment> \<open>Warning: simpset does not contain this definition, but separate
theorems for \<open>n = 0\<close> and \<open>n = Suc k\<close>\<close>
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
|
###output
?xs \<noteq> [] \<Longrightarrow> tl ?xs ! ?n = ?xs ! Suc ?n###end
|
AODV/variants/b_fwdrreps/B_Aodv
|
B_Aodv_Data.iD_addpreRT
| null |
?dip \<in> kD ?rt \<Longrightarrow> iD (the (addpreRT ?rt ?dip ?npre)) = iD ?rt
|
x_1 \<in> ?H1 x_2 \<Longrightarrow> ?H2 (?H3 (?H4 x_2 x_1 x_3)) = ?H2 x_2
|
[
"B_Aodv_Data.addpreRT",
"Option.option.the",
"B_Aodv_Data.iD",
"B_Aodv_Data.kD"
] |
[
"(nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option) \\<Rightarrow> nat \\<Rightarrow> nat set \\<Rightarrow> (nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option) option",
"'a option \\<Rightarrow> 'a",
"(nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option) \\<Rightarrow> nat set",
"(nat \\<Rightarrow> (nat \\<times> k \\<times> f \\<times> nat \\<times> nat \\<times> nat set) option) \\<Rightarrow> nat set"
] |
[
"datatype 'a option =\n None\n | Some (the: 'a)"
] |
lemma_object
|
###symbols
B_Aodv_Data.addpreRT :::: (nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option) \<Rightarrow> nat \<Rightarrow> nat set \<Rightarrow> (nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option) option
Option.option.the :::: 'a option \<Rightarrow> 'a
B_Aodv_Data.iD :::: (nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option) \<Rightarrow> nat set
B_Aodv_Data.kD :::: (nat \<Rightarrow> (nat \<times> k \<times> f \<times> nat \<times> nat \<times> nat set) option) \<Rightarrow> nat set
###defs
datatype 'a option =
None
| Some (the: 'a)
|
###output
?dip \<in> kD ?rt \<Longrightarrow> iD (the (addpreRT ?rt ?dip ?npre)) = iD ?rt###end
|
Word_Lib/More_Word
|
More_Word.word_less_sub_1
|
lemma word_less_sub_1:
"x < (y :: 'a :: len word) \<Longrightarrow> x \<le> y - 1"
|
?x < ?y \<Longrightarrow> ?x \<le> ?y - 1
|
x_1 < x_2 \<Longrightarrow> x_1 \<le> ?H1 x_2 ?H2
|
[
"Groups.one_class.one",
"Groups.minus_class.minus"
] |
[
"'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a"
] |
[
"class one =\n fixes one :: 'a (\"1\")",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)"
] |
lemma_object
|
###symbols
Groups.one_class.one :::: 'a
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
###defs
class one =
fixes one :: 'a ("1")
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
|
###output
?x < ?y \<Longrightarrow> ?x \<le> ?y - 1###end
|
Berlekamp_Zassenhaus/Square_Free_Factorization_Int
|
Square_Free_Factorization_Int.square_free_factorization_int'(3)
|
lemma square_free_factorization_int': assumes res: "square_free_factorization_int' f = (d, fs)"
shows "square_free_factorization f (d,fs)"
"(fi, i) \<in> set fs \<Longrightarrow> content fi = 1 \<and> lead_coeff fi > 0"
"distinct (map snd fs)"
|
square_free_factorization_int' ?f = (?d, ?fs) \<Longrightarrow> distinct (map snd ?fs)
|
?H1 x_1 = (x_2, x_3) \<Longrightarrow> ?H2 (?H3 ?H4 x_3)
|
[
"Product_Type.prod.snd",
"List.list.map",
"List.distinct",
"Square_Free_Factorization_Int.square_free_factorization_int'"
] |
[
"'a \\<times> 'b \\<Rightarrow> 'b",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a list \\<Rightarrow> 'b list",
"'a list \\<Rightarrow> bool",
"int poly \\<Rightarrow> int \\<times> (int poly \\<times> nat) list"
] |
[
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec distinct :: \"'a list \\<Rightarrow> bool\" where\n\"distinct [] \\<longleftrightarrow> True\" |\n\"distinct (x # xs) \\<longleftrightarrow> x \\<notin> set xs \\<and> distinct xs\"",
"definition square_free_factorization_int' :: \"int poly \\<Rightarrow> int \\<times> (int poly \\<times> nat)list\" where\n \"square_free_factorization_int' f = (if degree f = 0\n then (lead_coeff f,[]) else (let \\<comment> \\<open>content factorization\\<close>\n c = content f;\n d = (sgn (lead_coeff f) * c);\n g = sdiv_poly f d\n \\<comment> \\<open>and \\<open>square_free\\<close> factorization\\<close>\n in (d, square_free_factorization_int_main g)))\""
] |
lemma_object
|
###symbols
Product_Type.prod.snd :::: 'a \<times> 'b \<Rightarrow> 'b
List.list.map :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a list \<Rightarrow> 'b list
List.distinct :::: 'a list \<Rightarrow> bool
Square_Free_Factorization_Int.square_free_factorization_int' :::: int poly \<Rightarrow> int \<times> (int poly \<times> nat) list
###defs
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec distinct :: "'a list \<Rightarrow> bool" where
"distinct [] \<longleftrightarrow> True" |
"distinct (x # xs) \<longleftrightarrow> x \<notin> set xs \<and> distinct xs"
definition square_free_factorization_int' :: "int poly \<Rightarrow> int \<times> (int poly \<times> nat)list" where
"square_free_factorization_int' f = (if degree f = 0
then (lead_coeff f,[]) else (let \<comment> \<open>content factorization\<close>
c = content f;
d = (sgn (lead_coeff f) * c);
g = sdiv_poly f d
\<comment> \<open>and \<open>square_free\<close> factorization\<close>
in (d, square_free_factorization_int_main g)))"
|
###output
square_free_factorization_int' ?f = (?d, ?fs) \<Longrightarrow> distinct (map snd ?fs)###end
|
Adaptive_State_Counting/FSM/FSM
|
FSM.path_last_io_target
|
lemma path_last_io_target :
assumes "path M (xs || tr) q"
and "length xs = length tr"
and "length xs > 0"
shows "last tr \<in> io_targets M q xs"
|
path ?M (?xs || ?tr) ?q \<Longrightarrow> length ?xs = length ?tr \<Longrightarrow> 0 < length ?xs \<Longrightarrow> last ?tr \<in> io_targets ?M ?q ?xs
|
\<lbrakk> ?H1 x_1 (?H2 x_2 x_3) x_4; ?H3 x_2 = ?H4 x_3; ?H5 < ?H3 x_2\<rbrakk> \<Longrightarrow> ?H6 x_3 \<in> ?H7 x_1 x_4 x_2
|
[
"FSM.io_targets",
"List.last",
"Groups.zero_class.zero",
"List.length",
"List.zip",
"FSM.path"
] |
[
"('a, 'b, 'c) FSM \\<Rightarrow> 'c \\<Rightarrow> ('a \\<times> 'b) list \\<Rightarrow> 'c set",
"'a list \\<Rightarrow> 'a",
"'a",
"'a list \\<Rightarrow> nat",
"'a list \\<Rightarrow> 'b list \\<Rightarrow> ('a \\<times> 'b) list",
"'a itself \\<Rightarrow> ('b, 'c, 'd, 'a) FSM_scheme \\<Rightarrow> (('b \\<times> 'c) \\<times> 'd) list \\<Rightarrow> 'd \\<Rightarrow> bool"
] |
[
"fun io_targets :: \"('a,'b,'c) fsm \\<Rightarrow> ('b \\<times> 'c) list \\<Rightarrow> 'a \\<Rightarrow> 'a set\" where\n \"io_targets M io q = {target q p | p . path M q p \\<and> p_io p = io}\"",
"primrec (nonexhaustive) last :: \"'a list \\<Rightarrow> 'a\" where\n\"last (x # xs) = (if xs = [] then x else last xs)\"",
"class zero =\n fixes zero :: 'a (\"0\")",
"abbreviation length :: \"'a list \\<Rightarrow> nat\" where\n\"length \\<equiv> size\"",
"primrec zip :: \"'a list \\<Rightarrow> 'b list \\<Rightarrow> ('a \\<times> 'b) list\" where\n\"zip xs [] = []\" |\nzip_Cons: \"zip xs (y # ys) =\n (case xs of [] \\<Rightarrow> [] | z # zs \\<Rightarrow> (z, y) # zip zs ys)\"\n \\<comment> \\<open>Warning: simpset does not contain this definition, but separate\n theorems for \\<open>xs = []\\<close> and \\<open>xs = z # zs\\<close>\\<close>",
"inductive path :: \"('state, 'input, 'output) fsm \\<Rightarrow> 'state \\<Rightarrow> ('state, 'input, 'output) path \\<Rightarrow> bool\" \n where\n nil[intro!] : \"q \\<in> states M \\<Longrightarrow> path M q []\" |\n cons[intro!] : \"t \\<in> transitions M \\<Longrightarrow> path M (t_target t) ts \\<Longrightarrow> path M (t_source t) (t#ts)\""
] |
lemma_object
|
###symbols
FSM.io_targets :::: ('a, 'b, 'c) FSM \<Rightarrow> 'c \<Rightarrow> ('a \<times> 'b) list \<Rightarrow> 'c set
List.last :::: 'a list \<Rightarrow> 'a
Groups.zero_class.zero :::: 'a
List.length :::: 'a list \<Rightarrow> nat
List.zip :::: 'a list \<Rightarrow> 'b list \<Rightarrow> ('a \<times> 'b) list
FSM.path :::: 'a itself \<Rightarrow> ('b, 'c, 'd, 'a) FSM_scheme \<Rightarrow> (('b \<times> 'c) \<times> 'd) list \<Rightarrow> 'd \<Rightarrow> bool
###defs
fun io_targets :: "('a,'b,'c) fsm \<Rightarrow> ('b \<times> 'c) list \<Rightarrow> 'a \<Rightarrow> 'a set" where
"io_targets M io q = {target q p | p . path M q p \<and> p_io p = io}"
primrec (nonexhaustive) last :: "'a list \<Rightarrow> 'a" where
"last (x # xs) = (if xs = [] then x else last xs)"
class zero =
fixes zero :: 'a ("0")
abbreviation length :: "'a list \<Rightarrow> nat" where
"length \<equiv> size"
primrec zip :: "'a list \<Rightarrow> 'b list \<Rightarrow> ('a \<times> 'b) list" where
"zip xs [] = []" |
zip_Cons: "zip xs (y # ys) =
(case xs of [] \<Rightarrow> [] | z # zs \<Rightarrow> (z, y) # zip zs ys)"
\<comment> \<open>Warning: simpset does not contain this definition, but separate
theorems for \<open>xs = []\<close> and \<open>xs = z # zs\<close>\<close>
inductive path :: "('state, 'input, 'output) fsm \<Rightarrow> 'state \<Rightarrow> ('state, 'input, 'output) path \<Rightarrow> bool"
where
nil[intro!] : "q \<in> states M \<Longrightarrow> path M q []" |
cons[intro!] : "t \<in> transitions M \<Longrightarrow> path M (t_target t) ts \<Longrightarrow> path M (t_source t) (t#ts)"
|
###output
path ?M (?xs || ?tr) ?q \<Longrightarrow> length ?xs = length ?tr \<Longrightarrow> 0 < length ?xs \<Longrightarrow> last ?tr \<in> io_targets ?M ?q ?xs###end
|
Pi_Calculus/Rel
|
Relation.Range_empty_iff
| null |
(Range ?r = {}) = (?r = {})
|
(?H1 x_1 = ?H2) = (x_1 = ?H3)
|
[
"Set.empty",
"Relation.Range"
] |
[
"'a set",
"('a \\<times> 'b) set \\<Rightarrow> 'b set"
] |
[
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"inductive_set Range :: \"('a \\<times> 'b) set \\<Rightarrow> 'b set\" for r :: \"('a \\<times> 'b) set\"\n where RangeI [intro]: \"(a, b) \\<in> r \\<Longrightarrow> b \\<in> Range r\""
] |
lemma_object
|
###symbols
Set.empty :::: 'a set
Relation.Range :::: ('a \<times> 'b) set \<Rightarrow> 'b set
###defs
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
inductive_set Range :: "('a \<times> 'b) set \<Rightarrow> 'b set" for r :: "('a \<times> 'b) set"
where RangeI [intro]: "(a, b) \<in> r \<Longrightarrow> b \<in> Range r"
|
###output
(Range ?r = {}) = (?r = {})###end
|
Q0_Metatheory/Boolean_Algebra
|
Boolean_Algebras.inf1E
| null |
(?A \<sqinter> ?B) ?x \<Longrightarrow> (?A ?x \<Longrightarrow> ?B ?x \<Longrightarrow> ?P) \<Longrightarrow> ?P
|
\<lbrakk> ?H1 x_1 x_2 x_3; \<lbrakk>x_1 x_3; x_2 x_3\<rbrakk> \<Longrightarrow> x_4\<rbrakk> \<Longrightarrow> x_4
|
[
"Lattices.inf_class.inf"
] |
[
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a"
] |
[
"class inf =\n fixes inf :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"\\<sqinter>\" 70)"
] |
lemma_object
|
###symbols
Lattices.inf_class.inf :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
###defs
class inf =
fixes inf :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "\<sqinter>" 70)
|
###output
(?A \<sqinter> ?B) ?x \<Longrightarrow> (?A ?x \<Longrightarrow> ?B ?x \<Longrightarrow> ?P) \<Longrightarrow> ?P###end
|
Euler_Polyhedron_Formula/Euler_Formula
|
Euler_Formula.hyperplane_cellcomplex_diff
|
lemma hyperplane_cellcomplex_diff:
"\<lbrakk>hyperplane_cellcomplex A S; hyperplane_cellcomplex A T\<rbrakk>
\<Longrightarrow> hyperplane_cellcomplex A (S - T)"
|
hyperplane_cellcomplex ?A ?S \<Longrightarrow> hyperplane_cellcomplex ?A ?T \<Longrightarrow> hyperplane_cellcomplex ?A (?S - ?T)
|
\<lbrakk> ?H1 x_1 x_2; ?H1 x_1 x_3\<rbrakk> \<Longrightarrow> ?H1 x_1 (?H2 x_2 x_3)
|
[
"Groups.minus_class.minus",
"Euler_Formula.hyperplane_cellcomplex"
] |
[
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"('a \\<times> real) set \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"definition hyperplane_cellcomplex \n where \"hyperplane_cellcomplex A S \\<equiv>\n \\<exists>\\<T>. (\\<forall>C \\<in> \\<T>. hyperplane_cell A C) \\<and> S = \\<Union>\\<T>\""
] |
lemma_object
|
###symbols
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Euler_Formula.hyperplane_cellcomplex :::: ('a \<times> real) set \<Rightarrow> 'a set \<Rightarrow> bool
###defs
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
definition hyperplane_cellcomplex
where "hyperplane_cellcomplex A S \<equiv>
\<exists>\<T>. (\<forall>C \<in> \<T>. hyperplane_cell A C) \<and> S = \<Union>\<T>"
|
###output
hyperplane_cellcomplex ?A ?S \<Longrightarrow> hyperplane_cellcomplex ?A ?T \<Longrightarrow> hyperplane_cellcomplex ?A (?S - ?T)###end
|
Word_Lib/More_Word
|
More_Word.and_mask_eq_iff_le_mask
|
lemma and_mask_eq_iff_le_mask:
\<open>w AND mask n = w \<longleftrightarrow> w \<le> mask n\<close>
for w :: \<open>'a::len word\<close>
|
(and ?w (mask ?n) = ?w) = (?w \<le> mask ?n)
|
(?H1 x_1 (?H2 x_2) = x_1) = (x_1 \<le> ?H2 x_2)
|
[
"Bit_Operations.semiring_bit_operations_class.mask",
"Bit_Operations.semiring_bit_operations_class.and"
] |
[
"nat \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a"
] |
[
"class semiring_bit_operations = semiring_bits +\n fixes \"and\" :: \\<open>'a \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close> (infixr \\<open>AND\\<close> 64)\n and or :: \\<open>'a \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close> (infixr \\<open>OR\\<close> 59)\n and xor :: \\<open>'a \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close> (infixr \\<open>XOR\\<close> 59)\n and mask :: \\<open>nat \\<Rightarrow> 'a\\<close>\n and set_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and unset_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and flip_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and push_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and drop_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and take_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n assumes and_rec: \\<open>a AND b = of_bool (odd a \\<and> odd b) + 2 * ((a div 2) AND (b div 2))\\<close>\n and or_rec: \\<open>a OR b = of_bool (odd a \\<or> odd b) + 2 * ((a div 2) OR (b div 2))\\<close>\n and xor_rec: \\<open>a XOR b = of_bool (odd a \\<noteq> odd b) + 2 * ((a div 2) XOR (b div 2))\\<close>\n and mask_eq_exp_minus_1: \\<open>mask n = 2 ^ n - 1\\<close>\n and set_bit_eq_or: \\<open>set_bit n a = a OR push_bit n 1\\<close>\n and unset_bit_eq_or_xor: \\<open>unset_bit n a = (a OR push_bit n 1) XOR push_bit n 1\\<close>\n and flip_bit_eq_xor: \\<open>flip_bit n a = a XOR push_bit n 1\\<close>\n and push_bit_eq_mult: \\<open>push_bit n a = a * 2 ^ n\\<close>\n and drop_bit_eq_div: \\<open>drop_bit n a = a div 2 ^ n\\<close>\n and take_bit_eq_mod: \\<open>take_bit n a = a mod 2 ^ n\\<close>\nbegin",
"class semiring_bit_operations = semiring_bits +\n fixes \"and\" :: \\<open>'a \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close> (infixr \\<open>AND\\<close> 64)\n and or :: \\<open>'a \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close> (infixr \\<open>OR\\<close> 59)\n and xor :: \\<open>'a \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close> (infixr \\<open>XOR\\<close> 59)\n and mask :: \\<open>nat \\<Rightarrow> 'a\\<close>\n and set_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and unset_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and flip_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and push_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and drop_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n and take_bit :: \\<open>nat \\<Rightarrow> 'a \\<Rightarrow> 'a\\<close>\n assumes and_rec: \\<open>a AND b = of_bool (odd a \\<and> odd b) + 2 * ((a div 2) AND (b div 2))\\<close>\n and or_rec: \\<open>a OR b = of_bool (odd a \\<or> odd b) + 2 * ((a div 2) OR (b div 2))\\<close>\n and xor_rec: \\<open>a XOR b = of_bool (odd a \\<noteq> odd b) + 2 * ((a div 2) XOR (b div 2))\\<close>\n and mask_eq_exp_minus_1: \\<open>mask n = 2 ^ n - 1\\<close>\n and set_bit_eq_or: \\<open>set_bit n a = a OR push_bit n 1\\<close>\n and unset_bit_eq_or_xor: \\<open>unset_bit n a = (a OR push_bit n 1) XOR push_bit n 1\\<close>\n and flip_bit_eq_xor: \\<open>flip_bit n a = a XOR push_bit n 1\\<close>\n and push_bit_eq_mult: \\<open>push_bit n a = a * 2 ^ n\\<close>\n and drop_bit_eq_div: \\<open>drop_bit n a = a div 2 ^ n\\<close>\n and take_bit_eq_mod: \\<open>take_bit n a = a mod 2 ^ n\\<close>\nbegin"
] |
lemma_object
|
###symbols
Bit_Operations.semiring_bit_operations_class.mask :::: nat \<Rightarrow> 'a
Bit_Operations.semiring_bit_operations_class.and :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
###defs
class semiring_bit_operations = semiring_bits +
fixes "and" :: \<open>'a \<Rightarrow> 'a \<Rightarrow> 'a\<close> (infixr \<open>AND\<close> 64)
and or :: \<open>'a \<Rightarrow> 'a \<Rightarrow> 'a\<close> (infixr \<open>OR\<close> 59)
and xor :: \<open>'a \<Rightarrow> 'a \<Rightarrow> 'a\<close> (infixr \<open>XOR\<close> 59)
and mask :: \<open>nat \<Rightarrow> 'a\<close>
and set_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and unset_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and flip_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and push_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and drop_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and take_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
assumes and_rec: \<open>a AND b = of_bool (odd a \<and> odd b) + 2 * ((a div 2) AND (b div 2))\<close>
and or_rec: \<open>a OR b = of_bool (odd a \<or> odd b) + 2 * ((a div 2) OR (b div 2))\<close>
and xor_rec: \<open>a XOR b = of_bool (odd a \<noteq> odd b) + 2 * ((a div 2) XOR (b div 2))\<close>
and mask_eq_exp_minus_1: \<open>mask n = 2 ^ n - 1\<close>
and set_bit_eq_or: \<open>set_bit n a = a OR push_bit n 1\<close>
and unset_bit_eq_or_xor: \<open>unset_bit n a = (a OR push_bit n 1) XOR push_bit n 1\<close>
and flip_bit_eq_xor: \<open>flip_bit n a = a XOR push_bit n 1\<close>
and push_bit_eq_mult: \<open>push_bit n a = a * 2 ^ n\<close>
and drop_bit_eq_div: \<open>drop_bit n a = a div 2 ^ n\<close>
and take_bit_eq_mod: \<open>take_bit n a = a mod 2 ^ n\<close>
begin
class semiring_bit_operations = semiring_bits +
fixes "and" :: \<open>'a \<Rightarrow> 'a \<Rightarrow> 'a\<close> (infixr \<open>AND\<close> 64)
and or :: \<open>'a \<Rightarrow> 'a \<Rightarrow> 'a\<close> (infixr \<open>OR\<close> 59)
and xor :: \<open>'a \<Rightarrow> 'a \<Rightarrow> 'a\<close> (infixr \<open>XOR\<close> 59)
and mask :: \<open>nat \<Rightarrow> 'a\<close>
and set_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and unset_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and flip_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and push_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and drop_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
and take_bit :: \<open>nat \<Rightarrow> 'a \<Rightarrow> 'a\<close>
assumes and_rec: \<open>a AND b = of_bool (odd a \<and> odd b) + 2 * ((a div 2) AND (b div 2))\<close>
and or_rec: \<open>a OR b = of_bool (odd a \<or> odd b) + 2 * ((a div 2) OR (b div 2))\<close>
and xor_rec: \<open>a XOR b = of_bool (odd a \<noteq> odd b) + 2 * ((a div 2) XOR (b div 2))\<close>
and mask_eq_exp_minus_1: \<open>mask n = 2 ^ n - 1\<close>
and set_bit_eq_or: \<open>set_bit n a = a OR push_bit n 1\<close>
and unset_bit_eq_or_xor: \<open>unset_bit n a = (a OR push_bit n 1) XOR push_bit n 1\<close>
and flip_bit_eq_xor: \<open>flip_bit n a = a XOR push_bit n 1\<close>
and push_bit_eq_mult: \<open>push_bit n a = a * 2 ^ n\<close>
and drop_bit_eq_div: \<open>drop_bit n a = a div 2 ^ n\<close>
and take_bit_eq_mod: \<open>take_bit n a = a mod 2 ^ n\<close>
begin
|
###output
(and ?w (mask ?n) = ?w) = (?w \<le> mask ?n)###end
|
Collections/ICF/CollectionsV1
|
CollectionsV1.ts_correct(31)
| null |
ts.invar ?s1.0 \<Longrightarrow> ts.invar ?s2.0 \<Longrightarrow> ts.disjoint_witness ?s1.0 ?s2.0 = None \<Longrightarrow> ts.\<alpha> ?s1.0 \<inter> ts.\<alpha> ?s2.0 = {}
|
\<lbrakk> ?H1 x_1; ?H1 x_2; ?H2 x_1 x_2 = ?H3\<rbrakk> \<Longrightarrow> ?H4 (?H5 x_1) (?H5 x_2) = ?H6
|
[
"Set.empty",
"TrieSetImpl.ts.\\<alpha>",
"Set.inter",
"Option.option.None",
"TrieSetImpl.ts.disjoint_witness",
"TrieSetImpl.ts.invar"
] |
[
"'a set",
"('a, unit) trie \\<Rightarrow> 'a list set",
"'a set \\<Rightarrow> 'a set \\<Rightarrow> 'a set",
"'a option",
"('a, unit) trie \\<Rightarrow> ('a, unit) trie \\<Rightarrow> 'a list option",
"('a, unit) trie \\<Rightarrow> bool"
] |
[
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"abbreviation inter :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> 'a set\" (infixl \"\\<inter>\" 70)\n where \"(\\<inter>) \\<equiv> inf\"",
"datatype 'a option =\n None\n | Some (the: 'a)"
] |
lemma_object
|
###symbols
Set.empty :::: 'a set
TrieSetImpl.ts.\<alpha> :::: ('a, unit) trie \<Rightarrow> 'a list set
Set.inter :::: 'a set \<Rightarrow> 'a set \<Rightarrow> 'a set
Option.option.None :::: 'a option
TrieSetImpl.ts.disjoint_witness :::: ('a, unit) trie \<Rightarrow> ('a, unit) trie \<Rightarrow> 'a list option
TrieSetImpl.ts.invar :::: ('a, unit) trie \<Rightarrow> bool
###defs
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
abbreviation inter :: "'a set \<Rightarrow> 'a set \<Rightarrow> 'a set" (infixl "\<inter>" 70)
where "(\<inter>) \<equiv> inf"
datatype 'a option =
None
| Some (the: 'a)
|
###output
ts.invar ?s1.0 \<Longrightarrow> ts.invar ?s2.0 \<Longrightarrow> ts.disjoint_witness ?s1.0 ?s2.0 = None \<Longrightarrow> ts.\<alpha> ?s1.0 \<inter> ts.\<alpha> ?s2.0 = {}###end
|
LTL3_Semantics/LTL3
|
LTL3.unroll_Union
|
lemma unroll_Union: \<open>\<Squnion> (range P) = P 0 \<squnion> (\<Squnion> (range (P \<circ> Suc)))\<close>
|
\<Squnion> (range ?P) = ?P 0 \<squnion> \<Squnion> (range (?P \<circ> Suc))
|
?H1 (?H2 x_1) = ?H3 (x_1 ?H4) (?H1 (?H2 (?H5 x_1 ?H6)))
|
[
"Nat.Suc",
"Fun.comp",
"Groups.zero_class.zero",
"Traces.union_dset",
"Set.range",
"Traces.Union_cset"
] |
[
"nat \\<Rightarrow> nat",
"('a \\<Rightarrow> 'b) \\<Rightarrow> ('c \\<Rightarrow> 'a) \\<Rightarrow> 'c \\<Rightarrow> 'b",
"'a",
"'a dset \\<Rightarrow> 'a dset \\<Rightarrow> 'a dset",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'b set",
"'a dset set \\<Rightarrow> 'a dset"
] |
[
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"definition comp :: \"('b \\<Rightarrow> 'c) \\<Rightarrow> ('a \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> 'c\" (infixl \"\\<circ>\" 55)\n where \"f \\<circ> g = (\\<lambda>x. f (g x))\"",
"class zero =\n fixes zero :: 'a (\"0\")",
"abbreviation union_dset :: \\<open>'a dset \\<Rightarrow> 'a dset \\<Rightarrow> 'a dset\\<close> (infixl \\<open>\\<squnion>\\<close> 65) where\n \\<open>X \\<squnion> Y \\<equiv> \\<Squnion> {X,Y}\\<close>",
"abbreviation range :: \"('a \\<Rightarrow> 'b) \\<Rightarrow> 'b set\" \\<comment> \\<open>of function\\<close>\n where \"range f \\<equiv> f ` UNIV\""
] |
lemma_object
|
###symbols
Nat.Suc :::: nat \<Rightarrow> nat
Fun.comp :::: ('a \<Rightarrow> 'b) \<Rightarrow> ('c \<Rightarrow> 'a) \<Rightarrow> 'c \<Rightarrow> 'b
Groups.zero_class.zero :::: 'a
Traces.union_dset :::: 'a dset \<Rightarrow> 'a dset \<Rightarrow> 'a dset
Set.range :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'b set
Traces.Union_cset :::: 'a dset set \<Rightarrow> 'a dset
###defs
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
definition comp :: "('b \<Rightarrow> 'c) \<Rightarrow> ('a \<Rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> 'c" (infixl "\<circ>" 55)
where "f \<circ> g = (\<lambda>x. f (g x))"
class zero =
fixes zero :: 'a ("0")
abbreviation union_dset :: \<open>'a dset \<Rightarrow> 'a dset \<Rightarrow> 'a dset\<close> (infixl \<open>\<squnion>\<close> 65) where
\<open>X \<squnion> Y \<equiv> \<Squnion> {X,Y}\<close>
abbreviation range :: "('a \<Rightarrow> 'b) \<Rightarrow> 'b set" \<comment> \<open>of function\<close>
where "range f \<equiv> f ` UNIV"
|
###output
\<Squnion> (range ?P) = ?P 0 \<squnion> \<Squnion> (range (?P \<circ> Suc))###end
|
Dirichlet_Series/Dirichlet_Product
|
Dirichlet_Product.of_int_dirichlet_inverse
|
lemma of_int_dirichlet_inverse:
"of_int (dirichlet_inverse f i n) = dirichlet_inverse (\<lambda>n. of_int (f n)) (of_int i) n"
|
of_int (dirichlet_inverse ?f ?i ?n) = dirichlet_inverse (\<lambda>n. of_int (?f n)) (of_int ?i) ?n
|
?H1 (?H2 x_1 x_2 x_3) = ?H3 (\<lambda>y_0. ?H1 (x_1 y_0)) (?H1 x_2) x_3
|
[
"Dirichlet_Product.dirichlet_inverse",
"Int.ring_1_class.of_int"
] |
[
"(nat \\<Rightarrow> 'a) \\<Rightarrow> 'a \\<Rightarrow> nat \\<Rightarrow> 'a",
"int \\<Rightarrow> 'a"
] |
[
"fun dirichlet_inverse :: \"(nat \\<Rightarrow> 'a :: comm_ring_1) \\<Rightarrow> 'a \\<Rightarrow> nat \\<Rightarrow> 'a\" where\n \"dirichlet_inverse f i n = \n (if n = 0 then 0 else if n = 1 then i\n else -i * (\\<Sum>d | d dvd n \\<and> d < n. f (n div d) * dirichlet_inverse f i d))\""
] |
lemma_object
|
###symbols
Dirichlet_Product.dirichlet_inverse :::: (nat \<Rightarrow> 'a) \<Rightarrow> 'a \<Rightarrow> nat \<Rightarrow> 'a
Int.ring_1_class.of_int :::: int \<Rightarrow> 'a
###defs
fun dirichlet_inverse :: "(nat \<Rightarrow> 'a :: comm_ring_1) \<Rightarrow> 'a \<Rightarrow> nat \<Rightarrow> 'a" where
"dirichlet_inverse f i n =
(if n = 0 then 0 else if n = 1 then i
else -i * (\<Sum>d | d dvd n \<and> d < n. f (n div d) * dirichlet_inverse f i d))"
|
###output
of_int (dirichlet_inverse ?f ?i ?n) = dirichlet_inverse (\<lambda>n. of_int (?f n)) (of_int ?i) ?n###end
|
Containers/Compatibility_Containers_Regular_Sets
|
Compatibility_Containers_Regular_Sets.comparator_rexp_simps(14)
| null |
comparator_rexp ?comp\<^sub>'\<^sub>a (Atom ?x) One = Gt
|
?H1 x_1 (?H2 x_2) ?H3 = ?H4
|
[
"Comparator.order.Gt",
"Regular_Exp.rexp.One",
"Regular_Exp.rexp.Atom",
"Compatibility_Containers_Regular_Sets.comparator_rexp"
] |
[
"order",
"'a rexp",
"'a \\<Rightarrow> 'a rexp",
"('a \\<Rightarrow> 'a \\<Rightarrow> order) \\<Rightarrow> 'a rexp \\<Rightarrow> 'a rexp \\<Rightarrow> order"
] |
[
"datatype (atoms: 'a) rexp =\n is_Zero: Zero |\n is_One: One |\n Atom 'a |\n Plus \"('a rexp)\" \"('a rexp)\" |\n Times \"('a rexp)\" \"('a rexp)\" |\n Star \"('a rexp)\"",
"datatype (atoms: 'a) rexp =\n is_Zero: Zero |\n is_One: One |\n Atom 'a |\n Plus \"('a rexp)\" \"('a rexp)\" |\n Times \"('a rexp)\" \"('a rexp)\" |\n Star \"('a rexp)\""
] |
lemma_object
|
###symbols
Comparator.order.Gt :::: order
Regular_Exp.rexp.One :::: 'a rexp
Regular_Exp.rexp.Atom :::: 'a \<Rightarrow> 'a rexp
Compatibility_Containers_Regular_Sets.comparator_rexp :::: ('a \<Rightarrow> 'a \<Rightarrow> order) \<Rightarrow> 'a rexp \<Rightarrow> 'a rexp \<Rightarrow> order
###defs
datatype (atoms: 'a) rexp =
is_Zero: Zero |
is_One: One |
Atom 'a |
Plus "('a rexp)" "('a rexp)" |
Times "('a rexp)" "('a rexp)" |
Star "('a rexp)"
datatype (atoms: 'a) rexp =
is_Zero: Zero |
is_One: One |
Atom 'a |
Plus "('a rexp)" "('a rexp)" |
Times "('a rexp)" "('a rexp)" |
Star "('a rexp)"
|
###output
comparator_rexp ?comp\<^sub>'\<^sub>a (Atom ?x) One = Gt###end
|
List_Update/Prob_Theory
|
Prob_Theory.map_hd_list_pmf
|
lemma map_hd_list_pmf: "map_pmf hd (bv (Suc n)) = bernoulli_pmf (5 / 10)"
|
map_pmf hd (bv (Suc ?n)) = bernoulli_pmf (5 / 10)
|
?H1 ?H2 (?H3 (?H4 x_1)) = ?H5 (?H6 (?H7 (?H8 (?H9 ?H10))) (?H7 (?H9 (?H8 (?H9 ?H10)))))
|
[
"Num.num.One",
"Num.num.Bit0",
"Num.num.Bit1",
"Num.numeral_class.numeral",
"Fields.inverse_class.inverse_divide",
"Probability_Mass_Function.bernoulli_pmf",
"Nat.Suc",
"Prob_Theory.bv",
"List.list.hd",
"Probability_Mass_Function.map_pmf"
] |
[
"num",
"num \\<Rightarrow> num",
"num \\<Rightarrow> num",
"num \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"real \\<Rightarrow> bool pmf",
"nat \\<Rightarrow> nat",
"nat \\<Rightarrow> bool list pmf",
"'a list \\<Rightarrow> 'a",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a pmf \\<Rightarrow> 'b pmf"
] |
[
"datatype num = One | Bit0 num | Bit1 num",
"datatype num = One | Bit0 num | Bit1 num",
"datatype num = One | Bit0 num | Bit1 num",
"primrec numeral :: \"num \\<Rightarrow> 'a\"\n where\n numeral_One: \"numeral One = 1\"\n | numeral_Bit0: \"numeral (Bit0 n) = numeral n + numeral n\"\n | numeral_Bit1: \"numeral (Bit1 n) = numeral n + numeral n + 1\"",
"class inverse = divide +\n fixes inverse :: \"'a \\<Rightarrow> 'a\"\nbegin",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"fun bv:: \"nat \\<Rightarrow> bool list pmf\" where\n \"bv 0 = return_pmf []\"\n| \"bv (Suc n) = do {\n (xs::bool list) \\<leftarrow> bv n;\n (x::bool) \\<leftarrow> (bernoulli_pmf 0.5);\n return_pmf (x#xs)\n }\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"definition \"map_pmf f M = bind_pmf M (\\<lambda>x. return_pmf (f x))\""
] |
lemma_object
|
###symbols
Num.num.One :::: num
Num.num.Bit0 :::: num \<Rightarrow> num
Num.num.Bit1 :::: num \<Rightarrow> num
Num.numeral_class.numeral :::: num \<Rightarrow> 'a
Fields.inverse_class.inverse_divide :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Probability_Mass_Function.bernoulli_pmf :::: real \<Rightarrow> bool pmf
Nat.Suc :::: nat \<Rightarrow> nat
Prob_Theory.bv :::: nat \<Rightarrow> bool list pmf
List.list.hd :::: 'a list \<Rightarrow> 'a
Probability_Mass_Function.map_pmf :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a pmf \<Rightarrow> 'b pmf
###defs
datatype num = One | Bit0 num | Bit1 num
datatype num = One | Bit0 num | Bit1 num
datatype num = One | Bit0 num | Bit1 num
primrec numeral :: "num \<Rightarrow> 'a"
where
numeral_One: "numeral One = 1"
| numeral_Bit0: "numeral (Bit0 n) = numeral n + numeral n"
| numeral_Bit1: "numeral (Bit1 n) = numeral n + numeral n + 1"
class inverse = divide +
fixes inverse :: "'a \<Rightarrow> 'a"
begin
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
fun bv:: "nat \<Rightarrow> bool list pmf" where
"bv 0 = return_pmf []"
| "bv (Suc n) = do {
(xs::bool list) \<leftarrow> bv n;
(x::bool) \<leftarrow> (bernoulli_pmf 0.5);
return_pmf (x#xs)
}"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
definition "map_pmf f M = bind_pmf M (\<lambda>x. return_pmf (f x))"
|
###output
map_pmf hd (bv (Suc ?n)) = bernoulli_pmf (5 / 10)###end
|
ROBDD/Pointer_Map
|
Pointer_Map.pointermap_insert_in
|
lemma pointermap_insert_in: "u = (pointermap_insert a m) \<Longrightarrow> pm_pth u (the (getentry u a)) = a"
|
?u = pointermap_insert ?a ?m \<Longrightarrow> pm_pth ?u (the (getentry ?u ?a)) = ?a
|
x_1 = ?H1 x_2 x_3 \<Longrightarrow> ?H2 x_1 (?H3 (?H4 x_1 x_2)) = x_2
|
[
"Pointer_Map.pointermap.getentry",
"Option.option.the",
"Pointer_Map.pm_pth",
"Pointer_Map.pointermap_insert"
] |
[
"('a, 'b) pointermap_scheme \\<Rightarrow> 'a \\<Rightarrow> nat option",
"'a option \\<Rightarrow> 'a",
"('a, 'b) pointermap_scheme \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a \\<Rightarrow> ('a, 'b) pointermap_scheme \\<Rightarrow> 'a pointermap"
] |
[
"datatype 'a option =\n None\n | Some (the: 'a)",
"definition \"pm_pth m p \\<equiv> entries m ! p\"",
"definition \"pointermap_insert a m \\<equiv> \\<lparr>entries = (entries m)@[a], getentry = (getentry m)(a \\<mapsto> length (entries m))\\<rparr>\""
] |
lemma_object
|
###symbols
Pointer_Map.pointermap.getentry :::: ('a, 'b) pointermap_scheme \<Rightarrow> 'a \<Rightarrow> nat option
Option.option.the :::: 'a option \<Rightarrow> 'a
Pointer_Map.pm_pth :::: ('a, 'b) pointermap_scheme \<Rightarrow> nat \<Rightarrow> 'a
Pointer_Map.pointermap_insert :::: 'a \<Rightarrow> ('a, 'b) pointermap_scheme \<Rightarrow> 'a pointermap
###defs
datatype 'a option =
None
| Some (the: 'a)
definition "pm_pth m p \<equiv> entries m ! p"
definition "pointermap_insert a m \<equiv> \<lparr>entries = (entries m)@[a], getentry = (getentry m)(a \<mapsto> length (entries m))\<rparr>"
|
###output
?u = pointermap_insert ?a ?m \<Longrightarrow> pm_pth ?u (the (getentry ?u ?a)) = ?a###end
|
Higher_Order_Terms/Find_First
|
Find_First.find_first_none
|
lemma find_first_none: "x \<notin> set xs \<Longrightarrow> find_first x xs = None"
|
?x \<notin> set ?xs \<Longrightarrow> find_first ?x ?xs = None
|
?H1 x_1 (?H2 x_2) \<Longrightarrow> ?H3 x_1 x_2 = ?H4
|
[
"Option.option.None",
"Find_First.find_first",
"List.list.set",
"Set.not_member"
] |
[
"'a option",
"'a \\<Rightarrow> 'a list \\<Rightarrow> nat option",
"'a list \\<Rightarrow> 'a set",
"'a \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"datatype 'a option =\n None\n | Some (the: 'a)",
"fun find_first :: \"'a \\<Rightarrow> 'a list \\<Rightarrow> nat option\" where\n\"find_first _ [] = None\" |\n\"find_first x (y # ys) = (if x = y then Some 0 else map_option Suc (find_first x ys))\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"abbreviation not_member\n where \"not_member x A \\<equiv> \\<not> (x \\<in> A)\" \\<comment> \\<open>non-membership\\<close>"
] |
lemma_object
|
###symbols
Option.option.None :::: 'a option
Find_First.find_first :::: 'a \<Rightarrow> 'a list \<Rightarrow> nat option
List.list.set :::: 'a list \<Rightarrow> 'a set
Set.not_member :::: 'a \<Rightarrow> 'a set \<Rightarrow> bool
###defs
datatype 'a option =
None
| Some (the: 'a)
fun find_first :: "'a \<Rightarrow> 'a list \<Rightarrow> nat option" where
"find_first _ [] = None" |
"find_first x (y # ys) = (if x = y then Some 0 else map_option Suc (find_first x ys))"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
abbreviation not_member
where "not_member x A \<equiv> \<not> (x \<in> A)" \<comment> \<open>non-membership\<close>
|
###output
?x \<notin> set ?xs \<Longrightarrow> find_first ?x ?xs = None###end
|
Jordan_Normal_Form/Jordan_Normal_Form
|
Jordan_Normal_Form.jordan_nf_matrix_poly_bound
|
lemma jordan_nf_matrix_poly_bound: fixes n_as :: "(nat \<times> 'a)list"
assumes A: "A \<in> carrier_mat n n"
and n_as: "\<And> n a. (n,a) \<in> set n_as \<Longrightarrow> n > 0 \<Longrightarrow> norm a \<le> 1"
and N: "\<And> n a. (n,a) \<in> set n_as \<Longrightarrow> norm a = 1 \<Longrightarrow> n \<le> N"
and jnf: "jordan_nf A n_as"
shows "\<exists> c1 c2. \<forall> k. norm_bound (A ^\<^sub>m k) (c1 + c2 * of_nat k ^ (N - 1))"
|
?A \<in> carrier_mat ?n ?n \<Longrightarrow> (\<And>n a. (n, a) \<in> set ?n_as \<Longrightarrow> 0 < n \<Longrightarrow> norm a \<le> 1) \<Longrightarrow> (\<And>n a. (n, a) \<in> set ?n_as \<Longrightarrow> norm a = 1 \<Longrightarrow> n \<le> ?N) \<Longrightarrow> jordan_nf ?A ?n_as \<Longrightarrow> \<exists>c1 c2. \<forall>k. norm_bound (?A ^\<^sub>m k) (c1 + c2 * real k ^ (?N - 1))
|
\<lbrakk>x_1 \<in> ?H1 x_2 x_2; \<And>y_0 y_1. \<lbrakk>(y_0, y_1) \<in> ?H2 x_3; ?H3 < y_0\<rbrakk> \<Longrightarrow> ?H4 y_1 \<le> ?H5; \<And>y_2 y_3. \<lbrakk>(y_2, y_3) \<in> ?H2 x_3; ?H4 y_3 = ?H5\<rbrakk> \<Longrightarrow> y_2 \<le> x_4; ?H6 x_1 x_3\<rbrakk> \<Longrightarrow> \<exists>y_4 y_5. \<forall>y_6. ?H7 (?H8 x_1 y_6) (?H9 y_4 (?H10 y_5 (?H11 (?H12 y_6) (?H13 x_4 ?H14))))
|
[
"Groups.minus_class.minus",
"Real.real",
"Power.power_class.power",
"Groups.times_class.times",
"Groups.plus_class.plus",
"Matrix.pow_mat",
"Jordan_Normal_Form.norm_bound",
"Jordan_Normal_Form.jordan_nf",
"Groups.one_class.one",
"Real_Vector_Spaces.norm_class.norm",
"Groups.zero_class.zero",
"List.list.set",
"Matrix.carrier_mat"
] |
[
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"nat \\<Rightarrow> real",
"'a \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a mat \\<Rightarrow> nat \\<Rightarrow> 'a mat",
"'a mat \\<Rightarrow> real \\<Rightarrow> bool",
"'a mat \\<Rightarrow> (nat \\<times> 'a) list \\<Rightarrow> bool",
"'a",
"'a \\<Rightarrow> real",
"'a",
"'a list \\<Rightarrow> 'a set",
"nat \\<Rightarrow> nat \\<Rightarrow> 'a mat set"
] |
[
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"abbreviation real :: \"nat \\<Rightarrow> real\"\n where \"real \\<equiv> of_nat\"",
"primrec power :: \"'a \\<Rightarrow> nat \\<Rightarrow> 'a\" (infixr \"^\" 80)\n where\n power_0: \"a ^ 0 = 1\"\n | power_Suc: \"a ^ Suc n = a * a ^ n\"",
"class times =\n fixes times :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"*\" 70)",
"class plus =\n fixes plus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"+\" 65)",
"fun pow_mat :: \"'a :: semiring_1 mat \\<Rightarrow> nat \\<Rightarrow> 'a mat\" (infixr \"^\\<^sub>m\" 75) where\n \"A ^\\<^sub>m 0 = 1\\<^sub>m (dim_row A)\"\n| \"A ^\\<^sub>m (Suc k) = A ^\\<^sub>m k * A\"",
"definition norm_bound :: \"'a mat \\<Rightarrow> real \\<Rightarrow> bool\" where\n \"norm_bound A b \\<equiv> \\<forall> i j. i < dim_row A \\<longrightarrow> j < dim_col A \\<longrightarrow> norm (A $$ (i,j)) \\<le> b\"",
"definition jordan_nf :: \"'a :: semiring_1 mat \\<Rightarrow> (nat \\<times> 'a)list \\<Rightarrow> bool\" where\n \"jordan_nf A n_as \\<equiv> (0 \\<notin> fst ` set n_as \\<and> similar_mat A (jordan_matrix n_as))\"",
"class one =\n fixes one :: 'a (\"1\")",
"class norm =\n fixes norm :: \"'a \\<Rightarrow> real\"",
"class zero =\n fixes zero :: 'a (\"0\")",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"definition carrier_mat :: \"nat \\<Rightarrow> nat \\<Rightarrow> 'a mat set\"\n where \"carrier_mat nr nc = { m . dim_row m = nr \\<and> dim_col m = nc}\""
] |
lemma_object
|
###symbols
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Real.real :::: nat \<Rightarrow> real
Power.power_class.power :::: 'a \<Rightarrow> nat \<Rightarrow> 'a
Groups.times_class.times :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Groups.plus_class.plus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Matrix.pow_mat :::: 'a mat \<Rightarrow> nat \<Rightarrow> 'a mat
Jordan_Normal_Form.norm_bound :::: 'a mat \<Rightarrow> real \<Rightarrow> bool
Jordan_Normal_Form.jordan_nf :::: 'a mat \<Rightarrow> (nat \<times> 'a) list \<Rightarrow> bool
Groups.one_class.one :::: 'a
Real_Vector_Spaces.norm_class.norm :::: 'a \<Rightarrow> real
Groups.zero_class.zero :::: 'a
List.list.set :::: 'a list \<Rightarrow> 'a set
Matrix.carrier_mat :::: nat \<Rightarrow> nat \<Rightarrow> 'a mat set
###defs
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
abbreviation real :: "nat \<Rightarrow> real"
where "real \<equiv> of_nat"
primrec power :: "'a \<Rightarrow> nat \<Rightarrow> 'a" (infixr "^" 80)
where
power_0: "a ^ 0 = 1"
| power_Suc: "a ^ Suc n = a * a ^ n"
class times =
fixes times :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "*" 70)
class plus =
fixes plus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "+" 65)
fun pow_mat :: "'a :: semiring_1 mat \<Rightarrow> nat \<Rightarrow> 'a mat" (infixr "^\<^sub>m" 75) where
"A ^\<^sub>m 0 = 1\<^sub>m (dim_row A)"
| "A ^\<^sub>m (Suc k) = A ^\<^sub>m k * A"
definition norm_bound :: "'a mat \<Rightarrow> real \<Rightarrow> bool" where
"norm_bound A b \<equiv> \<forall> i j. i < dim_row A \<longrightarrow> j < dim_col A \<longrightarrow> norm (A $$ (i,j)) \<le> b"
definition jordan_nf :: "'a :: semiring_1 mat \<Rightarrow> (nat \<times> 'a)list \<Rightarrow> bool" where
"jordan_nf A n_as \<equiv> (0 \<notin> fst ` set n_as \<and> similar_mat A (jordan_matrix n_as))"
class one =
fixes one :: 'a ("1")
class norm =
fixes norm :: "'a \<Rightarrow> real"
class zero =
fixes zero :: 'a ("0")
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
definition carrier_mat :: "nat \<Rightarrow> nat \<Rightarrow> 'a mat set"
where "carrier_mat nr nc = { m . dim_row m = nr \<and> dim_col m = nc}"
|
###output
?A \<in> carrier_mat ?n ?n \<Longrightarrow> (\<And>n a. (n, a) \<in> set ?n_as \<Longrightarrow> 0 < n \<Longrightarrow> norm a \<le> 1) \<Longrightarrow> (\<And>n a. (n, a) \<in> set ?n_as \<Longrightarrow> norm a = 1 \<Longrightarrow> n \<le> ?N) \<Longrightarrow> jordan_nf ?A ?n_as \<Longrightarrow> \<exists>c1 c2. \<forall>k. norm_bound (?A ^\<^sub>m k) (c1 + c2 * real k ^ (?N - 1))###end
|
Complex_Bounded_Operators/Complex_Bounded_Linear_Function
|
Complex_Bounded_Linear_Function.riesz_representation_cblinfun_existence
|
theorem riesz_representation_cblinfun_existence:
\<comment> \<open>Theorem 3.4 in \<^cite>\<open>conway2013course\<close>\<close>
fixes f::\<open>'a::chilbert_space \<Rightarrow>\<^sub>C\<^sub>L complex\<close>
shows \<open>\<exists>t. \<forall>x. f *\<^sub>V x = (t \<bullet>\<^sub>C x)\<close>
|
\<exists>t. \<forall>x. cblinfun_apply ?f x = t \<bullet>\<^sub>C x
|
\<exists>y_0. \<forall>y_1. ?H1 x_1 y_1 = ?H2 y_0 y_1
|
[
"Complex_Inner_Product0.complex_inner_class.cinner",
"Complex_Bounded_Linear_Function0.cblinfun.cblinfun_apply"
] |
[
"'a \\<Rightarrow> 'a \\<Rightarrow> complex",
"('a, 'b) cblinfun \\<Rightarrow> 'a \\<Rightarrow> 'b"
] |
[
"class complex_inner = complex_vector + sgn_div_norm + dist_norm + uniformity_dist + open_uniformity +\n fixes cinner :: \"'a \\<Rightarrow> 'a \\<Rightarrow> complex\"\n assumes cinner_commute: \"cinner x y = cnj (cinner y x)\"\n and cinner_add_left: \"cinner (x + y) z = cinner x z + cinner y z\"\n and cinner_scaleC_left [simp]: \"cinner (scaleC r x) y = (cnj r) * (cinner x y)\"\n and cinner_ge_zero [simp]: \"0 \\<le> cinner x x\"\n and cinner_eq_zero_iff [simp]: \"cinner x x = 0 \\<longleftrightarrow> x = 0\"\n and norm_eq_sqrt_cinner: \"norm x = sqrt (cmod (cinner x x))\"\nbegin"
] |
lemma_object
|
###symbols
Complex_Inner_Product0.complex_inner_class.cinner :::: 'a \<Rightarrow> 'a \<Rightarrow> complex
Complex_Bounded_Linear_Function0.cblinfun.cblinfun_apply :::: ('a, 'b) cblinfun \<Rightarrow> 'a \<Rightarrow> 'b
###defs
class complex_inner = complex_vector + sgn_div_norm + dist_norm + uniformity_dist + open_uniformity +
fixes cinner :: "'a \<Rightarrow> 'a \<Rightarrow> complex"
assumes cinner_commute: "cinner x y = cnj (cinner y x)"
and cinner_add_left: "cinner (x + y) z = cinner x z + cinner y z"
and cinner_scaleC_left [simp]: "cinner (scaleC r x) y = (cnj r) * (cinner x y)"
and cinner_ge_zero [simp]: "0 \<le> cinner x x"
and cinner_eq_zero_iff [simp]: "cinner x x = 0 \<longleftrightarrow> x = 0"
and norm_eq_sqrt_cinner: "norm x = sqrt (cmod (cinner x x))"
begin
|
###output
\<exists>t. \<forall>x. cblinfun_apply ?f x = t \<bullet>\<^sub>C x###end
|
HyperHoareLogic/Compositionality
|
Compositionality.not_fv_hyperE
|
lemma not_fv_hyperE:
assumes "not_fv_hyper e I"
and "same_mod_updates {e} S S'"
and "I S"
shows "I S'"
|
not_fv_hyper ?e ?I \<Longrightarrow> same_mod_updates { ?e} ?S ?S' \<Longrightarrow> ?I ?S \<Longrightarrow> ?I ?S'
|
\<lbrakk> ?H1 x_1 x_2; ?H2 (?H3 x_1 ?H4) x_3 x_4; x_2 x_3\<rbrakk> \<Longrightarrow> x_2 x_4
|
[
"Set.empty",
"Set.insert",
"Compositionality.same_mod_updates",
"Compositionality.not_fv_hyper"
] |
[
"'a set",
"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set",
"'a set \\<Rightarrow> (('a \\<Rightarrow> 'b) \\<times> 'c) set \\<Rightarrow> (('a \\<Rightarrow> 'b) \\<times> 'c) set \\<Rightarrow> bool",
"'a \\<Rightarrow> ((('a \\<Rightarrow> 'b) \\<times> 'c) set \\<Rightarrow> bool) \\<Rightarrow> bool"
] |
[
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"definition insert :: \"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set\"\n where insert_compr: \"insert a B = {x. x = a \\<or> x \\<in> B}\"",
"definition same_mod_updates where\n \"same_mod_updates vars S S' \\<longleftrightarrow> subset_mod_updates vars S S' \\<and> subset_mod_updates vars S' S\"",
"definition not_fv_hyper where\n \"not_fv_hyper t A \\<longleftrightarrow> (\\<forall>S S'. same_mod_updates {t} S S' \\<and> A S \\<longrightarrow> A S')\""
] |
lemma_object
|
###symbols
Set.empty :::: 'a set
Set.insert :::: 'a \<Rightarrow> 'a set \<Rightarrow> 'a set
Compositionality.same_mod_updates :::: 'a set \<Rightarrow> (('a \<Rightarrow> 'b) \<times> 'c) set \<Rightarrow> (('a \<Rightarrow> 'b) \<times> 'c) set \<Rightarrow> bool
Compositionality.not_fv_hyper :::: 'a \<Rightarrow> ((('a \<Rightarrow> 'b) \<times> 'c) set \<Rightarrow> bool) \<Rightarrow> bool
###defs
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
definition insert :: "'a \<Rightarrow> 'a set \<Rightarrow> 'a set"
where insert_compr: "insert a B = {x. x = a \<or> x \<in> B}"
definition same_mod_updates where
"same_mod_updates vars S S' \<longleftrightarrow> subset_mod_updates vars S S' \<and> subset_mod_updates vars S' S"
definition not_fv_hyper where
"not_fv_hyper t A \<longleftrightarrow> (\<forall>S S'. same_mod_updates {t} S S' \<and> A S \<longrightarrow> A S')"
|
###output
not_fv_hyper ?e ?I \<Longrightarrow> same_mod_updates { ?e} ?S ?S' \<Longrightarrow> ?I ?S \<Longrightarrow> ?I ?S'###end
|
AOT/AOT_misc
|
AOT_misc.ConceptOfOrdinaryProperty
| null |
\<^bold>\<turnstile>\<^sub>\<box> H \<Rightarrow> O! \<rightarrow> [\<lambda>x ConceptOf(x,H)]\<down>
|
H1 x_1 (H2 (H3 (H4 x_2) H5) (H6 (H7 (\<lambda>y_0. H8 y_0 (H4 x_2)))))
|
[
"AOT_misc.conceptOf",
"AOT_syntax.AOT_lambda",
"AOT_syntax.AOT_denotes",
"AOT_semantics.AOT_ordinary",
"AOT_model.AOT_var.AOT_term_of_var",
"AOT_misc.FimpG",
"AOT_syntax.AOT_imp",
"AOT_model.AOT_model_valid_in"
] |
[
"\\<kappa> \\<Rightarrow> <\\<kappa>> \\<Rightarrow> \\<o>",
"('a \\<Rightarrow> \\<o>) \\<Rightarrow> <'a>",
"'a \\<Rightarrow> \\<o>",
"<\\<kappa>>",
"'a AOT_var \\<Rightarrow> 'a",
"<\\<kappa>> \\<Rightarrow> <\\<kappa>> \\<Rightarrow> \\<o>",
"\\<o> \\<Rightarrow> \\<o> \\<Rightarrow> \\<o>",
"w \\<Rightarrow> \\<o> \\<Rightarrow> bool"
] |
[
"consts AOT_denotes :: \\<open>'a::AOT_Term \\<Rightarrow> \\<o>\\<close>\n AOT_imp :: \\<open>[\\<o>, \\<o>] \\<Rightarrow> \\<o>\\<close>\n AOT_not :: \\<open>\\<o> \\<Rightarrow> \\<o>\\<close>\n AOT_box :: \\<open>\\<o> \\<Rightarrow> \\<o>\\<close>\n AOT_act :: \\<open>\\<o> \\<Rightarrow> \\<o>\\<close>\n AOT_forall :: \\<open>('a::AOT_Term \\<Rightarrow> \\<o>) \\<Rightarrow> \\<o>\\<close>\n AOT_eq :: \\<open>'a::AOT_Term \\<Rightarrow> 'a::AOT_Term \\<Rightarrow> \\<o>\\<close>\n AOT_desc :: \\<open>('a::AOT_UnaryIndividualTerm \\<Rightarrow> \\<o>) \\<Rightarrow> 'a\\<close>\n AOT_exe :: \\<open><'a::AOT_IndividualTerm> \\<Rightarrow> 'a \\<Rightarrow> \\<o>\\<close>\n AOT_lambda :: \\<open>('a::AOT_IndividualTerm \\<Rightarrow> \\<o>) \\<Rightarrow> <'a>\\<close>\n AOT_lambda0 :: \\<open>\\<o> \\<Rightarrow> \\<o>\\<close>\n AOT_concrete :: \\<open><'a::AOT_UnaryIndividualTerm> AOT_var\\<close>",
"definition AOT_model_valid_in :: \\<open>w\\<Rightarrow>\\<o>\\<Rightarrow>bool\\<close> where\n \\<open>AOT_model_valid_in w \\<phi> \\<equiv> AOT_model_d\\<o> \\<phi> w\\<close>"
] |
lemma_object
|
###symbols
AOT_misc.conceptOf :::: \<kappa> \<Rightarrow> <\<kappa>> \<Rightarrow> \<o>
AOT_syntax.AOT_lambda :::: ('a \<Rightarrow> \<o>) \<Rightarrow> <'a>
AOT_syntax.AOT_denotes :::: 'a \<Rightarrow> \<o>
AOT_semantics.AOT_ordinary :::: <\<kappa>>
AOT_model.AOT_var.AOT_term_of_var :::: 'a AOT_var \<Rightarrow> 'a
AOT_misc.FimpG :::: <\<kappa>> \<Rightarrow> <\<kappa>> \<Rightarrow> \<o>
AOT_syntax.AOT_imp :::: \<o> \<Rightarrow> \<o> \<Rightarrow> \<o>
AOT_model.AOT_model_valid_in :::: w \<Rightarrow> \<o> \<Rightarrow> bool
###defs
consts AOT_denotes :: \<open>'a::AOT_Term \<Rightarrow> \<o>\<close>
AOT_imp :: \<open>[\<o>, \<o>] \<Rightarrow> \<o>\<close>
AOT_not :: \<open>\<o> \<Rightarrow> \<o>\<close>
AOT_box :: \<open>\<o> \<Rightarrow> \<o>\<close>
AOT_act :: \<open>\<o> \<Rightarrow> \<o>\<close>
AOT_forall :: \<open>('a::AOT_Term \<Rightarrow> \<o>) \<Rightarrow> \<o>\<close>
AOT_eq :: \<open>'a::AOT_Term \<Rightarrow> 'a::AOT_Term \<Rightarrow> \<o>\<close>
AOT_desc :: \<open>('a::AOT_UnaryIndividualTerm \<Rightarrow> \<o>) \<Rightarrow> 'a\<close>
AOT_exe :: \<open><'a::AOT_IndividualTerm> \<Rightarrow> 'a \<Rightarrow> \<o>\<close>
AOT_lambda :: \<open>('a::AOT_IndividualTerm \<Rightarrow> \<o>) \<Rightarrow> <'a>\<close>
AOT_lambda0 :: \<open>\<o> \<Rightarrow> \<o>\<close>
AOT_concrete :: \<open><'a::AOT_UnaryIndividualTerm> AOT_var\<close>
definition AOT_model_valid_in :: \<open>w\<Rightarrow>\<o>\<Rightarrow>bool\<close> where
\<open>AOT_model_valid_in w \<phi> \<equiv> AOT_model_d\<o> \<phi> w\<close>
|
###output
\<^bold>\<turnstile>\<^sub>\<box> H \<Rightarrow> O! \<rightarrow> [\<lambda>x ConceptOf(x,H)]\<down>###end
|
Group-Ring-Module/Algebra3
|
Algebra3.isom_gch_unitsTr1_7_6
|
lemma isom_gch_unitsTr1_7_6:"\<lbrakk>Ugp E; Gchain (Suc n) h; k \<noteq> Suc n;
k \<le> (Suc n); h (Suc n) \<cong> E; h k \<cong> E\<rbrakk> \<Longrightarrow>
{i. i \<le> (Suc n) \<and> h i \<cong> E} =
insert k (insert (Suc n) ({i. i \<le> (Suc n) \<and> h i \<cong> E} - {k, Suc n}))"
|
Ugp ?E \<Longrightarrow> Gchain (Suc ?n) ?h \<Longrightarrow> ?k \<noteq> Suc ?n \<Longrightarrow> ?k \<le> Suc ?n \<Longrightarrow> ?h (Suc ?n) \<cong> ?E \<Longrightarrow> ?h ?k \<cong> ?E \<Longrightarrow> {i. i \<le> Suc ?n \<and> ?h i \<cong> ?E} = insert ?k (insert (Suc ?n) ({i. i \<le> Suc ?n \<and> ?h i \<cong> ?E} - { ?k, Suc ?n}))
|
\<lbrakk> ?H1 x_1; ?H2 (?H3 x_2) x_3; x_4 \<noteq> ?H3 x_2; x_4 \<le> ?H3 x_2; ?H4 (x_3 (?H3 x_2)) x_1; ?H4 (x_3 x_4) x_1\<rbrakk> \<Longrightarrow> ?H5 (\<lambda>y_0. y_0 \<le> ?H3 x_2 \<and> ?H4 (x_3 y_0) x_1) = ?H6 x_4 (?H6 (?H3 x_2) (?H7 (?H5 (\<lambda>y_1. y_1 \<le> ?H3 x_2 \<and> ?H4 (x_3 y_1) x_1)) (?H6 x_4 (?H6 (?H3 x_2) ?H8))))
|
[
"Set.empty",
"Groups.minus_class.minus",
"Set.insert",
"Set.Collect",
"Algebra2.isomorphic",
"Nat.Suc",
"Algebra3.Gchain",
"Algebra2.Ugp"
] |
[
"'a set",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a set",
"('a, 'b) Group_scheme \\<Rightarrow> ('c, 'd) Group_scheme \\<Rightarrow> bool",
"nat \\<Rightarrow> nat",
"nat \\<Rightarrow> (nat \\<Rightarrow> ('a set, 'b) Group_scheme) \\<Rightarrow> bool",
"('a, 'b) Group_scheme \\<Rightarrow> bool"
] |
[
"abbreviation empty :: \"'a set\" (\"{}\")\n where \"{} \\<equiv> bot\"",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"definition insert :: \"'a \\<Rightarrow> 'a set \\<Rightarrow> 'a set\"\n where insert_compr: \"insert a B = {x. x = a \\<or> x \\<in> B}\"",
"definition\n isomorphic :: \"[('a, 'm) Group_scheme, ('b, 'm1) Group_scheme]\n \\<Rightarrow> bool\" (infix \"\\<cong>\" 100) where\n \"F \\<cong> G \\<longleftrightarrow> (\\<exists>f. gbij\\<^bsub>F,G\\<^esub> f)\"",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"definition\n Gchain :: \"[nat, nat \\<Rightarrow> (('a set), 'more) Group_scheme] \\<Rightarrow> bool\" where\n \"Gchain n g \\<longleftrightarrow> (\\<forall>l \\<le> n. Group (g l))\"",
"definition\n Ugp :: \"_ \\<Rightarrow> bool\" where\n \"Ugp G == Group G \\<and> carrier G = {\\<one>\\<^bsub>G\\<^esub>}\""
] |
lemma_object
|
###symbols
Set.empty :::: 'a set
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Set.insert :::: 'a \<Rightarrow> 'a set \<Rightarrow> 'a set
Set.Collect :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a set
Algebra2.isomorphic :::: ('a, 'b) Group_scheme \<Rightarrow> ('c, 'd) Group_scheme \<Rightarrow> bool
Nat.Suc :::: nat \<Rightarrow> nat
Algebra3.Gchain :::: nat \<Rightarrow> (nat \<Rightarrow> ('a set, 'b) Group_scheme) \<Rightarrow> bool
Algebra2.Ugp :::: ('a, 'b) Group_scheme \<Rightarrow> bool
###defs
abbreviation empty :: "'a set" ("{}")
where "{} \<equiv> bot"
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
definition insert :: "'a \<Rightarrow> 'a set \<Rightarrow> 'a set"
where insert_compr: "insert a B = {x. x = a \<or> x \<in> B}"
definition
isomorphic :: "[('a, 'm) Group_scheme, ('b, 'm1) Group_scheme]
\<Rightarrow> bool" (infix "\<cong>" 100) where
"F \<cong> G \<longleftrightarrow> (\<exists>f. gbij\<^bsub>F,G\<^esub> f)"
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
definition
Gchain :: "[nat, nat \<Rightarrow> (('a set), 'more) Group_scheme] \<Rightarrow> bool" where
"Gchain n g \<longleftrightarrow> (\<forall>l \<le> n. Group (g l))"
definition
Ugp :: "_ \<Rightarrow> bool" where
"Ugp G == Group G \<and> carrier G = {\<one>\<^bsub>G\<^esub>}"
|
###output
Ugp ?E \<Longrightarrow> Gchain (Suc ?n) ?h \<Longrightarrow> ?k \<noteq> Suc ?n \<Longrightarrow> ?k \<le> Suc ?n \<Longrightarrow> ?h (Suc ?n) \<cong> ?E \<Longrightarrow> ?h ?k \<cong> ?E \<Longrightarrow> {i. i \<le> Suc ?n \<and> ?h i \<cong> ?E} = insert ?k (insert (Suc ?n) ({i. i \<le> Suc ?n \<and> ?h i \<cong> ?E} - { ?k, Suc ?n}))###end
|
CZH_Foundations/czh_semicategories/CZH_SMC_PSemicategory
|
CZH_SMC_PSemicategory.smcf_up_ObjMap_vdomain
| null |
\<D>\<^sub>\<circ> (smcf_up ?I ?\<AA> ?\<CC> ?\<phi>\<lparr>ObjMap\<rparr>) = ?\<CC>\<lparr>Obj\<rparr>
|
?H1 (?H2 (?H3 x_1 x_2 x_3 x_4) ?H4) = ?H2 x_3 ?H5
|
[
"CZH_DG_Digraph.Obj",
"CZH_DG_DGHM.ObjMap",
"CZH_SMC_PSemicategory.smcf_up",
"ZFC_Cardinals.app",
"CZH_Sets_BRelations.app_vdomain"
] |
[
"V",
"V",
"V \\<Rightarrow> (V \\<Rightarrow> V) \\<Rightarrow> V \\<Rightarrow> (V \\<Rightarrow> V) \\<Rightarrow> V",
"V \\<Rightarrow> V \\<Rightarrow> V",
"V \\<Rightarrow> V"
] |
[
"definition app :: \"[V,V] \\<Rightarrow> V\"\n where \"app f x \\<equiv> THE y. \\<langle>x,y\\<rangle> \\<in> elts f\""
] |
lemma_object
|
###symbols
CZH_DG_Digraph.Obj :::: V
CZH_DG_DGHM.ObjMap :::: V
CZH_SMC_PSemicategory.smcf_up :::: V \<Rightarrow> (V \<Rightarrow> V) \<Rightarrow> V \<Rightarrow> (V \<Rightarrow> V) \<Rightarrow> V
ZFC_Cardinals.app :::: V \<Rightarrow> V \<Rightarrow> V
CZH_Sets_BRelations.app_vdomain :::: V \<Rightarrow> V
###defs
definition app :: "[V,V] \<Rightarrow> V"
where "app f x \<equiv> THE y. \<langle>x,y\<rangle> \<in> elts f"
|
###output
\<D>\<^sub>\<circ> (smcf_up ?I ?\<AA> ?\<CC> ?\<phi>\<lparr>ObjMap\<rparr>) = ?\<CC>\<lparr>Obj\<rparr>###end
|
Van_Emde_Boas_Trees/Separation_Logic_Imperative_HOL/Assertions
|
Assertions.enttD
|
lemma enttD: "A\<Longrightarrow>\<^sub>tB \<Longrightarrow> A\<Longrightarrow>\<^sub>AB*True"
|
?A \<Longrightarrow>\<^sub>t ?B \<Longrightarrow> ?A \<Longrightarrow>\<^sub>A ?B * True
|
?H1 x_1 x_2 \<Longrightarrow> ?H2 x_1 (?H3 x_2 ?H4)
|
[
"Assertions.top_assn",
"Groups.times_class.times",
"Assertions.entails",
"Assertions.entailst"
] |
[
"assn",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"assn \\<Rightarrow> assn \\<Rightarrow> bool",
"assn \\<Rightarrow> assn \\<Rightarrow> bool"
] |
[
"abbreviation top_assn::assn (\"True\") where \"top_assn \\<equiv> top\"",
"class times =\n fixes times :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"*\" 70)",
"definition entails :: \"assn \\<Rightarrow> assn \\<Rightarrow> bool\" (infix \"\\<Longrightarrow>\\<^sub>A\" 10)\n where \"P \\<Longrightarrow>\\<^sub>A Q \\<equiv> \\<forall>h. h\\<Turnstile>P \\<longrightarrow> h\\<Turnstile>Q\"",
"definition entailst :: \"assn \\<Rightarrow> assn \\<Rightarrow> bool\" (infix \"\\<Longrightarrow>\\<^sub>t\" 10)\n where \"entailst A B \\<equiv> A \\<Longrightarrow>\\<^sub>A B * True\""
] |
lemma_object
|
###symbols
Assertions.top_assn :::: assn
Groups.times_class.times :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Assertions.entails :::: assn \<Rightarrow> assn \<Rightarrow> bool
Assertions.entailst :::: assn \<Rightarrow> assn \<Rightarrow> bool
###defs
abbreviation top_assn::assn ("True") where "top_assn \<equiv> top"
class times =
fixes times :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "*" 70)
definition entails :: "assn \<Rightarrow> assn \<Rightarrow> bool" (infix "\<Longrightarrow>\<^sub>A" 10)
where "P \<Longrightarrow>\<^sub>A Q \<equiv> \<forall>h. h\<Turnstile>P \<longrightarrow> h\<Turnstile>Q"
definition entailst :: "assn \<Rightarrow> assn \<Rightarrow> bool" (infix "\<Longrightarrow>\<^sub>t" 10)
where "entailst A B \<equiv> A \<Longrightarrow>\<^sub>A B * True"
|
###output
?A \<Longrightarrow>\<^sub>t ?B \<Longrightarrow> ?A \<Longrightarrow>\<^sub>A ?B * True###end
|
ABY3_Protocols/Shuffle
|
Shuffle.inj_split_Cons'
|
lemma inj_split_Cons': "inj_on (\<lambda>(n, xs). n#xs) X"
|
inj_on (\<lambda>(n, xs). n # xs) ?X
|
?H1 (?H2 ?H3) x_1
|
[
"List.list.Cons",
"Product_Type.prod.case_prod",
"Fun.inj_on"
] |
[
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"('a \\<Rightarrow> 'b \\<Rightarrow> 'c) \\<Rightarrow> 'a \\<times> 'b \\<Rightarrow> 'c",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"definition inj_on :: \"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a set \\<Rightarrow> bool\" \\<comment> \\<open>injective\\<close>\n where \"inj_on f A \\<longleftrightarrow> (\\<forall>x\\<in>A. \\<forall>y\\<in>A. f x = f y \\<longrightarrow> x = y)\""
] |
lemma_object
|
###symbols
List.list.Cons :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a list
Product_Type.prod.case_prod :::: ('a \<Rightarrow> 'b \<Rightarrow> 'c) \<Rightarrow> 'a \<times> 'b \<Rightarrow> 'c
Fun.inj_on :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a set \<Rightarrow> bool
###defs
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
definition inj_on :: "('a \<Rightarrow> 'b) \<Rightarrow> 'a set \<Rightarrow> bool" \<comment> \<open>injective\<close>
where "inj_on f A \<longleftrightarrow> (\<forall>x\<in>A. \<forall>y\<in>A. f x = f y \<longrightarrow> x = y)"
|
###output
inj_on (\<lambda>(n, xs). n # xs) ?X###end
|
S_Finite_Measure_Monad/Monad_QuasiBorel
|
Monad_QuasiBorel.qbs_s_finite_eq'_dest(2)
|
lemma qbs_s_finite_eq'_dest:
assumes "qbs_s_finite_eq' (X,\<alpha>,\<mu>) (Y,\<beta>,\<nu>)"
shows "qbs_s_finite X \<alpha> \<mu>" "qbs_s_finite Y \<beta> \<nu>" "Y = X" "\<And>f. f \<in> X \<rightarrow>\<^sub>Q qbs_borel \<Longrightarrow> (\<integral>\<^sup>+x. f (\<alpha> x) \<partial> \<mu>) = (\<integral>\<^sup>+x. f (\<beta> x) \<partial> \<nu>)"
|
qbs_s_finite_eq' (?X, ?\<alpha>, ?\<mu>) (?Y, ?\<beta>, ?\<nu>) \<Longrightarrow> qbs_s_finite ?Y ?\<beta> ?\<nu>
|
?H1 (x_1, x_2, x_3) (x_4, x_5, x_6) \<Longrightarrow> ?H2 x_4 x_5 x_6
|
[
"Monad_QuasiBorel.qbs_s_finite",
"Monad_QuasiBorel.qbs_s_finite_eq'"
] |
[
"'a quasi_borel \\<Rightarrow> (real \\<Rightarrow> 'a) \\<Rightarrow> real measure \\<Rightarrow> bool",
"'a quasi_borel \\<times> (real \\<Rightarrow> 'a) \\<times> real measure \\<Rightarrow> 'a quasi_borel \\<times> (real \\<Rightarrow> 'a) \\<times> real measure \\<Rightarrow> bool"
] |
[
"definition qbs_s_finite_eq' :: \"['a qbs_s_finite_t, 'a qbs_s_finite_t] \\<Rightarrow> bool\" where\n \"qbs_s_finite_eq' p1 p2 \\<equiv>\n (let (X, \\<alpha>, \\<mu>) = p1;\n (Y, \\<beta>, \\<nu>) = p2 in\n qbs_s_finite X \\<alpha> \\<mu> \\<and> qbs_s_finite Y \\<beta> \\<nu> \\<and> X = Y \\<and>\n (\\<forall>f\\<in>X \\<rightarrow>\\<^sub>Q (qbs_borel :: ennreal quasi_borel). (\\<integral>\\<^sup>+x. f (\\<alpha> x) \\<partial>\\<mu>) = (\\<integral>\\<^sup>+x. f (\\<beta> x) \\<partial>\\<nu>)))\""
] |
lemma_object
|
###symbols
Monad_QuasiBorel.qbs_s_finite :::: 'a quasi_borel \<Rightarrow> (real \<Rightarrow> 'a) \<Rightarrow> real measure \<Rightarrow> bool
Monad_QuasiBorel.qbs_s_finite_eq' :::: 'a quasi_borel \<times> (real \<Rightarrow> 'a) \<times> real measure \<Rightarrow> 'a quasi_borel \<times> (real \<Rightarrow> 'a) \<times> real measure \<Rightarrow> bool
###defs
definition qbs_s_finite_eq' :: "['a qbs_s_finite_t, 'a qbs_s_finite_t] \<Rightarrow> bool" where
"qbs_s_finite_eq' p1 p2 \<equiv>
(let (X, \<alpha>, \<mu>) = p1;
(Y, \<beta>, \<nu>) = p2 in
qbs_s_finite X \<alpha> \<mu> \<and> qbs_s_finite Y \<beta> \<nu> \<and> X = Y \<and>
(\<forall>f\<in>X \<rightarrow>\<^sub>Q (qbs_borel :: ennreal quasi_borel). (\<integral>\<^sup>+x. f (\<alpha> x) \<partial>\<mu>) = (\<integral>\<^sup>+x. f (\<beta> x) \<partial>\<nu>)))"
|
###output
qbs_s_finite_eq' (?X, ?\<alpha>, ?\<mu>) (?Y, ?\<beta>, ?\<nu>) \<Longrightarrow> qbs_s_finite ?Y ?\<beta> ?\<nu>###end
|
List-Infinite/ListInf/ListInf
|
ListInf.i_drop_Suc_append
|
lemma i_drop_Suc_append[simp]: "((x # xs) \<frown> f) \<Up> Suc n = ((xs \<frown> f) \<Up> n)"
|
((?x # ?xs) \<frown> ?f) \<Up> Suc ?n = (?xs \<frown> ?f) \<Up> ?n
|
?H1 (?H2 (?H3 x_1 x_2) x_3) (?H4 x_4) = ?H1 (?H2 x_2 x_3) x_4
|
[
"Nat.Suc",
"List.list.Cons",
"ListInf.i_append",
"ListInf.i_drop'"
] |
[
"nat \\<Rightarrow> nat",
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"'a list \\<Rightarrow> (nat \\<Rightarrow> 'a) \\<Rightarrow> nat \\<Rightarrow> 'a",
"(nat \\<Rightarrow> 'a) \\<Rightarrow> nat \\<Rightarrow> nat \\<Rightarrow> 'a"
] |
[
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"definition i_append :: \"'a list \\<Rightarrow> 'a ilist \\<Rightarrow> 'a ilist\" (infixr \"\\<frown>\" 65)\n where \"xs \\<frown> f \\<equiv> \\<lambda>n. if n < length xs then xs ! n else f (n - length xs)\"",
"abbreviation i_drop' :: \"'a ilist \\<Rightarrow> nat \\<Rightarrow> 'a ilist\" (infixl \"\\<Up>\" 100)\n where \"f \\<Up> n \\<equiv> i_drop n f\""
] |
lemma_object
|
###symbols
Nat.Suc :::: nat \<Rightarrow> nat
List.list.Cons :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a list
ListInf.i_append :::: 'a list \<Rightarrow> (nat \<Rightarrow> 'a) \<Rightarrow> nat \<Rightarrow> 'a
ListInf.i_drop' :::: (nat \<Rightarrow> 'a) \<Rightarrow> nat \<Rightarrow> nat \<Rightarrow> 'a
###defs
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
definition i_append :: "'a list \<Rightarrow> 'a ilist \<Rightarrow> 'a ilist" (infixr "\<frown>" 65)
where "xs \<frown> f \<equiv> \<lambda>n. if n < length xs then xs ! n else f (n - length xs)"
abbreviation i_drop' :: "'a ilist \<Rightarrow> nat \<Rightarrow> 'a ilist" (infixl "\<Up>" 100)
where "f \<Up> n \<equiv> i_drop n f"
|
###output
((?x # ?xs) \<frown> ?f) \<Up> Suc ?n = (?xs \<frown> ?f) \<Up> ?n###end
|
Combinatorial_Q_Analogues/Q_Analogues
|
Q_Analogues.qbinomial_rec2
|
lemma qbinomial_rec2:
fixes q :: "'a :: real_normed_field"
assumes "norm q \<noteq> 1" "n > 0" "k < n"
shows "qbinomial q n k = (1 - q ^ n) / (1 - q ^ (n - k)) * qbinomial q (n-1) k"
|
norm ?q \<noteq> 1 \<Longrightarrow> 0 < ?n \<Longrightarrow> ?k < ?n \<Longrightarrow> qbinomial ?q ?n ?k = ((1:: ?'a) - ?q ^ ?n) / ((1:: ?'a) - ?q ^ (?n - ?k)) * qbinomial ?q (?n - 1) ?k
|
\<lbrakk> ?H1 x_1 \<noteq> ?H2; ?H3 < x_2; x_3 < x_2\<rbrakk> \<Longrightarrow> ?H4 x_1 x_2 x_3 = ?H5 (?H6 (?H7 ?H8 (?H9 x_1 x_2)) (?H7 ?H8 (?H9 x_1 (?H10 x_2 x_3)))) (?H4 x_1 (?H10 x_2 ?H11) x_3)
|
[
"Power.power_class.power",
"Groups.minus_class.minus",
"Fields.inverse_class.inverse_divide",
"Groups.times_class.times",
"Q_Analogues.qbinomial",
"Groups.zero_class.zero",
"Groups.one_class.one",
"Real_Vector_Spaces.norm_class.norm"
] |
[
"'a \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a \\<Rightarrow> nat \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a",
"'a",
"'a \\<Rightarrow> real"
] |
[
"primrec power :: \"'a \\<Rightarrow> nat \\<Rightarrow> 'a\" (infixr \"^\" 80)\n where\n power_0: \"a ^ 0 = 1\"\n | power_Suc: \"a ^ Suc n = a * a ^ n\"",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"class inverse = divide +\n fixes inverse :: \"'a \\<Rightarrow> 'a\"\nbegin",
"class times =\n fixes times :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"*\" 70)",
"fun qbinomial :: \"'a \\<Rightarrow> nat \\<Rightarrow> nat \\<Rightarrow> 'a :: field\" where\n \"qbinomial q n 0 = 1\"\n| \"qbinomial q 0 (Suc k) = 0\"\n| \"qbinomial q (Suc n) (Suc k) = q ^ Suc k * qbinomial q n (Suc k) + qbinomial q n k\"",
"class zero =\n fixes zero :: 'a (\"0\")",
"class one =\n fixes one :: 'a (\"1\")",
"class norm =\n fixes norm :: \"'a \\<Rightarrow> real\""
] |
lemma_object
|
###symbols
Power.power_class.power :::: 'a \<Rightarrow> nat \<Rightarrow> 'a
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Fields.inverse_class.inverse_divide :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Groups.times_class.times :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Q_Analogues.qbinomial :::: 'a \<Rightarrow> nat \<Rightarrow> nat \<Rightarrow> 'a
Groups.zero_class.zero :::: 'a
Groups.one_class.one :::: 'a
Real_Vector_Spaces.norm_class.norm :::: 'a \<Rightarrow> real
###defs
primrec power :: "'a \<Rightarrow> nat \<Rightarrow> 'a" (infixr "^" 80)
where
power_0: "a ^ 0 = 1"
| power_Suc: "a ^ Suc n = a * a ^ n"
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
class inverse = divide +
fixes inverse :: "'a \<Rightarrow> 'a"
begin
class times =
fixes times :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "*" 70)
fun qbinomial :: "'a \<Rightarrow> nat \<Rightarrow> nat \<Rightarrow> 'a :: field" where
"qbinomial q n 0 = 1"
| "qbinomial q 0 (Suc k) = 0"
| "qbinomial q (Suc n) (Suc k) = q ^ Suc k * qbinomial q n (Suc k) + qbinomial q n k"
class zero =
fixes zero :: 'a ("0")
class one =
fixes one :: 'a ("1")
class norm =
fixes norm :: "'a \<Rightarrow> real"
|
###output
norm ?q \<noteq> 1 \<Longrightarrow> 0 < ?n \<Longrightarrow> ?k < ?n \<Longrightarrow> qbinomial ?q ?n ?k = ((1:: ?'a) - ?q ^ ?n) / ((1:: ?'a) - ?q ^ (?n - ?k)) * qbinomial ?q (?n - 1) ?k###end
|
Collections/Iterator/SetIterator
|
SetIterator.map_iterator_genord_I
| null |
distinct (map fst ?l0.0) \<Longrightarrow> ?m = map_of ?l0.0 \<Longrightarrow> sorted_wrt ?R ?l0.0 \<Longrightarrow> ?iti = foldli ?l0.0 \<Longrightarrow> map_iterator_genord ?iti ?m ?R
|
\<lbrakk> ?H1 (?H2 ?H3 x_1); x_2 = ?H4 x_1; ?H5 x_3 x_1; x_4 = ?H6 x_1\<rbrakk> \<Longrightarrow> ?H7 x_4 x_2 x_3
|
[
"SetIterator.map_iterator_genord",
"Foldi.foldli",
"List.sorted_wrt",
"Map.map_of",
"Product_Type.prod.fst",
"List.list.map",
"List.distinct"
] |
[
"(('a \\<Rightarrow> bool) \\<Rightarrow> ('b \\<times> 'c \\<Rightarrow> 'a \\<Rightarrow> 'a) \\<Rightarrow> 'a \\<Rightarrow> 'a) \\<Rightarrow> ('b \\<Rightarrow> 'c option) \\<Rightarrow> ('b \\<times> 'c \\<Rightarrow> 'b \\<times> 'c \\<Rightarrow> bool) \\<Rightarrow> bool",
"'a list \\<Rightarrow> ('b \\<Rightarrow> bool) \\<Rightarrow> ('a \\<Rightarrow> 'b \\<Rightarrow> 'b) \\<Rightarrow> 'b \\<Rightarrow> 'b",
"('a \\<Rightarrow> 'a \\<Rightarrow> bool) \\<Rightarrow> 'a list \\<Rightarrow> bool",
"('a \\<times> 'b) list \\<Rightarrow> 'a \\<Rightarrow> 'b option",
"'a \\<times> 'b \\<Rightarrow> 'a",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a list \\<Rightarrow> 'b list",
"'a list \\<Rightarrow> bool"
] |
[
"fun sorted_wrt :: \"('a \\<Rightarrow> 'a \\<Rightarrow> bool) \\<Rightarrow> 'a list \\<Rightarrow> bool\" where\n\"sorted_wrt P [] = True\" |\n\"sorted_wrt P (x # ys) = ((\\<forall>y \\<in> set ys. P x y) \\<and> sorted_wrt P ys)\"",
"primrec map_of :: \"('a \\<times> 'b) list \\<Rightarrow> 'a \\<rightharpoonup> 'b\" where\n \"map_of [] = empty\"\n| \"map_of (p # ps) = (map_of ps)(fst p \\<mapsto> snd p)\"",
"definition \"prod = {f. \\<exists>a b. f = Pair_Rep (a::'a) (b::'b)}\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec distinct :: \"'a list \\<Rightarrow> bool\" where\n\"distinct [] \\<longleftrightarrow> True\" |\n\"distinct (x # xs) \\<longleftrightarrow> x \\<notin> set xs \\<and> distinct xs\""
] |
lemma_object
|
###symbols
SetIterator.map_iterator_genord :::: (('a \<Rightarrow> bool) \<Rightarrow> ('b \<times> 'c \<Rightarrow> 'a \<Rightarrow> 'a) \<Rightarrow> 'a \<Rightarrow> 'a) \<Rightarrow> ('b \<Rightarrow> 'c option) \<Rightarrow> ('b \<times> 'c \<Rightarrow> 'b \<times> 'c \<Rightarrow> bool) \<Rightarrow> bool
Foldi.foldli :::: 'a list \<Rightarrow> ('b \<Rightarrow> bool) \<Rightarrow> ('a \<Rightarrow> 'b \<Rightarrow> 'b) \<Rightarrow> 'b \<Rightarrow> 'b
List.sorted_wrt :::: ('a \<Rightarrow> 'a \<Rightarrow> bool) \<Rightarrow> 'a list \<Rightarrow> bool
Map.map_of :::: ('a \<times> 'b) list \<Rightarrow> 'a \<Rightarrow> 'b option
Product_Type.prod.fst :::: 'a \<times> 'b \<Rightarrow> 'a
List.list.map :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a list \<Rightarrow> 'b list
List.distinct :::: 'a list \<Rightarrow> bool
###defs
fun sorted_wrt :: "('a \<Rightarrow> 'a \<Rightarrow> bool) \<Rightarrow> 'a list \<Rightarrow> bool" where
"sorted_wrt P [] = True" |
"sorted_wrt P (x # ys) = ((\<forall>y \<in> set ys. P x y) \<and> sorted_wrt P ys)"
primrec map_of :: "('a \<times> 'b) list \<Rightarrow> 'a \<rightharpoonup> 'b" where
"map_of [] = empty"
| "map_of (p # ps) = (map_of ps)(fst p \<mapsto> snd p)"
definition "prod = {f. \<exists>a b. f = Pair_Rep (a::'a) (b::'b)}"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec distinct :: "'a list \<Rightarrow> bool" where
"distinct [] \<longleftrightarrow> True" |
"distinct (x # xs) \<longleftrightarrow> x \<notin> set xs \<and> distinct xs"
|
###output
distinct (map fst ?l0.0) \<Longrightarrow> ?m = map_of ?l0.0 \<Longrightarrow> sorted_wrt ?R ?l0.0 \<Longrightarrow> ?iti = foldli ?l0.0 \<Longrightarrow> map_iterator_genord ?iti ?m ?R###end
|
List-Infinite/ListInf/ListInf
|
ListInf.glength_0_conv
|
lemma glength_0_conv[simp]: "(glength a = 0) = (a = FL [])"
|
(glength ?a = 0) = (?a = FL [])
|
(?H1 x_1 = ?H2) = (x_1 = ?H3 ?H4)
|
[
"List.list.Nil",
"ListInf.glist.FL",
"Groups.zero_class.zero",
"ListInf.glength"
] |
[
"'a list",
"'a list \\<Rightarrow> 'a glist",
"'a",
"'a glist \\<Rightarrow> enat"
] |
[
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype (gset: 'a) glist = FL \"'a list\" | IL \"'a ilist\" for map: gmap",
"class zero =\n fixes zero :: 'a (\"0\")",
"definition glength :: \"'a glist \\<Rightarrow> enat\"\nwhere\n \"glength a \\<equiv> case a of\n FL xs \\<Rightarrow> enat (length xs) |\n IL f \\<Rightarrow> \\<infinity>\""
] |
lemma_object
|
###symbols
List.list.Nil :::: 'a list
ListInf.glist.FL :::: 'a list \<Rightarrow> 'a glist
Groups.zero_class.zero :::: 'a
ListInf.glength :::: 'a glist \<Rightarrow> enat
###defs
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype (gset: 'a) glist = FL "'a list" | IL "'a ilist" for map: gmap
class zero =
fixes zero :: 'a ("0")
definition glength :: "'a glist \<Rightarrow> enat"
where
"glength a \<equiv> case a of
FL xs \<Rightarrow> enat (length xs) |
IL f \<Rightarrow> \<infinity>"
|
###output
(glength ?a = 0) = (?a = FL [])###end
|
Polynomials/More_MPoly_Type
|
More_MPoly_Type.one_term_is_monomial
|
lemma one_term_is_monomial:
assumes "card (keys (mapping_of p)) \<le> 1"
obtains m where "p = monom m (coeff p m)"
|
card (keys (mapping_of ?p)) \<le> 1 \<Longrightarrow> (\<And>m. ?p = monom m (coeff ?p m) \<Longrightarrow> ?thesis) \<Longrightarrow> ?thesis
|
\<lbrakk> ?H1 (?H2 (?H3 x_1)) \<le> ?H4; \<And>y_0. x_1 = ?H5 y_0 (?H6 x_1 y_0) \<Longrightarrow> x_2\<rbrakk> \<Longrightarrow> x_2
|
[
"MPoly_Type.coeff",
"MPoly_Type.monom",
"Groups.one_class.one",
"MPoly_Type.mpoly.mapping_of",
"More_MPoly_Type.keys",
"Finite_Set.card"
] |
[
"'a mpoly \\<Rightarrow> (nat \\<Rightarrow>\\<^sub>0 nat) \\<Rightarrow> 'a",
"(nat \\<Rightarrow>\\<^sub>0 nat) \\<Rightarrow> 'a \\<Rightarrow> 'a mpoly",
"'a",
"'a mpoly \\<Rightarrow> (nat \\<Rightarrow>\\<^sub>0 nat) \\<Rightarrow>\\<^sub>0 'a",
"('a \\<Rightarrow>\\<^sub>0 'b) \\<Rightarrow> 'a set",
"'a set \\<Rightarrow> nat"
] |
[
"definition coeff :: \"'a::zero mpoly \\<Rightarrow> (nat \\<Rightarrow>\\<^sub>0 nat) \\<Rightarrow> 'a\"\nwhere\n \"coeff p = Poly_Mapping.lookup (mapping_of p)\"",
"class one =\n fixes one :: 'a (\"1\")",
"abbreviation \"keys == Poly_Mapping.keys\""
] |
lemma_object
|
###symbols
MPoly_Type.coeff :::: 'a mpoly \<Rightarrow> (nat \<Rightarrow>\<^sub>0 nat) \<Rightarrow> 'a
MPoly_Type.monom :::: (nat \<Rightarrow>\<^sub>0 nat) \<Rightarrow> 'a \<Rightarrow> 'a mpoly
Groups.one_class.one :::: 'a
MPoly_Type.mpoly.mapping_of :::: 'a mpoly \<Rightarrow> (nat \<Rightarrow>\<^sub>0 nat) \<Rightarrow>\<^sub>0 'a
More_MPoly_Type.keys :::: ('a \<Rightarrow>\<^sub>0 'b) \<Rightarrow> 'a set
Finite_Set.card :::: 'a set \<Rightarrow> nat
###defs
definition coeff :: "'a::zero mpoly \<Rightarrow> (nat \<Rightarrow>\<^sub>0 nat) \<Rightarrow> 'a"
where
"coeff p = Poly_Mapping.lookup (mapping_of p)"
class one =
fixes one :: 'a ("1")
abbreviation "keys == Poly_Mapping.keys"
|
###output
card (keys (mapping_of ?p)) \<le> 1 \<Longrightarrow> (\<And>m. ?p = monom m (coeff ?p m) \<Longrightarrow> ?thesis) \<Longrightarrow> ?thesis###end
|
S_Finite_Measure_Monad/Query
|
Query.nc_hnormal_f
|
lemma nc_hnormal_f: "qbs_l (density_qbs lborel_qbs hnormal_f) UNIV = ennreal (1/ 2)"
|
0 < ?\<sigma> \<Longrightarrow> emeasure (qbs_l (density_qbs lborel\<^sub>Q (\<lambda>x. ennreal (hnormal_f ?\<mu> ?\<sigma> x)))) UNIV = ennreal (1 / 2)
|
?H1 < x_1 \<Longrightarrow> ?H2 (?H3 (?H4 ?H5 (\<lambda>y_0. ?H6 (?H7 x_2 x_1 y_0)))) ?H8 = ?H6 (?H9 ?H10 (?H11 (?H12 ?H13)))
|
[
"Num.num.One",
"Num.num.Bit0",
"Num.numeral_class.numeral",
"Groups.one_class.one",
"Fields.inverse_class.inverse_divide",
"Set.UNIV",
"Query.hnormal_f",
"Extended_Nonnegative_Real.ennreal",
"Monad_QuasiBorel.lborel_qbs",
"Monad_QuasiBorel.density_qbs",
"Monad_QuasiBorel.qbs_l",
"Sigma_Algebra.emeasure",
"Groups.zero_class.zero"
] |
[
"num",
"num \\<Rightarrow> num",
"num \\<Rightarrow> 'a",
"'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a set",
"real \\<Rightarrow> real \\<Rightarrow> real \\<Rightarrow> real",
"real \\<Rightarrow> ennreal",
"'a qbs_measure",
"'a qbs_measure \\<Rightarrow> ('a \\<Rightarrow> ennreal) \\<Rightarrow> 'a qbs_measure",
"'a qbs_measure \\<Rightarrow> 'a measure",
"'a measure \\<Rightarrow> 'a set \\<Rightarrow> ennreal",
"'a"
] |
[
"datatype num = One | Bit0 num | Bit1 num",
"datatype num = One | Bit0 num | Bit1 num",
"primrec numeral :: \"num \\<Rightarrow> 'a\"\n where\n numeral_One: \"numeral One = 1\"\n | numeral_Bit0: \"numeral (Bit0 n) = numeral n + numeral n\"\n | numeral_Bit1: \"numeral (Bit1 n) = numeral n + numeral n + 1\"",
"class one =\n fixes one :: 'a (\"1\")",
"class inverse = divide +\n fixes inverse :: \"'a \\<Rightarrow> 'a\"\nbegin",
"abbreviation UNIV :: \"'a set\"\n where \"UNIV \\<equiv> top\"",
"definition \"hnormal_f \\<equiv> (\\<lambda>x. if x \\<le> \\<mu> then 0 else normal_density \\<mu> \\<sigma> x)\"",
"typedef ennreal = \"{x :: ereal. 0 \\<le> x}\"\n morphisms enn2ereal e2ennreal'",
"definition lborel_qbs (\"lborel\\<^sub>Q\") where \"lborel_qbs \\<equiv> qbs_l_inverse lborel\"",
"class zero =\n fixes zero :: 'a (\"0\")"
] |
lemma_object
|
###symbols
Num.num.One :::: num
Num.num.Bit0 :::: num \<Rightarrow> num
Num.numeral_class.numeral :::: num \<Rightarrow> 'a
Groups.one_class.one :::: 'a
Fields.inverse_class.inverse_divide :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Set.UNIV :::: 'a set
Query.hnormal_f :::: real \<Rightarrow> real \<Rightarrow> real \<Rightarrow> real
Extended_Nonnegative_Real.ennreal :::: real \<Rightarrow> ennreal
Monad_QuasiBorel.lborel_qbs :::: 'a qbs_measure
Monad_QuasiBorel.density_qbs :::: 'a qbs_measure \<Rightarrow> ('a \<Rightarrow> ennreal) \<Rightarrow> 'a qbs_measure
Monad_QuasiBorel.qbs_l :::: 'a qbs_measure \<Rightarrow> 'a measure
Sigma_Algebra.emeasure :::: 'a measure \<Rightarrow> 'a set \<Rightarrow> ennreal
Groups.zero_class.zero :::: 'a
###defs
datatype num = One | Bit0 num | Bit1 num
datatype num = One | Bit0 num | Bit1 num
primrec numeral :: "num \<Rightarrow> 'a"
where
numeral_One: "numeral One = 1"
| numeral_Bit0: "numeral (Bit0 n) = numeral n + numeral n"
| numeral_Bit1: "numeral (Bit1 n) = numeral n + numeral n + 1"
class one =
fixes one :: 'a ("1")
class inverse = divide +
fixes inverse :: "'a \<Rightarrow> 'a"
begin
abbreviation UNIV :: "'a set"
where "UNIV \<equiv> top"
definition "hnormal_f \<equiv> (\<lambda>x. if x \<le> \<mu> then 0 else normal_density \<mu> \<sigma> x)"
typedef ennreal = "{x :: ereal. 0 \<le> x}"
morphisms enn2ereal e2ennreal'
definition lborel_qbs ("lborel\<^sub>Q") where "lborel_qbs \<equiv> qbs_l_inverse lborel"
class zero =
fixes zero :: 'a ("0")
|
###output
0 < ?\<sigma> \<Longrightarrow> emeasure (qbs_l (density_qbs lborel\<^sub>Q (\<lambda>x. ennreal (hnormal_f ?\<mu> ?\<sigma> x)))) UNIV = ennreal (1 / 2)###end
|
Ordinal/OrdinalInduct
|
OrdinalInduct.strict_mono_f_make_mono
|
lemma strict_mono_f_make_mono:
"\<forall>n. f n < oLimit f \<Longrightarrow> strict_mono (\<lambda>n. f (make_mono f n))"
|
\<forall>n. ?f n < oLimit ?f \<Longrightarrow> OrdinalInduct.strict_mono (\<lambda>n. ?f (make_mono ?f n))
|
\<forall>y_0. x_1 y_0 < ?H1 x_1 \<Longrightarrow> ?H2 (\<lambda>y_1. x_1 (?H3 x_1 y_1))
|
[
"OrdinalInduct.make_mono",
"OrdinalInduct.strict_mono",
"OrdinalInduct.oLimit"
] |
[
"(nat \\<Rightarrow> ordinal) \\<Rightarrow> nat \\<Rightarrow> nat",
"('a \\<Rightarrow> 'b) \\<Rightarrow> bool",
"(nat \\<Rightarrow> ordinal) \\<Rightarrow> ordinal"
] |
[
"primrec make_mono :: \"(nat \\<Rightarrow> ordinal) \\<Rightarrow> nat \\<Rightarrow> nat\"\n where\n \"make_mono f 0 = 0\"\n | \"make_mono f (Suc n) = (LEAST x. f (make_mono f n) < f x)\"",
"definition\n oLimit :: \"(nat \\<Rightarrow> ordinal) \\<Rightarrow> ordinal\" where\n \"oLimit f = (LEAST k. \\<forall>n. f n \\<le> k)\""
] |
lemma_object
|
###symbols
OrdinalInduct.make_mono :::: (nat \<Rightarrow> ordinal) \<Rightarrow> nat \<Rightarrow> nat
OrdinalInduct.strict_mono :::: ('a \<Rightarrow> 'b) \<Rightarrow> bool
OrdinalInduct.oLimit :::: (nat \<Rightarrow> ordinal) \<Rightarrow> ordinal
###defs
primrec make_mono :: "(nat \<Rightarrow> ordinal) \<Rightarrow> nat \<Rightarrow> nat"
where
"make_mono f 0 = 0"
| "make_mono f (Suc n) = (LEAST x. f (make_mono f n) < f x)"
definition
oLimit :: "(nat \<Rightarrow> ordinal) \<Rightarrow> ordinal" where
"oLimit f = (LEAST k. \<forall>n. f n \<le> k)"
|
###output
\<forall>n. ?f n < oLimit ?f \<Longrightarrow> OrdinalInduct.strict_mono (\<lambda>n. ?f (make_mono ?f n))###end
|
Quasi_Borel_Spaces/Probability_Space_QuasiBorel
|
Probability_Space_QuasiBorel.qbs_integrable_cong
|
lemma qbs_integrable_cong:
assumes "qbs_prob_space_qbs s = X"
"\<And>x. x \<in> qbs_space X \<Longrightarrow> f x = g x"
and "qbs_integrable s f"
shows "qbs_integrable s g"
|
qbs_prob_space_qbs ?s = ?X \<Longrightarrow> (\<And>x. x \<in> qbs_space ?X \<Longrightarrow> ?f x = ?g x) \<Longrightarrow> qbs_integrable ?s ?f \<Longrightarrow> qbs_integrable ?s ?g
|
\<lbrakk> ?H1 x_1 = x_2; \<And>y_0. y_0 \<in> ?H2 x_2 \<Longrightarrow> x_3 y_0 = x_4 y_0; ?H3 x_1 x_3\<rbrakk> \<Longrightarrow> ?H3 x_1 x_4
|
[
"Probability_Space_QuasiBorel.qbs_integrable",
"QuasiBorel.qbs_space",
"Probability_Space_QuasiBorel.qbs_prob_space_qbs"
] |
[
"'a qbs_prob_space \\<Rightarrow> ('a \\<Rightarrow> real) \\<Rightarrow> bool",
"'a quasi_borel \\<Rightarrow> 'a set",
"'a qbs_prob_space \\<Rightarrow> 'a quasi_borel"
] |
[
"definition qbs_space :: \"'a quasi_borel \\<Rightarrow> 'a set\" where\n \"qbs_space X \\<equiv> fst (Rep_quasi_borel X)\""
] |
lemma_object
|
###symbols
Probability_Space_QuasiBorel.qbs_integrable :::: 'a qbs_prob_space \<Rightarrow> ('a \<Rightarrow> real) \<Rightarrow> bool
QuasiBorel.qbs_space :::: 'a quasi_borel \<Rightarrow> 'a set
Probability_Space_QuasiBorel.qbs_prob_space_qbs :::: 'a qbs_prob_space \<Rightarrow> 'a quasi_borel
###defs
definition qbs_space :: "'a quasi_borel \<Rightarrow> 'a set" where
"qbs_space X \<equiv> fst (Rep_quasi_borel X)"
|
###output
qbs_prob_space_qbs ?s = ?X \<Longrightarrow> (\<And>x. x \<in> qbs_space ?X \<Longrightarrow> ?f x = ?g x) \<Longrightarrow> qbs_integrable ?s ?f \<Longrightarrow> qbs_integrable ?s ?g###end
|
Monomorphic_Monad/Interpreter
|
Interpreter.rel_exp_simps(2)
|
lemma rel_exp_simps [simp]:
"rel_exp V (Var x) e' \<longleftrightarrow> (\<exists>y. e' = Var y \<and> V x y)"
"rel_exp V (Const n) e' \<longleftrightarrow> e' = Const n"
"rel_exp V (Plus e1 e2) e' \<longleftrightarrow> (\<exists>e1' e2'. e' = Plus e1' e2' \<and> rel_exp V e1 e1' \<and> rel_exp V e2 e2')"
"rel_exp V (Div e1 e2) e' \<longleftrightarrow> (\<exists>e1' e2'. e' = Div e1' e2' \<and> rel_exp V e1 e1' \<and> rel_exp V e2 e2')"
"rel_exp V e (Var y) \<longleftrightarrow> (\<exists>x. e = Var x \<and> V x y)"
"rel_exp V e (Const n) \<longleftrightarrow> e = Const n"
"rel_exp V e (Plus e1' e2') \<longleftrightarrow> (\<exists>e1 e2. e = Plus e1 e2 \<and> rel_exp V e1 e1' \<and> rel_exp V e2 e2')"
"rel_exp V e (Div e1' e2') \<longleftrightarrow> (\<exists>e1 e2. e = Div e1 e2 \<and> rel_exp V e1 e1' \<and> rel_exp V e2 e2')"
|
rel_exp ?V (Const ?n) ?e' = (?e' = Const ?n)
|
?H1 x_1 (?H2 x_2) x_3 = (x_3 = ?H3 x_2)
|
[
"Interpreter.exp.Const",
"Interpreter.exp.rel_exp"
] |
[
"int \\<Rightarrow> 'a exp",
"('a \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> 'a exp \\<Rightarrow> 'b exp \\<Rightarrow> bool"
] |
[
"datatype (vars: 'v) exp = Var 'v | Const int | Plus \"'v exp\" \"'v exp\" | Div \"'v exp\" \"'v exp\"",
"datatype (vars: 'v) exp = Var 'v | Const int | Plus \"'v exp\" \"'v exp\" | Div \"'v exp\" \"'v exp\""
] |
lemma_object
|
###symbols
Interpreter.exp.Const :::: int \<Rightarrow> 'a exp
Interpreter.exp.rel_exp :::: ('a \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> 'a exp \<Rightarrow> 'b exp \<Rightarrow> bool
###defs
datatype (vars: 'v) exp = Var 'v | Const int | Plus "'v exp" "'v exp" | Div "'v exp" "'v exp"
datatype (vars: 'v) exp = Var 'v | Const int | Plus "'v exp" "'v exp" | Div "'v exp" "'v exp"
|
###output
rel_exp ?V (Const ?n) ?e' = (?e' = Const ?n)###end
|
Shadow_DOM/Shadow_DOM
|
Shadow_DOM.in_disconnected_nodes_no_parent
|
lemma in_disconnected_nodes_no_parent:
assumes "heap_is_wellformed h"
assumes "h \<turnstile> get_parent node_ptr \<rightarrow>\<^sub>r None"
assumes "h \<turnstile> get_owner_document (cast node_ptr) \<rightarrow>\<^sub>r owner_document"
assumes "h \<turnstile> get_disconnected_nodes owner_document \<rightarrow>\<^sub>r disc_nodes"
assumes "known_ptrs h"
assumes "type_wf h"
shows "node_ptr \<in> set disc_nodes"
|
Shadow_DOM.heap_is_wellformed ?h \<Longrightarrow> ?h \<turnstile> Shadow_DOM.get_parent ?node_ptr \<rightarrow>\<^sub>r None \<Longrightarrow> ?h \<turnstile> Shadow_DOM.get_owner_document (cast\<^sub>n\<^sub>o\<^sub>d\<^sub>e\<^sub>_\<^sub>p\<^sub>t\<^sub>r\<^sub>2\<^sub>o\<^sub>b\<^sub>j\<^sub>e\<^sub>c\<^sub>t\<^sub>_\<^sub>p\<^sub>t\<^sub>r ?node_ptr) \<rightarrow>\<^sub>r ?owner_document \<Longrightarrow> ?h \<turnstile> get_disconnected_nodes ?owner_document \<rightarrow>\<^sub>r ?disc_nodes \<Longrightarrow> ShadowRootClass.known_ptrs ?h \<Longrightarrow> ShadowRootClass.type_wf ?h \<Longrightarrow> ?node_ptr \<in> set ?disc_nodes
|
\<lbrakk> ?H1 x_1; ?H2 x_1 (?H3 x_2) ?H4; ?H5 x_1 (?H6 (?H7 x_2)) x_3; ?H8 x_1 (?H9 x_3) x_4; ?H10 x_1; ?H11 x_1\<rbrakk> \<Longrightarrow> x_2 \<in> ?H12 x_4
|
[
"List.list.set",
"ShadowRootClass.type_wf",
"ShadowRootClass.known_ptrs",
"Core_DOM_Functions.get_disconnected_nodes",
"NodePointer.cast\\<^sub>n\\<^sub>o\\<^sub>d\\<^sub>e\\<^sub>_\\<^sub>p\\<^sub>t\\<^sub>r\\<^sub>2\\<^sub>o\\<^sub>b\\<^sub>j\\<^sub>e\\<^sub>c\\<^sub>t\\<^sub>_\\<^sub>p\\<^sub>t\\<^sub>r",
"Shadow_DOM.get_owner_document",
"Option.option.None",
"Shadow_DOM.get_parent",
"Heap_Error_Monad.returns_result",
"Shadow_DOM.heap_is_wellformed"
] |
[
"'a list \\<Rightarrow> 'a set",
"(_) heap \\<Rightarrow> bool",
"(_) heap \\<Rightarrow> bool",
"(_) document_ptr \\<Rightarrow> ((_) heap, exception, (_) node_ptr list) prog",
"(_) node_ptr \\<Rightarrow> (_) object_ptr",
"(_) object_ptr \\<Rightarrow> ((_) heap, exception, (_) document_ptr) prog",
"'a option",
"(_) node_ptr \\<Rightarrow> ((_) heap, exception, (_) object_ptr option) prog",
"'a \\<Rightarrow> ('a, 'b, 'c) prog \\<Rightarrow> 'c \\<Rightarrow> bool",
"(_) heap \\<Rightarrow> bool"
] |
[
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype 'a option =\n None\n | Some (the: 'a)"
] |
lemma_object
|
###symbols
List.list.set :::: 'a list \<Rightarrow> 'a set
ShadowRootClass.type_wf :::: (_) heap \<Rightarrow> bool
ShadowRootClass.known_ptrs :::: (_) heap \<Rightarrow> bool
Core_DOM_Functions.get_disconnected_nodes :::: (_) document_ptr \<Rightarrow> ((_) heap, exception, (_) node_ptr list) prog
NodePointer.cast\<^sub>n\<^sub>o\<^sub>d\<^sub>e\<^sub>_\<^sub>p\<^sub>t\<^sub>r\<^sub>2\<^sub>o\<^sub>b\<^sub>j\<^sub>e\<^sub>c\<^sub>t\<^sub>_\<^sub>p\<^sub>t\<^sub>r :::: (_) node_ptr \<Rightarrow> (_) object_ptr
Shadow_DOM.get_owner_document :::: (_) object_ptr \<Rightarrow> ((_) heap, exception, (_) document_ptr) prog
Option.option.None :::: 'a option
Shadow_DOM.get_parent :::: (_) node_ptr \<Rightarrow> ((_) heap, exception, (_) object_ptr option) prog
Heap_Error_Monad.returns_result :::: 'a \<Rightarrow> ('a, 'b, 'c) prog \<Rightarrow> 'c \<Rightarrow> bool
Shadow_DOM.heap_is_wellformed :::: (_) heap \<Rightarrow> bool
###defs
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype 'a option =
None
| Some (the: 'a)
|
###output
Shadow_DOM.heap_is_wellformed ?h \<Longrightarrow> ?h \<turnstile> Shadow_DOM.get_parent ?node_ptr \<rightarrow>\<^sub>r None \<Longrightarrow> ?h \<turnstile> Shadow_DOM.get_owner_document (cast\<^sub>n\<^sub>o\<^sub>d\<^sub>e\<^sub>_\<^sub>p\<^sub>t\<^sub>r\<^sub>2\<^sub>o\<^sub>b\<^sub>j\<^sub>e\<^sub>c\<^sub>t\<^sub>_\<^sub>p\<^sub>t\<^sub>r ?node_ptr) \<rightarrow>\<^sub>r ?owner_document \<Longrightarrow> ?h \<turnstile> get_disconnected_nodes ?owner_document \<rightarrow>\<^sub>r ?disc_nodes \<Longrightarrow> ShadowRootClass.known_ptrs ?h \<Longrightarrow> ShadowRootClass.type_wf ?h \<Longrightarrow> ?node_ptr \<in> set ?disc_nodes###end
|
FSM_Tests/EquivalenceTesting/Convergence
|
Convergence.preserves_divergence_subset
|
lemma preserves_divergence_subset :
assumes "preserves_divergence M1 M2 B"
and "A \<subseteq> B"
shows "preserves_divergence M1 M2 A"
|
preserves_divergence ?M1.0 ?M2.0 ?B \<Longrightarrow> ?A \<subseteq> ?B \<Longrightarrow> preserves_divergence ?M1.0 ?M2.0 ?A
|
\<lbrakk> ?H1 x_1 x_2 x_3; ?H2 x_4 x_3\<rbrakk> \<Longrightarrow> ?H1 x_1 x_2 x_4
|
[
"Set.subset_eq",
"Convergence.preserves_divergence"
] |
[
"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool",
"('a, 'b, 'c) fsm \\<Rightarrow> ('d, 'b, 'c) fsm \\<Rightarrow> ('b \\<times> 'c) list set \\<Rightarrow> bool"
] |
[
"abbreviation subset_eq :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool\"\n where \"subset_eq \\<equiv> less_eq\""
] |
lemma_object
|
###symbols
Set.subset_eq :::: 'a set \<Rightarrow> 'a set \<Rightarrow> bool
Convergence.preserves_divergence :::: ('a, 'b, 'c) fsm \<Rightarrow> ('d, 'b, 'c) fsm \<Rightarrow> ('b \<times> 'c) list set \<Rightarrow> bool
###defs
abbreviation subset_eq :: "'a set \<Rightarrow> 'a set \<Rightarrow> bool"
where "subset_eq \<equiv> less_eq"
|
###output
preserves_divergence ?M1.0 ?M2.0 ?B \<Longrightarrow> ?A \<subseteq> ?B \<Longrightarrow> preserves_divergence ?M1.0 ?M2.0 ?A###end
|
HOLCF-Prelude/Data_Integer
|
Data_Integer.eq_refl_Integer
|
lemma eq_refl_Integer [simp]:
"(x::Integer) \<noteq> \<bottom> \<Longrightarrow> eq\<cdot>x\<cdot>x = TT"
|
?x \<noteq> \<bottom> \<Longrightarrow> eq\<cdot> ?x\<cdot> ?x = TT
|
x_1 \<noteq> ?H1 \<Longrightarrow> ?H2 (?H3 ?H4 x_1) x_1 = ?H5
|
[
"Tr.TT",
"Type_Classes.Eq_class.eq",
"Cfun.cfun.Rep_cfun",
"Pcpo.pcpo_class.bottom"
] |
[
"tr",
"'a \\<rightarrow> 'a \\<rightarrow> tr",
"('a \\<rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> 'b",
"'a"
] |
[
"definition TT :: \"tr\"\n where \"TT = Def True\"",
"class Eq =\n fixes eq :: \"'a \\<rightarrow> 'a \\<rightarrow> tr\"",
"class pcpo = cpo +\n assumes least: \"\\<exists>x. \\<forall>y. x \\<sqsubseteq> y\"\nbegin"
] |
lemma_object
|
###symbols
Tr.TT :::: tr
Type_Classes.Eq_class.eq :::: 'a \<rightarrow> 'a \<rightarrow> tr
Cfun.cfun.Rep_cfun :::: ('a \<rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> 'b
Pcpo.pcpo_class.bottom :::: 'a
###defs
definition TT :: "tr"
where "TT = Def True"
class Eq =
fixes eq :: "'a \<rightarrow> 'a \<rightarrow> tr"
class pcpo = cpo +
assumes least: "\<exists>x. \<forall>y. x \<sqsubseteq> y"
begin
|
###output
?x \<noteq> \<bottom> \<Longrightarrow> eq\<cdot> ?x\<cdot> ?x = TT###end
|
UTP/utp/utp
|
utp_alphabet.aext_minus
| null |
(?x - ?y) \<oplus>\<^sub>p ?a = ?x \<oplus>\<^sub>p ?a - ?y \<oplus>\<^sub>p ?a
|
?H1 (?H2 x_1 x_2) x_3 = ?H3 (?H1 x_1 x_3) (?H1 x_2 x_3)
|
[
"Groups.minus_class.minus",
"utp_alphabet.aext"
] |
[
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"('a, 'b) uexpr \\<Rightarrow> ('b \\<Longrightarrow> 'c) \\<Rightarrow> ('a, 'c) uexpr"
] |
[
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)"
] |
lemma_object
|
###symbols
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
utp_alphabet.aext :::: ('a, 'b) uexpr \<Rightarrow> ('b \<Longrightarrow> 'c) \<Rightarrow> ('a, 'c) uexpr
###defs
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
|
###output
(?x - ?y) \<oplus>\<^sub>p ?a = ?x \<oplus>\<^sub>p ?a - ?y \<oplus>\<^sub>p ?a###end
|
Poincare_Disc/Hyperbolic_Functions
|
Hyperbolic_Functions.arcosh_mono
|
lemma arcosh_mono:
fixes x y::real
assumes "x \<ge> 1" "y \<ge> 1"
shows "arcosh x \<ge> arcosh y \<longleftrightarrow> x \<ge> y"
|
1 \<le> ?x \<Longrightarrow> 1 \<le> ?y \<Longrightarrow> (arcosh ?y \<le> arcosh ?x) = (?y \<le> ?x)
|
\<lbrakk> ?H1 \<le> x_1; ?H1 \<le> x_2\<rbrakk> \<Longrightarrow> (?H2 x_2 \<le> ?H2 x_1) = (x_2 \<le> x_1)
|
[
"Transcendental.arcosh",
"Groups.one_class.one"
] |
[
"'a \\<Rightarrow> 'a",
"'a"
] |
[
"definition arcosh :: \"'a :: {banach, real_normed_algebra_1, ln} \\<Rightarrow> 'a\" where\n \"arcosh x = ln (x + (x^2 - 1) powr of_real (1/2))\"",
"class one =\n fixes one :: 'a (\"1\")"
] |
lemma_object
|
###symbols
Transcendental.arcosh :::: 'a \<Rightarrow> 'a
Groups.one_class.one :::: 'a
###defs
definition arcosh :: "'a :: {banach, real_normed_algebra_1, ln} \<Rightarrow> 'a" where
"arcosh x = ln (x + (x^2 - 1) powr of_real (1/2))"
class one =
fixes one :: 'a ("1")
|
###output
1 \<le> ?x \<Longrightarrow> 1 \<le> ?y \<Longrightarrow> (arcosh ?y \<le> arcosh ?x) = (?y \<le> ?x)###end
|
POPLmark-deBruijn/POPLmarkRecord
|
POPLmarkRecord.lift_lift(1)
|
lemma lift_lift [simp]:
"k \<le> k' \<Longrightarrow> k' \<le> k + n \<Longrightarrow> \<up> n' k' (\<up> n k t) = \<up> (n + n') k t"
"k \<le> k' \<Longrightarrow> k' \<le> k + n \<Longrightarrow> \<up>\<^sub>r n' k' (\<up>\<^sub>r n k fs) = \<up>\<^sub>r (n + n') k fs"
"k \<le> k' \<Longrightarrow> k' \<le> k + n \<Longrightarrow> \<up>\<^sub>f n' k' (\<up>\<^sub>f n k f) = \<up>\<^sub>f (n + n') k f"
|
?k \<le> ?k' \<Longrightarrow> ?k' \<le> ?k + ?n \<Longrightarrow> \<up> ?n' ?k' (\<up> ?n ?k ?t) = \<up> (?n + ?n') ?k ?t
|
\<lbrakk>x_1 \<le> x_2; x_2 \<le> ?H1 x_1 x_3\<rbrakk> \<Longrightarrow> ?H2 x_4 x_2 (?H2 x_3 x_1 x_5) = ?H2 (?H1 x_3 x_4) x_1 x_5
|
[
"POPLmarkRecord.lift",
"Groups.plus_class.plus"
] |
[
"nat \\<Rightarrow> nat \\<Rightarrow> trm \\<Rightarrow> trm",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a"
] |
[
"primrec lift :: \"nat \\<Rightarrow> nat \\<Rightarrow> trm \\<Rightarrow> trm\" (\"\\<up>\")\n and liftr :: \"nat \\<Rightarrow> nat \\<Rightarrow> rcd \\<Rightarrow> rcd\" (\"\\<up>\\<^sub>r\")\n and liftf :: \"nat \\<Rightarrow> nat \\<Rightarrow> fld \\<Rightarrow> fld\" (\"\\<up>\\<^sub>f\")\nwhere\n \"\\<up> n k (Var i) = (if i < k then Var i else Var (i + n))\"\n| \"\\<up> n k (\\<lambda>:T. t) = (\\<lambda>:\\<up>\\<^sub>\\<tau> n k T. \\<up> n (k + 1) t)\"\n| \"\\<up> n k (\\<lambda><:T. t) = (\\<lambda><:\\<up>\\<^sub>\\<tau> n k T. \\<up> n (k + 1) t)\"\n| \"\\<up> n k (s \\<bullet> t) = \\<up> n k s \\<bullet> \\<up> n k t\"\n| \"\\<up> n k (t \\<bullet>\\<^sub>\\<tau> T) = \\<up> n k t \\<bullet>\\<^sub>\\<tau> \\<up>\\<^sub>\\<tau> n k T\"\n| \"\\<up> n k (Rcd fs) = Rcd (\\<up>\\<^sub>r n k fs)\"\n| \"\\<up> n k (t..a) = (\\<up> n k t)..a\"\n| \"\\<up> n k (LET p = t IN u) = (LET \\<up>\\<^sub>p n k p = \\<up> n k t IN \\<up> n (k + \\<parallel>p\\<parallel>\\<^sub>p) u)\"\n| \"\\<up>\\<^sub>r n k [] = []\"\n| \"\\<up>\\<^sub>r n k (f \\<Colon> fs) = \\<up>\\<^sub>f n k f \\<Colon> \\<up>\\<^sub>r n k fs\"\n| \"\\<up>\\<^sub>f n k (l, t) = (l, \\<up> n k t)\"",
"class plus =\n fixes plus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"+\" 65)"
] |
lemma_object
|
###symbols
POPLmarkRecord.lift :::: nat \<Rightarrow> nat \<Rightarrow> trm \<Rightarrow> trm
Groups.plus_class.plus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
###defs
primrec lift :: "nat \<Rightarrow> nat \<Rightarrow> trm \<Rightarrow> trm" ("\<up>")
and liftr :: "nat \<Rightarrow> nat \<Rightarrow> rcd \<Rightarrow> rcd" ("\<up>\<^sub>r")
and liftf :: "nat \<Rightarrow> nat \<Rightarrow> fld \<Rightarrow> fld" ("\<up>\<^sub>f")
where
"\<up> n k (Var i) = (if i < k then Var i else Var (i + n))"
| "\<up> n k (\<lambda>:T. t) = (\<lambda>:\<up>\<^sub>\<tau> n k T. \<up> n (k + 1) t)"
| "\<up> n k (\<lambda><:T. t) = (\<lambda><:\<up>\<^sub>\<tau> n k T. \<up> n (k + 1) t)"
| "\<up> n k (s \<bullet> t) = \<up> n k s \<bullet> \<up> n k t"
| "\<up> n k (t \<bullet>\<^sub>\<tau> T) = \<up> n k t \<bullet>\<^sub>\<tau> \<up>\<^sub>\<tau> n k T"
| "\<up> n k (Rcd fs) = Rcd (\<up>\<^sub>r n k fs)"
| "\<up> n k (t..a) = (\<up> n k t)..a"
| "\<up> n k (LET p = t IN u) = (LET \<up>\<^sub>p n k p = \<up> n k t IN \<up> n (k + \<parallel>p\<parallel>\<^sub>p) u)"
| "\<up>\<^sub>r n k [] = []"
| "\<up>\<^sub>r n k (f \<Colon> fs) = \<up>\<^sub>f n k f \<Colon> \<up>\<^sub>r n k fs"
| "\<up>\<^sub>f n k (l, t) = (l, \<up> n k t)"
class plus =
fixes plus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "+" 65)
|
###output
?k \<le> ?k' \<Longrightarrow> ?k' \<le> ?k + ?n \<Longrightarrow> \<up> ?n' ?k' (\<up> ?n ?k ?t) = \<up> (?n + ?n') ?k ?t###end
|
JinjaThreads/Framework/FWLock
|
FWLock.may_lock_may_lock_t_eq
|
lemma may_lock_may_lock_t_eq:
"\<lbrakk> may_lock l t; may_lock l t' \<rbrakk> \<Longrightarrow> (l = None) \<or> (t = t')"
|
may_lock ?l ?t \<Longrightarrow> may_lock ?l ?t' \<Longrightarrow> ?l = None \<or> ?t = ?t'
|
\<lbrakk> ?H1 x_1 x_2; ?H1 x_1 x_3\<rbrakk> \<Longrightarrow> x_1 = ?H2 \<or> x_2 = x_3
|
[
"Option.option.None",
"FWLock.may_lock"
] |
[
"'a option",
"('a \\<times> nat) option \\<Rightarrow> 'a \\<Rightarrow> bool"
] |
[
"datatype 'a option =\n None\n | Some (the: 'a)"
] |
lemma_object
|
###symbols
Option.option.None :::: 'a option
FWLock.may_lock :::: ('a \<times> nat) option \<Rightarrow> 'a \<Rightarrow> bool
###defs
datatype 'a option =
None
| Some (the: 'a)
|
###output
may_lock ?l ?t \<Longrightarrow> may_lock ?l ?t' \<Longrightarrow> ?l = None \<or> ?t = ?t'###end
|
Stable_Matching/Basis
|
Basis.linord_of_listP_rev
|
lemma linord_of_listP_rev:
assumes "z # zs \<in> set (subseqs xs)"
assumes "y \<in> set zs"
shows "linord_of_listP z y (rev xs)"
|
?z # ?zs \<in> set (subseqs ?xs) \<Longrightarrow> ?y \<in> set ?zs \<Longrightarrow> linord_of_listP ?z ?y (rev ?xs)
|
\<lbrakk> ?H1 x_1 x_2 \<in> ?H2 (?H3 x_3); x_4 \<in> ?H4 x_2\<rbrakk> \<Longrightarrow> ?H5 x_1 x_4 (?H6 x_3)
|
[
"List.rev",
"Basis.linord_of_listP",
"List.subseqs",
"List.list.set",
"List.list.Cons"
] |
[
"'a list \\<Rightarrow> 'a list",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a list \\<Rightarrow> bool",
"'a list \\<Rightarrow> 'a list list",
"'a list \\<Rightarrow> 'a set",
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a list"
] |
[
"primrec rev :: \"'a list \\<Rightarrow> 'a list\" where\n\"rev [] = []\" |\n\"rev (x # xs) = rev xs @ [x]\"",
"primrec linord_of_listP :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a list \\<Rightarrow> bool\" where\n \"linord_of_listP x y [] \\<longleftrightarrow> False\"\n| \"linord_of_listP x y (z # zs) \\<longleftrightarrow> (z = y \\<and> x \\<in> set (z # zs)) \\<or> linord_of_listP x y zs\"",
"primrec subseqs :: \"'a list \\<Rightarrow> 'a list list\" where\n\"subseqs [] = [[]]\" |\n\"subseqs (x#xs) = (let xss = subseqs xs in map (Cons x) xss @ xss)\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\""
] |
lemma_object
|
###symbols
List.rev :::: 'a list \<Rightarrow> 'a list
Basis.linord_of_listP :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a list \<Rightarrow> bool
List.subseqs :::: 'a list \<Rightarrow> 'a list list
List.list.set :::: 'a list \<Rightarrow> 'a set
List.list.Cons :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a list
###defs
primrec rev :: "'a list \<Rightarrow> 'a list" where
"rev [] = []" |
"rev (x # xs) = rev xs @ [x]"
primrec linord_of_listP :: "'a \<Rightarrow> 'a \<Rightarrow> 'a list \<Rightarrow> bool" where
"linord_of_listP x y [] \<longleftrightarrow> False"
| "linord_of_listP x y (z # zs) \<longleftrightarrow> (z = y \<and> x \<in> set (z # zs)) \<or> linord_of_listP x y zs"
primrec subseqs :: "'a list \<Rightarrow> 'a list list" where
"subseqs [] = [[]]" |
"subseqs (x#xs) = (let xss = subseqs xs in map (Cons x) xss @ xss)"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
|
###output
?z # ?zs \<in> set (subseqs ?xs) \<Longrightarrow> ?y \<in> set ?zs \<Longrightarrow> linord_of_listP ?z ?y (rev ?xs)###end
|
JiveDataStoreModel/Isabelle_Store/StoreProperties
|
StoreProperties.alive_reach_alive
|
lemma alive_reach_alive:
assumes alive_x: "alive x s"
assumes reach_l: "s \<turnstile> l reachable_from x"
shows "alive (ref l) s"
|
alive ?x ?s \<Longrightarrow> ?s\<turnstile> ?l reachable_from ?x \<Longrightarrow> alive (ref ?l) ?s
|
\<lbrakk> ?H1 x_1 x_2; ?H2 x_2 x_3 x_1\<rbrakk> \<Longrightarrow> ?H1 (?H3 x_3) x_2
|
[
"Location.ref",
"StoreProperties.reach",
"Store.alive"
] |
[
"Location \\<Rightarrow> Value",
"Store \\<Rightarrow> Location \\<Rightarrow> Value \\<Rightarrow> bool",
"Value \\<Rightarrow> Store \\<Rightarrow> bool"
] |
[] |
lemma_object
|
###symbols
Location.ref :::: Location \<Rightarrow> Value
StoreProperties.reach :::: Store \<Rightarrow> Location \<Rightarrow> Value \<Rightarrow> bool
Store.alive :::: Value \<Rightarrow> Store \<Rightarrow> bool
###defs
|
###output
alive ?x ?s \<Longrightarrow> ?s\<turnstile> ?l reachable_from ?x \<Longrightarrow> alive (ref ?l) ?s###end
|
FSM_Tests/Util
|
Util.prefixes_butlast_is_prefix
|
lemma prefixes_butlast_is_prefix :
"butlast xs \<in> set (prefixes xs)"
|
butlast ?xs \<in> set (prefixes ?xs)
|
?H1 x_1 \<in> ?H2 (?H3 x_1)
|
[
"Sublist.prefixes",
"List.list.set",
"List.butlast"
] |
[
"'a list \\<Rightarrow> 'a list list",
"'a list \\<Rightarrow> 'a set",
"'a list \\<Rightarrow> 'a list"
] |
[
"primrec prefixes where\n\"prefixes [] = [[]]\" |\n\"prefixes (x#xs) = [] # map ((#) x) (prefixes xs)\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec butlast :: \"'a list \\<Rightarrow> 'a list\" where\n\"butlast [] = []\" |\n\"butlast (x # xs) = (if xs = [] then [] else x # butlast xs)\""
] |
lemma_object
|
###symbols
Sublist.prefixes :::: 'a list \<Rightarrow> 'a list list
List.list.set :::: 'a list \<Rightarrow> 'a set
List.butlast :::: 'a list \<Rightarrow> 'a list
###defs
primrec prefixes where
"prefixes [] = [[]]" |
"prefixes (x#xs) = [] # map ((#) x) (prefixes xs)"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec butlast :: "'a list \<Rightarrow> 'a list" where
"butlast [] = []" |
"butlast (x # xs) = (if xs = [] then [] else x # butlast xs)"
|
###output
butlast ?xs \<in> set (prefixes ?xs)###end
|
Monomorphic_Monad/Monomorphic_Monad
|
Monomorphic_Monad.run_state_parametric
|
lemma run_state_parametric [transfer_rule]: "(rel_stateT S M ===> S ===> M) run_state run_state"
|
rel_fun (rel_stateT ?S ?M) (rel_fun ?S ?M) run_state run_state
|
?H1 (?H2 x_1 x_2) (?H3 x_1 x_2) ?H4 ?H5
|
[
"Monomorphic_Monad.stateT.run_state",
"Monomorphic_Monad.rel_stateT",
"BNF_Def.rel_fun"
] |
[
"('a, 'b) stateT \\<Rightarrow> 'a \\<Rightarrow> 'b",
"('a \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> ('c \\<Rightarrow> 'd \\<Rightarrow> bool) \\<Rightarrow> ('a, 'c) stateT \\<Rightarrow> ('b, 'd) stateT \\<Rightarrow> bool",
"('a \\<Rightarrow> 'b \\<Rightarrow> bool) \\<Rightarrow> ('c \\<Rightarrow> 'd \\<Rightarrow> bool) \\<Rightarrow> ('a \\<Rightarrow> 'c) \\<Rightarrow> ('b \\<Rightarrow> 'd) \\<Rightarrow> bool"
] |
[
"datatype ('s, 'm) stateT = StateT (run_state: \"'s \\<Rightarrow> 'm\")\n for rel: rel_stateT'",
"definition rel_stateT :: \"('s \\<Rightarrow> 's' \\<Rightarrow> bool) \\<Rightarrow> ('m \\<Rightarrow> 'm' \\<Rightarrow> bool) \\<Rightarrow> ('s, 'm) stateT \\<Rightarrow> ('s', 'm') stateT \\<Rightarrow> bool\"\nwhere \"rel_stateT S M m m' \\<longleftrightarrow> (S ===> M) (run_state m) (run_state m')\"",
"definition\n rel_fun :: \"('a \\<Rightarrow> 'c \\<Rightarrow> bool) \\<Rightarrow> ('b \\<Rightarrow> 'd \\<Rightarrow> bool) \\<Rightarrow> ('a \\<Rightarrow> 'b) \\<Rightarrow> ('c \\<Rightarrow> 'd) \\<Rightarrow> bool\"\nwhere\n \"rel_fun A B = (\\<lambda>f g. \\<forall>x y. A x y \\<longrightarrow> B (f x) (g y))\""
] |
lemma_object
|
###symbols
Monomorphic_Monad.stateT.run_state :::: ('a, 'b) stateT \<Rightarrow> 'a \<Rightarrow> 'b
Monomorphic_Monad.rel_stateT :::: ('a \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> ('c \<Rightarrow> 'd \<Rightarrow> bool) \<Rightarrow> ('a, 'c) stateT \<Rightarrow> ('b, 'd) stateT \<Rightarrow> bool
BNF_Def.rel_fun :::: ('a \<Rightarrow> 'b \<Rightarrow> bool) \<Rightarrow> ('c \<Rightarrow> 'd \<Rightarrow> bool) \<Rightarrow> ('a \<Rightarrow> 'c) \<Rightarrow> ('b \<Rightarrow> 'd) \<Rightarrow> bool
###defs
datatype ('s, 'm) stateT = StateT (run_state: "'s \<Rightarrow> 'm")
for rel: rel_stateT'
definition rel_stateT :: "('s \<Rightarrow> 's' \<Rightarrow> bool) \<Rightarrow> ('m \<Rightarrow> 'm' \<Rightarrow> bool) \<Rightarrow> ('s, 'm) stateT \<Rightarrow> ('s', 'm') stateT \<Rightarrow> bool"
where "rel_stateT S M m m' \<longleftrightarrow> (S ===> M) (run_state m) (run_state m')"
definition
rel_fun :: "('a \<Rightarrow> 'c \<Rightarrow> bool) \<Rightarrow> ('b \<Rightarrow> 'd \<Rightarrow> bool) \<Rightarrow> ('a \<Rightarrow> 'b) \<Rightarrow> ('c \<Rightarrow> 'd) \<Rightarrow> bool"
where
"rel_fun A B = (\<lambda>f g. \<forall>x y. A x y \<longrightarrow> B (f x) (g y))"
|
###output
rel_fun (rel_stateT ?S ?M) (rel_fun ?S ?M) run_state run_state###end
|
Frequency_Moments/Landau_Ext
|
Landau_Ext.inv_at_right_0_inf
|
lemma inv_at_right_0_inf:
"\<forall>\<^sub>F x in at_right 0. c \<le> 1 / real_of_rat x"
|
\<forall>\<^sub>F x in at_right 0. ?c \<le> 1 / real_of_rat x
|
?H1 (\<lambda>y_0. x_1 \<le> ?H2 ?H3 (?H4 y_0)) (?H5 ?H6)
|
[
"Groups.zero_class.zero",
"Topological_Spaces.order_topology_class.at_right",
"Real.real_of_rat",
"Groups.one_class.one",
"Fields.inverse_class.inverse_divide",
"Filter.eventually"
] |
[
"'a",
"'a \\<Rightarrow> 'a filter",
"rat \\<Rightarrow> real",
"'a",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a filter \\<Rightarrow> bool"
] |
[
"class zero =\n fixes zero :: 'a (\"0\")",
"class order_topology = order + \"open\" +\n assumes open_generated_order: \"open = generate_topology (range (\\<lambda>a. {..< a}) \\<union> range (\\<lambda>a. {a <..}))\"\nbegin",
"abbreviation real_of_rat :: \"rat \\<Rightarrow> real\"\n where \"real_of_rat \\<equiv> of_rat\"",
"class one =\n fixes one :: 'a (\"1\")",
"class inverse = divide +\n fixes inverse :: \"'a \\<Rightarrow> 'a\"\nbegin",
"definition eventually :: \"('a \\<Rightarrow> bool) \\<Rightarrow> 'a filter \\<Rightarrow> bool\"\n where \"eventually P F \\<longleftrightarrow> Rep_filter F P\""
] |
lemma_object
|
###symbols
Groups.zero_class.zero :::: 'a
Topological_Spaces.order_topology_class.at_right :::: 'a \<Rightarrow> 'a filter
Real.real_of_rat :::: rat \<Rightarrow> real
Groups.one_class.one :::: 'a
Fields.inverse_class.inverse_divide :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
Filter.eventually :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a filter \<Rightarrow> bool
###defs
class zero =
fixes zero :: 'a ("0")
class order_topology = order + "open" +
assumes open_generated_order: "open = generate_topology (range (\<lambda>a. {..< a}) \<union> range (\<lambda>a. {a <..}))"
begin
abbreviation real_of_rat :: "rat \<Rightarrow> real"
where "real_of_rat \<equiv> of_rat"
class one =
fixes one :: 'a ("1")
class inverse = divide +
fixes inverse :: "'a \<Rightarrow> 'a"
begin
definition eventually :: "('a \<Rightarrow> bool) \<Rightarrow> 'a filter \<Rightarrow> bool"
where "eventually P F \<longleftrightarrow> Rep_filter F P"
|
###output
\<forall>\<^sub>F x in at_right 0. ?c \<le> 1 / real_of_rat x###end
|
IMP_With_Speculation/Examples/Fun1
|
Fun1.unwindSDCond_aux_strong
| null |
unwindSDCond ?\<Gamma> \<Longrightarrow> ?\<Gamma> ?sv1.0 ?secl1.0 ?sv2.0 ?secl2.0 \<Longrightarrow> reachV ?sv1.0 \<Longrightarrow> Van.validFromS ?sv1.0 (?trv1.0 ## ?trn1.0) \<Longrightarrow> never isIntV ?trv1.0 \<Longrightarrow> isIntV ?trn1.0 \<Longrightarrow> reachV ?sv2.0 \<Longrightarrow> Van.validFromS ?sv2.0 (?trv2.0 ## ?trn2.0) \<Longrightarrow> never isIntV ?trv2.0 \<Longrightarrow> isIntV ?trn2.0 \<Longrightarrow> Van.S ?trv1.0 @ ?ssecl1.0 = ?secl1.0 \<Longrightarrow> Van.S ?trv2.0 @ ?ssecl2.0 = ?secl2.0 \<Longrightarrow> ?\<Gamma> (lastt ?sv1.0 ?trv1.0) ?ssecl1.0 (lastt ?sv2.0 ?trv2.0) ?ssecl2.0
|
\<lbrakk> ?H1 x_1; x_1 x_2 x_3 x_4 x_5; ?H2 x_2; ?H3 x_2 (?H4 x_6 x_7); ?H5 ?H6 x_6; ?H6 x_7; ?H2 x_4; ?H3 x_4 (?H4 x_8 x_9); ?H5 ?H6 x_8; ?H6 x_9; ?H7 (?H8 x_6) x_10 = x_3; ?H7 (?H8 x_8) x_11 = x_5\<rbrakk> \<Longrightarrow> x_1 (?H9 x_2 x_6) x_10 (?H9 x_4 x_8) x_11
|
[
"Transition_System.lastt",
"Fun1.Van.S",
"List.append",
"Fun1.isIntV",
"List_Filtermap.never",
"List_Filtermap.Rcons",
"Fun1.Van.validFromS",
"Fun1.reachV",
"Fun1.unwindSDCond"
] |
[
"'a \\<Rightarrow> 'a list \\<Rightarrow> 'a",
"(config \\<times> int llist \\<times> int llist \\<times> nat set) list \\<Rightarrow> state list",
"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list",
"config \\<times> int llist \\<times> int llist \\<times> nat set \\<Rightarrow> bool",
"('a \\<Rightarrow> bool) \\<Rightarrow> 'a list \\<Rightarrow> bool",
"'a list \\<Rightarrow> 'a \\<Rightarrow> 'a list",
"config \\<times> int llist \\<times> int llist \\<times> nat set \\<Rightarrow> (config \\<times> int llist \\<times> int llist \\<times> nat set) list \\<Rightarrow> bool",
"config \\<times> int llist \\<times> int llist \\<times> nat set \\<Rightarrow> bool",
"(config \\<times> int llist \\<times> int llist \\<times> nat set \\<Rightarrow> state list \\<Rightarrow> config \\<times> int llist \\<times> int llist \\<times> nat set \\<Rightarrow> state list \\<Rightarrow> bool) \\<Rightarrow> bool"
] |
[
"primrec append :: \"'a list \\<Rightarrow> 'a list \\<Rightarrow> 'a list\" (infixr \"@\" 65) where\nappend_Nil: \"[] @ ys = ys\" |\nappend_Cons: \"(x#xs) @ ys = x # xs @ ys\"",
"abbreviation never :: \"('a \\<Rightarrow> bool) \\<Rightarrow> 'a list \\<Rightarrow> bool\" where \"never U \\<equiv> list_all (\\<lambda> a. \\<not> U a)\"",
"abbreviation Rcons (infix \"##\" 70) where \"xs ## x \\<equiv> xs @ [x]\""
] |
lemma_object
|
###symbols
Transition_System.lastt :::: 'a \<Rightarrow> 'a list \<Rightarrow> 'a
Fun1.Van.S :::: (config \<times> int llist \<times> int llist \<times> nat set) list \<Rightarrow> state list
List.append :::: 'a list \<Rightarrow> 'a list \<Rightarrow> 'a list
Fun1.isIntV :::: config \<times> int llist \<times> int llist \<times> nat set \<Rightarrow> bool
List_Filtermap.never :::: ('a \<Rightarrow> bool) \<Rightarrow> 'a list \<Rightarrow> bool
List_Filtermap.Rcons :::: 'a list \<Rightarrow> 'a \<Rightarrow> 'a list
Fun1.Van.validFromS :::: config \<times> int llist \<times> int llist \<times> nat set \<Rightarrow> (config \<times> int llist \<times> int llist \<times> nat set) list \<Rightarrow> bool
Fun1.reachV :::: config \<times> int llist \<times> int llist \<times> nat set \<Rightarrow> bool
Fun1.unwindSDCond :::: (config \<times> int llist \<times> int llist \<times> nat set \<Rightarrow> state list \<Rightarrow> config \<times> int llist \<times> int llist \<times> nat set \<Rightarrow> state list \<Rightarrow> bool) \<Rightarrow> bool
###defs
primrec append :: "'a list \<Rightarrow> 'a list \<Rightarrow> 'a list" (infixr "@" 65) where
append_Nil: "[] @ ys = ys" |
append_Cons: "(x#xs) @ ys = x # xs @ ys"
abbreviation never :: "('a \<Rightarrow> bool) \<Rightarrow> 'a list \<Rightarrow> bool" where "never U \<equiv> list_all (\<lambda> a. \<not> U a)"
abbreviation Rcons (infix "##" 70) where "xs ## x \<equiv> xs @ [x]"
|
###output
unwindSDCond ?\<Gamma> \<Longrightarrow> ?\<Gamma> ?sv1.0 ?secl1.0 ?sv2.0 ?secl2.0 \<Longrightarrow> reachV ?sv1.0 \<Longrightarrow> Van.validFromS ?sv1.0 (?trv1.0 ## ?trn1.0) \<Longrightarrow> never isIntV ?trv1.0 \<Longrightarrow> isIntV ?trn1.0 \<Longrightarrow> reachV ?sv2.0 \<Longrightarrow> Van.validFromS ?sv2.0 (?trv2.0 ## ?trn2.0) \<Longrightarrow> never isIntV ?trv2.0 \<Longrightarrow> isIntV ?trn2.0 \<Longrightarrow> Van.S ?trv1.0 @ ?ssecl1.0 = ?secl1.0 \<Longrightarrow> Van.S ?trv2.0 @ ?ssecl2.0 = ?secl2.0 \<Longrightarrow> ?\<Gamma> (lastt ?sv1.0 ?trv1.0) ?ssecl1.0 (lastt ?sv2.0 ?trv2.0) ?ssecl2.0###end
|
FocusStreamsCaseStudies/SteamBoiler_proof
|
SteamBoiler_proof.L1_Converter
|
lemma L1_Converter:
assumes "Converter z x"
and "fin_make_untimed (inf_truncate z t) \<noteq> []"
shows "hd (x t) = (fin_make_untimed (inf_truncate z t)) !
((length (fin_make_untimed (inf_truncate z t))) - (1::nat))"
|
Converter ?z ?x \<Longrightarrow> fin_make_untimed (inf_truncate ?z ?t) \<noteq> [] \<Longrightarrow> hd (?x ?t) = fin_make_untimed (inf_truncate ?z ?t) ! (length (fin_make_untimed (inf_truncate ?z ?t)) - 1)
|
\<lbrakk> ?H1 x_1 x_2; ?H2 (?H3 x_1 x_3) \<noteq> ?H4\<rbrakk> \<Longrightarrow> ?H5 (x_2 x_3) = ?H6 (?H2 (?H3 x_1 x_3)) (?H7 (?H8 (?H2 (?H3 x_1 x_3))) ?H9)
|
[
"Groups.one_class.one",
"List.length",
"Groups.minus_class.minus",
"List.nth",
"List.list.hd",
"List.list.Nil",
"stream.inf_truncate",
"stream.fin_make_untimed",
"SteamBoiler.Converter"
] |
[
"'a",
"'a list \\<Rightarrow> nat",
"'a \\<Rightarrow> 'a \\<Rightarrow> 'a",
"'a list \\<Rightarrow> nat \\<Rightarrow> 'a",
"'a list \\<Rightarrow> 'a",
"'a list",
"(nat \\<Rightarrow> 'a) \\<Rightarrow> nat \\<Rightarrow> 'a list",
"'a list list \\<Rightarrow> 'a list",
"(nat \\<Rightarrow> bit list) \\<Rightarrow> (nat \\<Rightarrow> bit list) \\<Rightarrow> bool"
] |
[
"class one =\n fixes one :: 'a (\"1\")",
"abbreviation length :: \"'a list \\<Rightarrow> nat\" where\n\"length \\<equiv> size\"",
"class minus =\n fixes minus :: \"'a \\<Rightarrow> 'a \\<Rightarrow> 'a\" (infixl \"-\" 65)",
"primrec (nonexhaustive) nth :: \"'a list => nat => 'a\" (infixl \"!\" 100) where\nnth_Cons: \"(x # xs) ! n = (case n of 0 \\<Rightarrow> x | Suc k \\<Rightarrow> xs ! k)\"\n \\<comment> \\<open>Warning: simpset does not contain this definition, but separate\n theorems for \\<open>n = 0\\<close> and \\<open>n = Suc k\\<close>\\<close>",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec\n inf_truncate :: \"(nat \\<Rightarrow> 'a) \\<Rightarrow> nat \\<Rightarrow> 'a list\"\nwhere \n \"inf_truncate s 0 = [ s 0 ]\" |\n \"inf_truncate s (Suc k) = (inf_truncate s k) @ [s (Suc k)]\"\n\n\\<comment> \\<open>truncating an infinite stream after the n-th element\\<close>\n\\<comment> \\<open>n is of type of natural numbers enriched by Infinity\\<close>",
"definition\n fin_make_untimed :: \"'a fstream \\<Rightarrow> 'a list\"\nwhere\n \"fin_make_untimed x \\<equiv> concat x\"\n\n\\<comment> \\<open>making an infinite timed stream to an infinite untimed stream\\<close>\n\\<comment> \\<open>(auxiliary function)\\<close>",
"definition\n Converter :: \"bit istream \\<Rightarrow> bit istream \\<Rightarrow> bool\"\nwhere\n \"Converter z x \n \\<equiv> \n (ts x) \n \\<and> \n (\\<forall> (t::nat). \n hd (x t) = \n (if (fin_make_untimed (inf_truncate z t) = [])\n then \n Zero\n else \n (fin_make_untimed (inf_truncate z t)) ! \n ((length (fin_make_untimed (inf_truncate z t))) - (1::nat)) \n ))\""
] |
lemma_object
|
###symbols
Groups.one_class.one :::: 'a
List.length :::: 'a list \<Rightarrow> nat
Groups.minus_class.minus :::: 'a \<Rightarrow> 'a \<Rightarrow> 'a
List.nth :::: 'a list \<Rightarrow> nat \<Rightarrow> 'a
List.list.hd :::: 'a list \<Rightarrow> 'a
List.list.Nil :::: 'a list
stream.inf_truncate :::: (nat \<Rightarrow> 'a) \<Rightarrow> nat \<Rightarrow> 'a list
stream.fin_make_untimed :::: 'a list list \<Rightarrow> 'a list
SteamBoiler.Converter :::: (nat \<Rightarrow> bit list) \<Rightarrow> (nat \<Rightarrow> bit list) \<Rightarrow> bool
###defs
class one =
fixes one :: 'a ("1")
abbreviation length :: "'a list \<Rightarrow> nat" where
"length \<equiv> size"
class minus =
fixes minus :: "'a \<Rightarrow> 'a \<Rightarrow> 'a" (infixl "-" 65)
primrec (nonexhaustive) nth :: "'a list => nat => 'a" (infixl "!" 100) where
nth_Cons: "(x # xs) ! n = (case n of 0 \<Rightarrow> x | Suc k \<Rightarrow> xs ! k)"
\<comment> \<open>Warning: simpset does not contain this definition, but separate
theorems for \<open>n = 0\<close> and \<open>n = Suc k\<close>\<close>
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec
inf_truncate :: "(nat \<Rightarrow> 'a) \<Rightarrow> nat \<Rightarrow> 'a list"
where
"inf_truncate s 0 = [ s 0 ]" |
"inf_truncate s (Suc k) = (inf_truncate s k) @ [s (Suc k)]"
\<comment> \<open>truncating an infinite stream after the n-th element\<close>
\<comment> \<open>n is of type of natural numbers enriched by Infinity\<close>
definition
fin_make_untimed :: "'a fstream \<Rightarrow> 'a list"
where
"fin_make_untimed x \<equiv> concat x"
\<comment> \<open>making an infinite timed stream to an infinite untimed stream\<close>
\<comment> \<open>(auxiliary function)\<close>
definition
Converter :: "bit istream \<Rightarrow> bit istream \<Rightarrow> bool"
where
"Converter z x
\<equiv>
(ts x)
\<and>
(\<forall> (t::nat).
hd (x t) =
(if (fin_make_untimed (inf_truncate z t) = [])
then
Zero
else
(fin_make_untimed (inf_truncate z t)) !
((length (fin_make_untimed (inf_truncate z t))) - (1::nat))
))"
|
###output
Converter ?z ?x \<Longrightarrow> fin_make_untimed (inf_truncate ?z ?t) \<noteq> [] \<Longrightarrow> hd (?x ?t) = fin_make_untimed (inf_truncate ?z ?t) ! (length (fin_make_untimed (inf_truncate ?z ?t)) - 1)###end
|
Jordan_Normal_Form/Gauss_Jordan_Elimination
|
Gauss_Jordan_Elimination.pivot_funI
|
lemma pivot_funI: assumes d: "dim_row A = nr"
and *: "\<And> i. i < nr \<Longrightarrow> f i \<le> nc"
"\<And> i j. i < nr \<Longrightarrow> j < f i \<Longrightarrow> A $$ (i,j) = 0"
"\<And> i. i < nr \<Longrightarrow> Suc i < nr \<Longrightarrow> f (Suc i) > f i \<or> f (Suc i) = nc"
"\<And> i. i < nr \<Longrightarrow> f i < nc \<Longrightarrow> A $$ (i, f i) = 1"
"\<And> i i'. i < nr \<Longrightarrow> f i < nc \<Longrightarrow> i' < nr \<Longrightarrow> i' \<noteq> i \<Longrightarrow> A $$ (i',f i) = 0"
shows "pivot_fun A f nc"
|
dim_row ?A = ?nr \<Longrightarrow> (\<And>i. i < ?nr \<Longrightarrow> ?f i \<le> ?nc) \<Longrightarrow> (\<And>i j. i < ?nr \<Longrightarrow> j < ?f i \<Longrightarrow> ?A $$ (i, j) = (0:: ?'a)) \<Longrightarrow> (\<And>i. i < ?nr \<Longrightarrow> Suc i < ?nr \<Longrightarrow> ?f i < ?f (Suc i) \<or> ?f (Suc i) = ?nc) \<Longrightarrow> (\<And>i. i < ?nr \<Longrightarrow> ?f i < ?nc \<Longrightarrow> ?A $$ (i, ?f i) = (1:: ?'a)) \<Longrightarrow> (\<And>i i'. i < ?nr \<Longrightarrow> ?f i < ?nc \<Longrightarrow> i' < ?nr \<Longrightarrow> i' \<noteq> i \<Longrightarrow> ?A $$ (i', ?f i) = (0:: ?'a)) \<Longrightarrow> pivot_fun ?A ?f ?nc
|
\<lbrakk> ?H1 x_1 = x_2; \<And>y_0. y_0 < x_2 \<Longrightarrow> x_3 y_0 \<le> x_4; \<And>y_1 y_2. \<lbrakk>y_1 < x_2; y_2 < x_3 y_1\<rbrakk> \<Longrightarrow> ?H2 x_1 (y_1, y_2) = ?H3; \<And>y_3. \<lbrakk>y_3 < x_2; ?H4 y_3 < x_2\<rbrakk> \<Longrightarrow> x_3 y_3 < x_3 (?H4 y_3) \<or> x_3 (?H4 y_3) = x_4; \<And>y_4. \<lbrakk>y_4 < x_2; x_3 y_4 < x_4\<rbrakk> \<Longrightarrow> ?H2 x_1 (y_4, x_3 y_4) = ?H5; \<And>y_5 y_6. \<lbrakk>y_5 < x_2; x_3 y_5 < x_4; y_6 < x_2; y_6 \<noteq> y_5\<rbrakk> \<Longrightarrow> ?H2 x_1 (y_6, x_3 y_5) = ?H3\<rbrakk> \<Longrightarrow> ?H6 x_1 x_3 x_4
|
[
"Gauss_Jordan_Elimination.pivot_fun",
"Groups.one_class.one",
"Nat.Suc",
"Groups.zero_class.zero",
"Matrix.index_mat",
"Matrix.dim_row"
] |
[
"'a mat \\<Rightarrow> (nat \\<Rightarrow> nat) \\<Rightarrow> nat \\<Rightarrow> bool",
"'a",
"nat \\<Rightarrow> nat",
"'a",
"'a mat \\<Rightarrow> nat \\<times> nat \\<Rightarrow> 'a",
"'a mat \\<Rightarrow> nat"
] |
[
"definition pivot_fun :: \"'a :: {zero,one} mat \\<Rightarrow> (nat \\<Rightarrow> nat) \\<Rightarrow> nat \\<Rightarrow> bool\" where\n \"pivot_fun A f nc \\<equiv> let nr = dim_row A in \n (\\<forall> i < nr. f i \\<le> nc \\<and> \n (f i < nc \\<longrightarrow> A $$ (i, f i) = 1 \\<and> (\\<forall> i' < nr. i' \\<noteq> i \\<longrightarrow> A $$ (i',f i) = 0)) \\<and> \n (\\<forall> j < f i. A $$ (i, j) = 0) \\<and>\n (Suc i < nr \\<longrightarrow> f (Suc i) > f i \\<or> f (Suc i) = nc))\"",
"class one =\n fixes one :: 'a (\"1\")",
"definition Suc :: \"nat \\<Rightarrow> nat\"\n where \"Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))\"",
"class zero =\n fixes zero :: 'a (\"0\")"
] |
lemma_object
|
###symbols
Gauss_Jordan_Elimination.pivot_fun :::: 'a mat \<Rightarrow> (nat \<Rightarrow> nat) \<Rightarrow> nat \<Rightarrow> bool
Groups.one_class.one :::: 'a
Nat.Suc :::: nat \<Rightarrow> nat
Groups.zero_class.zero :::: 'a
Matrix.index_mat :::: 'a mat \<Rightarrow> nat \<times> nat \<Rightarrow> 'a
Matrix.dim_row :::: 'a mat \<Rightarrow> nat
###defs
definition pivot_fun :: "'a :: {zero,one} mat \<Rightarrow> (nat \<Rightarrow> nat) \<Rightarrow> nat \<Rightarrow> bool" where
"pivot_fun A f nc \<equiv> let nr = dim_row A in
(\<forall> i < nr. f i \<le> nc \<and>
(f i < nc \<longrightarrow> A $$ (i, f i) = 1 \<and> (\<forall> i' < nr. i' \<noteq> i \<longrightarrow> A $$ (i',f i) = 0)) \<and>
(\<forall> j < f i. A $$ (i, j) = 0) \<and>
(Suc i < nr \<longrightarrow> f (Suc i) > f i \<or> f (Suc i) = nc))"
class one =
fixes one :: 'a ("1")
definition Suc :: "nat \<Rightarrow> nat"
where "Suc n = Abs_Nat (Suc_Rep (Rep_Nat n))"
class zero =
fixes zero :: 'a ("0")
|
###output
dim_row ?A = ?nr \<Longrightarrow> (\<And>i. i < ?nr \<Longrightarrow> ?f i \<le> ?nc) \<Longrightarrow> (\<And>i j. i < ?nr \<Longrightarrow> j < ?f i \<Longrightarrow> ?A $$ (i, j) = (0:: ?'a)) \<Longrightarrow> (\<And>i. i < ?nr \<Longrightarrow> Suc i < ?nr \<Longrightarrow> ?f i < ?f (Suc i) \<or> ?f (Suc i) = ?nc) \<Longrightarrow> (\<And>i. i < ?nr \<Longrightarrow> ?f i < ?nc \<Longrightarrow> ?A $$ (i, ?f i) = (1:: ?'a)) \<Longrightarrow> (\<And>i i'. i < ?nr \<Longrightarrow> ?f i < ?nc \<Longrightarrow> i' < ?nr \<Longrightarrow> i' \<noteq> i \<Longrightarrow> ?A $$ (i', ?f i) = (0:: ?'a)) \<Longrightarrow> pivot_fun ?A ?f ?nc###end
|
Interpreter_Optimizations/Global
|
Global.wf_fundefsI
|
lemma wf_fundefsI:
assumes "\<And>f fd. F f = Some fd \<Longrightarrow> wf_fundef fd"
shows "wf_fundefs F"
|
(\<And>f fd. ?F f = Some fd \<Longrightarrow> wf_fundef fd) \<Longrightarrow> wf_fundefs ?F
|
(\<And>y_0 y_1. x_1 y_0 = ?H1 y_1 \<Longrightarrow> ?H2 y_1) \<Longrightarrow> ?H3 x_1
|
[
"Global.wf_fundefs",
"Global.wf_fundef",
"Option.option.Some"
] |
[
"('a \\<Rightarrow> ('b, 'c) fundef option) \\<Rightarrow> bool",
"('a, 'b) fundef \\<Rightarrow> bool",
"'a \\<Rightarrow> 'a option"
] |
[
"definition wf_fundefs where\n \"wf_fundefs F \\<longleftrightarrow> (\\<forall>f fd. F f = Some fd \\<longrightarrow> wf_fundef fd)\"",
"definition wf_fundef where\n \"wf_fundef fd \\<longleftrightarrow> body fd \\<noteq> []\"",
"datatype 'a option =\n None\n | Some (the: 'a)"
] |
lemma_object
|
###symbols
Global.wf_fundefs :::: ('a \<Rightarrow> ('b, 'c) fundef option) \<Rightarrow> bool
Global.wf_fundef :::: ('a, 'b) fundef \<Rightarrow> bool
Option.option.Some :::: 'a \<Rightarrow> 'a option
###defs
definition wf_fundefs where
"wf_fundefs F \<longleftrightarrow> (\<forall>f fd. F f = Some fd \<longrightarrow> wf_fundef fd)"
definition wf_fundef where
"wf_fundef fd \<longleftrightarrow> body fd \<noteq> []"
datatype 'a option =
None
| Some (the: 'a)
|
###output
(\<And>f fd. ?F f = Some fd \<Longrightarrow> wf_fundef fd) \<Longrightarrow> wf_fundefs ?F###end
|
FOL-Fitting/FOL_Fitting
|
FOL_Fitting.subcs_psubst
|
lemma subcs_psubst: \<open>(\<forall>x \<in> (\<Union>p \<in> set z. params p). x \<noteq> c \<longrightarrow> f x \<noteq> f c) \<Longrightarrow>
map (psubst f) (subcs c s z) = subcs (f c) (psubstt f s) (map (psubst f) z)\<close>
|
\<forall>x\<in>\<Union> (params ` set ?z). x \<noteq> ?c \<longrightarrow> ?f x \<noteq> ?f ?c \<Longrightarrow> map (psubst ?f) (subcs ?c ?s ?z) = subcs (?f ?c) (psubstt ?f ?s) (map (psubst ?f) ?z)
|
\<forall>y_1\<in> ?H1 (?H2 ?H3 (?H4 x_1)). y_1 \<noteq> x_2 \<longrightarrow> x_3 y_1 \<noteq> x_3 x_2 \<Longrightarrow> ?H5 (?H6 x_3) (?H7 x_2 x_4 x_1) = ?H8 (x_3 x_2) (?H9 x_3 x_4) (?H5 (?H6 x_3) x_1)
|
[
"FOL_Fitting.psubstt",
"FOL_Fitting.subcs",
"FOL_Fitting.psubst",
"List.list.map",
"List.list.set",
"FOL_Fitting.params",
"Set.image",
"Complete_Lattices.Union"
] |
[
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a FOL_Fitting.term \\<Rightarrow> 'b FOL_Fitting.term",
"'a \\<Rightarrow> 'a FOL_Fitting.term \\<Rightarrow> ('a, 'b) form list \\<Rightarrow> ('a, 'b) form list",
"('a \\<Rightarrow> 'b) \\<Rightarrow> ('a, 'c) form \\<Rightarrow> ('b, 'c) form",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a list \\<Rightarrow> 'b list",
"'a list \\<Rightarrow> 'a set",
"('a, 'b) form \\<Rightarrow> 'a set",
"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a set \\<Rightarrow> 'b set",
"'a set set \\<Rightarrow> 'a set"
] |
[
"primrec\n psubstt :: \\<open>('a \\<Rightarrow> 'c) \\<Rightarrow> 'a term \\<Rightarrow> 'c term\\<close> and\n psubstts :: \\<open>('a \\<Rightarrow> 'c) \\<Rightarrow> 'a term list \\<Rightarrow> 'c term list\\<close> where\n \\<open>psubstt f (Var i) = Var i\\<close>\n| \\<open>psubstt f (App x ts) = App (f x) (psubstts f ts)\\<close>\n| \\<open>psubstts f [] = []\\<close>\n| \\<open>psubstts f (t # ts) = psubstt f t # psubstts f ts\\<close>",
"primrec subcs :: \\<open>'a \\<Rightarrow> 'a term \\<Rightarrow> ('a, 'b) form list \\<Rightarrow> ('a, 'b) form list\\<close> where\n \\<open>subcs c s [] = []\\<close> |\n \\<open>subcs c s (p # z) = subc c s p # subcs c s z\\<close>",
"primrec psubst :: \\<open>('a \\<Rightarrow> 'c) \\<Rightarrow> ('a, 'b) form \\<Rightarrow> ('c, 'b) form\\<close> where\n \\<open>psubst f FF = FF\\<close>\n| \\<open>psubst f TT = TT\\<close>\n| \\<open>psubst f (Pred b ts) = Pred b (psubstts f ts)\\<close>\n| \\<open>psubst f (And p q) = And (psubst f p) (psubst f q)\\<close>\n| \\<open>psubst f (Or p q) = Or (psubst f p) (psubst f q)\\<close>\n| \\<open>psubst f (Impl p q) = Impl (psubst f p) (psubst f q)\\<close>\n| \\<open>psubst f (Neg p) = Neg (psubst f p)\\<close>\n| \\<open>psubst f (Forall p) = Forall (psubst f p)\\<close>\n| \\<open>psubst f (Exists p) = Exists (psubst f p)\\<close>",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"primrec params :: \\<open>('a, 'b) form \\<Rightarrow> 'a set\\<close> where\n \\<open>params FF = {}\\<close>\n| \\<open>params TT = {}\\<close>\n| \\<open>params (Pred b ts) = paramsts ts\\<close>\n| \\<open>params (And p q) = params p \\<union> params q\\<close>\n| \\<open>params (Or p q) = params p \\<union> params q\\<close>\n| \\<open>params (Impl p q) = params p \\<union> params q\\<close>\n| \\<open>params (Neg p) = params p\\<close>\n| \\<open>params (Forall p) = params p\\<close>\n| \\<open>params (Exists p) = params p\\<close>",
"definition image :: \"('a \\<Rightarrow> 'b) \\<Rightarrow> 'a set \\<Rightarrow> 'b set\" (infixr \"`\" 90)\n where \"f ` A = {y. \\<exists>x\\<in>A. y = f x}\"",
"abbreviation Union :: \"'a set set \\<Rightarrow> 'a set\" (\"\\<Union>\")\n where \"\\<Union>S \\<equiv> \\<Squnion>S\""
] |
lemma_object
|
###symbols
FOL_Fitting.psubstt :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a FOL_Fitting.term \<Rightarrow> 'b FOL_Fitting.term
FOL_Fitting.subcs :::: 'a \<Rightarrow> 'a FOL_Fitting.term \<Rightarrow> ('a, 'b) form list \<Rightarrow> ('a, 'b) form list
FOL_Fitting.psubst :::: ('a \<Rightarrow> 'b) \<Rightarrow> ('a, 'c) form \<Rightarrow> ('b, 'c) form
List.list.map :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a list \<Rightarrow> 'b list
List.list.set :::: 'a list \<Rightarrow> 'a set
FOL_Fitting.params :::: ('a, 'b) form \<Rightarrow> 'a set
Set.image :::: ('a \<Rightarrow> 'b) \<Rightarrow> 'a set \<Rightarrow> 'b set
Complete_Lattices.Union :::: 'a set set \<Rightarrow> 'a set
###defs
primrec
psubstt :: \<open>('a \<Rightarrow> 'c) \<Rightarrow> 'a term \<Rightarrow> 'c term\<close> and
psubstts :: \<open>('a \<Rightarrow> 'c) \<Rightarrow> 'a term list \<Rightarrow> 'c term list\<close> where
\<open>psubstt f (Var i) = Var i\<close>
| \<open>psubstt f (App x ts) = App (f x) (psubstts f ts)\<close>
| \<open>psubstts f [] = []\<close>
| \<open>psubstts f (t # ts) = psubstt f t # psubstts f ts\<close>
primrec subcs :: \<open>'a \<Rightarrow> 'a term \<Rightarrow> ('a, 'b) form list \<Rightarrow> ('a, 'b) form list\<close> where
\<open>subcs c s [] = []\<close> |
\<open>subcs c s (p # z) = subc c s p # subcs c s z\<close>
primrec psubst :: \<open>('a \<Rightarrow> 'c) \<Rightarrow> ('a, 'b) form \<Rightarrow> ('c, 'b) form\<close> where
\<open>psubst f FF = FF\<close>
| \<open>psubst f TT = TT\<close>
| \<open>psubst f (Pred b ts) = Pred b (psubstts f ts)\<close>
| \<open>psubst f (And p q) = And (psubst f p) (psubst f q)\<close>
| \<open>psubst f (Or p q) = Or (psubst f p) (psubst f q)\<close>
| \<open>psubst f (Impl p q) = Impl (psubst f p) (psubst f q)\<close>
| \<open>psubst f (Neg p) = Neg (psubst f p)\<close>
| \<open>psubst f (Forall p) = Forall (psubst f p)\<close>
| \<open>psubst f (Exists p) = Exists (psubst f p)\<close>
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
primrec params :: \<open>('a, 'b) form \<Rightarrow> 'a set\<close> where
\<open>params FF = {}\<close>
| \<open>params TT = {}\<close>
| \<open>params (Pred b ts) = paramsts ts\<close>
| \<open>params (And p q) = params p \<union> params q\<close>
| \<open>params (Or p q) = params p \<union> params q\<close>
| \<open>params (Impl p q) = params p \<union> params q\<close>
| \<open>params (Neg p) = params p\<close>
| \<open>params (Forall p) = params p\<close>
| \<open>params (Exists p) = params p\<close>
definition image :: "('a \<Rightarrow> 'b) \<Rightarrow> 'a set \<Rightarrow> 'b set" (infixr "`" 90)
where "f ` A = {y. \<exists>x\<in>A. y = f x}"
abbreviation Union :: "'a set set \<Rightarrow> 'a set" ("\<Union>")
where "\<Union>S \<equiv> \<Squnion>S"
|
###output
\<forall>x\<in>\<Union> (params ` set ?z). x \<noteq> ?c \<longrightarrow> ?f x \<noteq> ?f ?c \<Longrightarrow> map (psubst ?f) (subcs ?c ?s ?z) = subcs (?f ?c) (psubstt ?f ?s) (map (psubst ?f) ?z)###end
|
CAVA_Automata/Automata_Impl
|
Automata_Impl.gen_igbg_refine(3)
|
lemma gen_igbg_refine:
fixes Rv Re Rv0 Racc
assumes "TERM (Rv,Re,Rv0)"
assumes "TERM (Racc)"
shows
"(igbgi_num_acc,igbg_num_acc)
\<in> \<langle>Rv,Re,Rv0\<rangle>gen_igbg_impl_rel_ext Rm Racc \<rightarrow> nat_rel"
"(igbgi_acc,igbg_acc)
\<in> \<langle>Rv,Re,Rv0\<rangle>gen_igbg_impl_rel_ext Rm Racc \<rightarrow> Racc"
"(gen_igbg_impl_ext, igb_graph_rec_ext)
\<in> nat_rel \<rightarrow> Racc \<rightarrow> Rm \<rightarrow> \<langle>Rm,Racc\<rangle>gen_igbg_impl_rel_eext"
|
TERM (?Rv, ?Re, ?Rv0.0) \<Longrightarrow> TERM ?Racc \<Longrightarrow> (gen_igbg_impl_ext, igb_graph_rec_ext) \<in> nat_rel \<rightarrow> ?Racc \<rightarrow> ?Rm \<rightarrow> \<langle> ?Rm, ?Racc\<rangle>gen_igbg_impl_rel_eext
|
\<lbrakk>TERM (x_1, x_2, x_3); TERM x_4\<rbrakk> \<Longrightarrow> (?H1, ?H2) \<in> ?H3 ?H4 (?H5 x_4 (?H6 x_5 (?H7 (?H8 ?H9 x_5) x_4)))
|
[
"Automata_Impl.gen_igbg_impl_rel_eext",
"Relators.relAPP",
"Relators.nat_rel",
"Relators.fun_rel_syn",
"Automata.igb_graph_rec.igb_graph_rec_ext",
"Automata_Impl.gen_igbg_impl.gen_igbg_impl_ext"
] |
[
"('a \\<times> 'b) set \\<Rightarrow> ('c \\<times> ('d \\<Rightarrow> nat set)) set \\<Rightarrow> (\\<lparr>igbgi_num_acc :: nat, igbgi_acc :: 'c, \\<dots> :: 'a\\<rparr> \\<times> \\<lparr>igbg_num_acc :: nat, igbg_acc :: 'd \\<Rightarrow> nat set, \\<dots> :: 'b\\<rparr>) set",
"(('a \\<times> 'b) set \\<Rightarrow> 'c) \\<Rightarrow> ('a \\<times> 'b) set \\<Rightarrow> 'c",
"(nat \\<times> nat) set",
"('a \\<times> 'b) set \\<Rightarrow> ('c \\<times> 'd) set \\<Rightarrow> (('a \\<Rightarrow> 'c) \\<times> ('b \\<Rightarrow> 'd)) set",
"nat \\<Rightarrow> ('a \\<Rightarrow> nat set) \\<Rightarrow> 'b \\<Rightarrow> \\<lparr>igbg_num_acc :: nat, igbg_acc :: 'a \\<Rightarrow> nat set, \\<dots> :: 'b\\<rparr>",
"nat \\<Rightarrow> 'a \\<Rightarrow> 'b \\<Rightarrow> \\<lparr>igbgi_num_acc :: nat, igbgi_acc :: 'a, \\<dots> :: 'b\\<rparr>"
] |
[
"record ('vi,'ei,'v0i,'acci) gen_igbg_impl = \"('vi,'ei,'v0i) gen_g_impl\" +\n igbgi_num_acc :: nat\n igbgi_acc :: 'acci"
] |
lemma_object
|
###symbols
Automata_Impl.gen_igbg_impl_rel_eext :::: ('a \<times> 'b) set \<Rightarrow> ('c \<times> ('d \<Rightarrow> nat set)) set \<Rightarrow> (\<lparr>igbgi_num_acc :: nat, igbgi_acc :: 'c, \<dots> :: 'a\<rparr> \<times> \<lparr>igbg_num_acc :: nat, igbg_acc :: 'd \<Rightarrow> nat set, \<dots> :: 'b\<rparr>) set
Relators.relAPP :::: (('a \<times> 'b) set \<Rightarrow> 'c) \<Rightarrow> ('a \<times> 'b) set \<Rightarrow> 'c
Relators.nat_rel :::: (nat \<times> nat) set
Relators.fun_rel_syn :::: ('a \<times> 'b) set \<Rightarrow> ('c \<times> 'd) set \<Rightarrow> (('a \<Rightarrow> 'c) \<times> ('b \<Rightarrow> 'd)) set
Automata.igb_graph_rec.igb_graph_rec_ext :::: nat \<Rightarrow> ('a \<Rightarrow> nat set) \<Rightarrow> 'b \<Rightarrow> \<lparr>igbg_num_acc :: nat, igbg_acc :: 'a \<Rightarrow> nat set, \<dots> :: 'b\<rparr>
Automata_Impl.gen_igbg_impl.gen_igbg_impl_ext :::: nat \<Rightarrow> 'a \<Rightarrow> 'b \<Rightarrow> \<lparr>igbgi_num_acc :: nat, igbgi_acc :: 'a, \<dots> :: 'b\<rparr>
###defs
record ('vi,'ei,'v0i,'acci) gen_igbg_impl = "('vi,'ei,'v0i) gen_g_impl" +
igbgi_num_acc :: nat
igbgi_acc :: 'acci
|
###output
TERM (?Rv, ?Re, ?Rv0.0) \<Longrightarrow> TERM ?Racc \<Longrightarrow> (gen_igbg_impl_ext, igb_graph_rec_ext) \<in> nat_rel \<rightarrow> ?Racc \<rightarrow> ?Rm \<rightarrow> \<langle> ?Rm, ?Racc\<rangle>gen_igbg_impl_rel_eext###end
|
UPF_Firewall/FWNormalisation/NormalisationGenericProofs
|
NormalisationGenericProofs.aux80
|
lemma aux80: "\<lbrakk>y \<notin> set p; y \<noteq> x\<rbrakk> \<Longrightarrow> y \<notin> set (insort x (sort p l) l)"
|
?y \<notin> set ?p \<Longrightarrow> ?y \<noteq> ?x \<Longrightarrow> ?y \<notin> set (FWNormalisationCore.insort ?x (FWNormalisationCore.sort ?p ?l) ?l)
|
\<lbrakk> ?H1 x_1 (?H2 x_2); x_1 \<noteq> x_3\<rbrakk> \<Longrightarrow> ?H1 x_1 (?H2 (?H3 x_3 (?H4 x_2 x_4) x_4))
|
[
"FWNormalisationCore.sort",
"FWNormalisationCore.insort",
"List.list.set",
"Set.not_member"
] |
[
"('a, 'b) Combinators list \\<Rightarrow> 'a set list \\<Rightarrow> ('a, 'b) Combinators list",
"('a, 'b) Combinators \\<Rightarrow> ('a, 'b) Combinators list \\<Rightarrow> 'a set list \\<Rightarrow> ('a, 'b) Combinators list",
"'a list \\<Rightarrow> 'a set",
"'a \\<Rightarrow> 'a set \\<Rightarrow> bool"
] |
[
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"abbreviation not_member\n where \"not_member x A \\<equiv> \\<not> (x \\<in> A)\" \\<comment> \\<open>non-membership\\<close>"
] |
lemma_object
|
###symbols
FWNormalisationCore.sort :::: ('a, 'b) Combinators list \<Rightarrow> 'a set list \<Rightarrow> ('a, 'b) Combinators list
FWNormalisationCore.insort :::: ('a, 'b) Combinators \<Rightarrow> ('a, 'b) Combinators list \<Rightarrow> 'a set list \<Rightarrow> ('a, 'b) Combinators list
List.list.set :::: 'a list \<Rightarrow> 'a set
Set.not_member :::: 'a \<Rightarrow> 'a set \<Rightarrow> bool
###defs
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
abbreviation not_member
where "not_member x A \<equiv> \<not> (x \<in> A)" \<comment> \<open>non-membership\<close>
|
###output
?y \<notin> set ?p \<Longrightarrow> ?y \<noteq> ?x \<Longrightarrow> ?y \<notin> set (FWNormalisationCore.insort ?x (FWNormalisationCore.sort ?p ?l) ?l)###end
|
CZH_Elementary_Categories/czh_ecategories/CZH_ECAT_Subcategory
|
CZH_ECAT_Subcategory.wide_replete_subcategoryE
| null |
?\<BB> \<subseteq>\<^sub>C\<^sub>.\<^sub>w\<^sub>r\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> (?\<BB> \<subseteq>\<^sub>C\<^sub>.\<^sub>w\<^sub>i\<^sub>d\<^sub>e\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> ?\<BB> \<subseteq>\<^sub>C\<^sub>.\<^sub>r\<^sub>e\<^sub>p\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> ?W) \<Longrightarrow> ?W
|
\<lbrakk> ?H1 x_1 x_2 x_3; \<lbrakk> ?H2 x_1 x_2 x_3; ?H3 x_1 x_2 x_3\<rbrakk> \<Longrightarrow> x_4\<rbrakk> \<Longrightarrow> x_4
|
[
"CZH_ECAT_Subcategory.is_replete_subcategory",
"CZH_ECAT_Subcategory.is_wide_subcategory",
"CZH_ECAT_Subcategory.is_wide_replete_subcategory"
] |
[
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> bool",
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> bool",
"V \\<Rightarrow> V \\<Rightarrow> V \\<Rightarrow> bool"
] |
[] |
lemma_object
|
###symbols
CZH_ECAT_Subcategory.is_replete_subcategory :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> bool
CZH_ECAT_Subcategory.is_wide_subcategory :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> bool
CZH_ECAT_Subcategory.is_wide_replete_subcategory :::: V \<Rightarrow> V \<Rightarrow> V \<Rightarrow> bool
###defs
|
###output
?\<BB> \<subseteq>\<^sub>C\<^sub>.\<^sub>w\<^sub>r\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> (?\<BB> \<subseteq>\<^sub>C\<^sub>.\<^sub>w\<^sub>i\<^sub>d\<^sub>e\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> ?\<BB> \<subseteq>\<^sub>C\<^sub>.\<^sub>r\<^sub>e\<^sub>p\<^bsub> ?\<alpha>\<^esub> ?\<CC> \<Longrightarrow> ?W) \<Longrightarrow> ?W###end
|
Monomorphic_Monad/Monomorphic_Monad
|
Monomorphic_Monad.run_tell_option
|
lemma run_tell_option [simp]: "run_option (tell_option w m) = tell w (run_option m)"
|
run_option (tell_option ?tell ?w ?m) = ?tell ?w (run_option ?m)
|
?H1 (?H2 x_1 x_2 x_3) = x_1 x_2 (?H1 x_3)
|
[
"Monomorphic_Monad.tell_option",
"Monomorphic_Monad.optionT.run_option"
] |
[
"('a \\<Rightarrow> 'b \\<Rightarrow> 'b) \\<Rightarrow> 'a \\<Rightarrow> ('c, 'b) optionT \\<Rightarrow> ('c, 'b) optionT",
"('a, 'b) optionT \\<Rightarrow> 'b"
] |
[
"definition tell_option :: \"('w, ('a, 'm) optionT) tell\" \nwhere \"tell_option w m = OptionT (tell w (run_option m))\"",
"datatype (plugins del: transfer) (phantom_optionT: 'a, set_optionT: 'm) optionT =\n OptionT (run_option: 'm)\n for rel: rel_optionT' \n map: map_optionT'"
] |
lemma_object
|
###symbols
Monomorphic_Monad.tell_option :::: ('a \<Rightarrow> 'b \<Rightarrow> 'b) \<Rightarrow> 'a \<Rightarrow> ('c, 'b) optionT \<Rightarrow> ('c, 'b) optionT
Monomorphic_Monad.optionT.run_option :::: ('a, 'b) optionT \<Rightarrow> 'b
###defs
definition tell_option :: "('w, ('a, 'm) optionT) tell"
where "tell_option w m = OptionT (tell w (run_option m))"
datatype (plugins del: transfer) (phantom_optionT: 'a, set_optionT: 'm) optionT =
OptionT (run_option: 'm)
for rel: rel_optionT'
map: map_optionT'
|
###output
run_option (tell_option ?tell ?w ?m) = ?tell ?w (run_option ?m)###end
|
Collections/Lib/Diff_Array
|
Diff_Array.param_assoc_list_of_array
|
lemma param_assoc_list_of_array[param]:
"(assoc_list_of_array, assoc_list_of_array) \<in>
\<langle>R\<rangle> array_rel \<rightarrow> \<langle>\<langle>nat_rel,R\<rangle>prod_rel\<rangle>list_rel"
|
(assoc_list_of_array, assoc_list_of_array) \<in> \<langle> ?R\<rangle>array_rel \<rightarrow> \<langle>nat_rel \<times>\<^sub>r ?R\<rangle>list_rel
|
(?H1, ?H2) \<in> ?H3 (?H4 ?H5 x_1) (?H6 ?H7 (?H8 ?H9 x_1))
|
[
"Relators.nat_rel",
"Relators.prod_rel_syn",
"Relators.list_rel",
"Diff_Array.array_rel",
"Relators.relAPP",
"Relators.fun_rel_syn",
"Diff_Array.assoc_list_of_array"
] |
[
"(nat \\<times> nat) set",
"('a \\<times> 'b) set \\<Rightarrow> ('c \\<times> 'd) set \\<Rightarrow> (('a \\<times> 'c) \\<times> 'b \\<times> 'd) set",
"('a \\<times> 'b) set \\<Rightarrow> ('a list \\<times> 'b list) set",
"('a \\<times> 'b) set \\<Rightarrow> ('a array \\<times> 'b array) set",
"(('a \\<times> 'b) set \\<Rightarrow> 'c) \\<Rightarrow> ('a \\<times> 'b) set \\<Rightarrow> 'c",
"('a \\<times> 'b) set \\<Rightarrow> ('c \\<times> 'd) set \\<Rightarrow> (('a \\<Rightarrow> 'c) \\<times> ('b \\<Rightarrow> 'd)) set",
"'a array \\<Rightarrow> (nat \\<times> 'a) list"
] |
[] |
lemma_object
|
###symbols
Relators.nat_rel :::: (nat \<times> nat) set
Relators.prod_rel_syn :::: ('a \<times> 'b) set \<Rightarrow> ('c \<times> 'd) set \<Rightarrow> (('a \<times> 'c) \<times> 'b \<times> 'd) set
Relators.list_rel :::: ('a \<times> 'b) set \<Rightarrow> ('a list \<times> 'b list) set
Diff_Array.array_rel :::: ('a \<times> 'b) set \<Rightarrow> ('a array \<times> 'b array) set
Relators.relAPP :::: (('a \<times> 'b) set \<Rightarrow> 'c) \<Rightarrow> ('a \<times> 'b) set \<Rightarrow> 'c
Relators.fun_rel_syn :::: ('a \<times> 'b) set \<Rightarrow> ('c \<times> 'd) set \<Rightarrow> (('a \<Rightarrow> 'c) \<times> ('b \<Rightarrow> 'd)) set
Diff_Array.assoc_list_of_array :::: 'a array \<Rightarrow> (nat \<times> 'a) list
###defs
|
###output
(assoc_list_of_array, assoc_list_of_array) \<in> \<langle> ?R\<rangle>array_rel \<rightarrow> \<langle>nat_rel \<times>\<^sub>r ?R\<rangle>list_rel###end
|
Network_Security_Policy_Verification/TopoS_Stateful_Policy_Algorithm
|
TopoS_Stateful_Policy_Algorithm.generate_valid_stateful_policy_IFSACS_all_security_requirements_fulfilled_IFS
|
lemma generate_valid_stateful_policy_IFSACS_all_security_requirements_fulfilled_IFS: assumes validReqs: "valid_reqs M"
and wfG: "wf_graph G"
and high_level_policy_valid: "all_security_requirements_fulfilled M G"
and edgesList: "(set edgesList) \<subseteq> edges G"
shows "all_security_requirements_fulfilled (get_IFS M) (stateful_policy_to_network_graph (generate_valid_stateful_policy_IFSACS G M edgesList))"
|
valid_reqs ?M \<Longrightarrow> wf_graph ?G \<Longrightarrow> all_security_requirements_fulfilled ?M ?G \<Longrightarrow> set ?edgesList \<subseteq> edges ?G \<Longrightarrow> all_security_requirements_fulfilled (get_IFS ?M) (stateful_policy_to_network_graph (generate_valid_stateful_policy_IFSACS ?G ?M ?edgesList))
|
\<lbrakk> ?H1 x_1; ?H2 x_2; ?H3 x_1 x_2; ?H4 (?H5 x_3) (?H6 x_2)\<rbrakk> \<Longrightarrow> ?H3 (?H7 x_1) (?H8 (?H9 x_2 x_1 x_3))
|
[
"TopoS_Stateful_Policy_Algorithm.generate_valid_stateful_policy_IFSACS",
"TopoS_Stateful_Policy.stateful_policy_to_network_graph",
"TopoS_Composition_Theory.get_IFS",
"FiniteGraph.graph.edges",
"List.list.set",
"Set.subset_eq",
"TopoS_Composition_Theory.all_security_requirements_fulfilled",
"FiniteGraph.wf_graph",
"TopoS_Composition_Theory.valid_reqs"
] |
[
"'a graph \\<Rightarrow> 'a SecurityInvariant_configured list \\<Rightarrow> ('a \\<times> 'a) list \\<Rightarrow> 'a stateful_policy",
"'a stateful_policy \\<Rightarrow> 'a graph",
"'a SecurityInvariant_configured list \\<Rightarrow> 'a SecurityInvariant_configured list",
"('a, 'b) graph_scheme \\<Rightarrow> ('a \\<times> 'a) set",
"'a list \\<Rightarrow> 'a set",
"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool",
"'a SecurityInvariant_configured list \\<Rightarrow> 'a graph \\<Rightarrow> bool",
"'a graph \\<Rightarrow> bool",
"'a SecurityInvariant_configured list \\<Rightarrow> bool"
] |
[
"definition generate_valid_stateful_policy_IFSACS :: \"'v::vertex graph \\<Rightarrow> 'v SecurityInvariant_configured list \\<Rightarrow> ('v \\<times> 'v) list \\<Rightarrow> 'v stateful_policy\" where\n \"generate_valid_stateful_policy_IFSACS G M edgesList \\<equiv> (let filterIFS = filter_IFS_no_violations G M edgesList in\n (let filterACS = filter_compliant_stateful_ACS G M filterIFS in \\<lparr> hosts = nodes G, flows_fix = edges G, flows_state = set filterACS \\<rparr>))\"",
"definition stateful_policy_to_network_graph :: \"'v stateful_policy \\<Rightarrow> 'v graph\" where\n \"stateful_policy_to_network_graph \\<T> = \\<lparr> nodes = hosts \\<T>, edges = all_flows \\<T> \\<rparr>\"",
"definition get_IFS :: \"('v::vertex) SecurityInvariant_configured list \\<Rightarrow> 'v SecurityInvariant_configured list\" where\n \"get_IFS M \\<equiv> [m \\<leftarrow> M. c_isIFS m]\"",
"datatype (set: 'a) list =\n Nil (\"[]\")\n | Cons (hd: 'a) (tl: \"'a list\") (infixr \"#\" 65)\nfor\n map: map\n rel: list_all2\n pred: list_all\nwhere\n \"tl [] = []\"",
"abbreviation subset_eq :: \"'a set \\<Rightarrow> 'a set \\<Rightarrow> bool\"\n where \"subset_eq \\<equiv> less_eq\"",
"definition all_security_requirements_fulfilled :: \"('v::vertex) SecurityInvariant_configured list \\<Rightarrow> 'v graph \\<Rightarrow> bool\" where\n \"all_security_requirements_fulfilled M G \\<equiv> \\<forall>m \\<in> set M. (c_sinvar m) G\"",
"definition valid_reqs :: \"('v::vertex) SecurityInvariant_configured list \\<Rightarrow> bool\" where\n \"valid_reqs M \\<equiv> \\<forall> m \\<in> set M. configured_SecurityInvariant m\""
] |
lemma_object
|
###symbols
TopoS_Stateful_Policy_Algorithm.generate_valid_stateful_policy_IFSACS :::: 'a graph \<Rightarrow> 'a SecurityInvariant_configured list \<Rightarrow> ('a \<times> 'a) list \<Rightarrow> 'a stateful_policy
TopoS_Stateful_Policy.stateful_policy_to_network_graph :::: 'a stateful_policy \<Rightarrow> 'a graph
TopoS_Composition_Theory.get_IFS :::: 'a SecurityInvariant_configured list \<Rightarrow> 'a SecurityInvariant_configured list
FiniteGraph.graph.edges :::: ('a, 'b) graph_scheme \<Rightarrow> ('a \<times> 'a) set
List.list.set :::: 'a list \<Rightarrow> 'a set
Set.subset_eq :::: 'a set \<Rightarrow> 'a set \<Rightarrow> bool
TopoS_Composition_Theory.all_security_requirements_fulfilled :::: 'a SecurityInvariant_configured list \<Rightarrow> 'a graph \<Rightarrow> bool
FiniteGraph.wf_graph :::: 'a graph \<Rightarrow> bool
TopoS_Composition_Theory.valid_reqs :::: 'a SecurityInvariant_configured list \<Rightarrow> bool
###defs
definition generate_valid_stateful_policy_IFSACS :: "'v::vertex graph \<Rightarrow> 'v SecurityInvariant_configured list \<Rightarrow> ('v \<times> 'v) list \<Rightarrow> 'v stateful_policy" where
"generate_valid_stateful_policy_IFSACS G M edgesList \<equiv> (let filterIFS = filter_IFS_no_violations G M edgesList in
(let filterACS = filter_compliant_stateful_ACS G M filterIFS in \<lparr> hosts = nodes G, flows_fix = edges G, flows_state = set filterACS \<rparr>))"
definition stateful_policy_to_network_graph :: "'v stateful_policy \<Rightarrow> 'v graph" where
"stateful_policy_to_network_graph \<T> = \<lparr> nodes = hosts \<T>, edges = all_flows \<T> \<rparr>"
definition get_IFS :: "('v::vertex) SecurityInvariant_configured list \<Rightarrow> 'v SecurityInvariant_configured list" where
"get_IFS M \<equiv> [m \<leftarrow> M. c_isIFS m]"
datatype (set: 'a) list =
Nil ("[]")
| Cons (hd: 'a) (tl: "'a list") (infixr "#" 65)
for
map: map
rel: list_all2
pred: list_all
where
"tl [] = []"
abbreviation subset_eq :: "'a set \<Rightarrow> 'a set \<Rightarrow> bool"
where "subset_eq \<equiv> less_eq"
definition all_security_requirements_fulfilled :: "('v::vertex) SecurityInvariant_configured list \<Rightarrow> 'v graph \<Rightarrow> bool" where
"all_security_requirements_fulfilled M G \<equiv> \<forall>m \<in> set M. (c_sinvar m) G"
definition valid_reqs :: "('v::vertex) SecurityInvariant_configured list \<Rightarrow> bool" where
"valid_reqs M \<equiv> \<forall> m \<in> set M. configured_SecurityInvariant m"
|
###output
valid_reqs ?M \<Longrightarrow> wf_graph ?G \<Longrightarrow> all_security_requirements_fulfilled ?M ?G \<Longrightarrow> set ?edgesList \<subseteq> edges ?G \<Longrightarrow> all_security_requirements_fulfilled (get_IFS ?M) (stateful_policy_to_network_graph (generate_valid_stateful_policy_IFSACS ?G ?M ?edgesList))###end
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.