Statement:
stringlengths
7
24.3k
lemma finite_set_decode [simp]: "finite (set_decode n)"
lemma iT_Div_mod_partition_card:" card (I \<inter> [n * d\<dots>,d - Suc 0] \<oslash> d) = (if I \<inter> [n * d\<dots>,d - Suc 0] = {} then 0 else Suc 0)"
lemma (in \<Z>) arr_Rel_converse_Rel_id_Rel: assumes "c \<in>\<^sub>\<circ> Vset \<alpha>" shows "arr_Rel \<alpha> ((id_Rel c)\<inverse>\<^sub>R\<^sub>e\<^sub>l)"
lemma valid_put_unis: \<open>\<forall>(e :: nat \<Rightarrow> 'a) f g. eval e f g p \<Longrightarrow> eval (e :: nat \<Rightarrow> 'a) f g (put_unis m p)\<close>
lemma(in Order_Rule) Bet_swap_lemma_5 : assumes "Bet_Point (Se A C) B" "Bet_Point (Se B D) C" "Bet_Point (Se C F) E" "\<not> Line_on (Li A D) F" "\<not> Line_on (Li A C) F" shows "Bet_Point (Se A D) C"
lemma rootI: "r\<^sup>@k \<in> r*"
lemma pred_stream_iff: "pred_stream P s \<longleftrightarrow> Ball (sset s) P"
theorem bose_inequality_alternate: "\<b> \<ge> \<v> + \<r> - 1 \<longleftrightarrow> \<r> \<ge> \<k> + \<Lambda>"
lemma H_is_gate [simp]: "gate 1 H"
lemma dprod_subset_Sigma2: "(dprod (Sigma A B) (Sigma C D)) <= Sigma (uprod A C) (Split (%x y. uprod (B x) (D y)))"
lemma semilattice_order_transfer[transfer_rule]: assumes [transfer_rule]: "bi_unique A" "right_total A" shows "( (A ===> A ===> A) ===> (A ===> A ===> (=)) ===> (A ===> A ===> (=)) ===> (=) ) (semilattice_order_ow (Collect (Domainp A))) semilattice_order"
lemma pos_empty [simp]: "pos [] = False"
lemma (in bin_cpx) Z_I_XpZ_trace: assumes "lhv M Z_I I_XpZ R Vz Vp" and "R\<in> fc_mats" shows "LINT w|M. (qt_expect Z_I Vz w) * (qt_expect I_XpZ Vp w) = Re (Complex_Matrix.trace (R * Z_XpZ))"
lemma Rf_mono_on_iia_on: shows "mono_on (Pow A) (Rf f) \<longleftrightarrow> iia_on A f"
lemma memo_rbt_trancl: "rs.\<alpha> (memo_rbt_trancl r a) = {b. (a, b) \<in> (set r)\<^sup>+}" (is "?l = ?r")
lemma FGModuleHom_restrict0_GSubspace : assumes "GSubspace U" shows "FGModuleHom G smult U smult' (T \<down> U)"
lemma snd3_simp[simp]: "snd3 (a,b,c) = b"
lemma seqSubstRes[simp]: fixes x :: name and P :: pi and \<sigma> :: "(name \<times> name) list" assumes "x \<sharp> \<sigma>" shows "(<\<nu>x>P)[<\<sigma>>] = <\<nu>x>(P[<\<sigma>>])"
lemma irreducibleE[elim]: assumes "irreducible p" and "p \<noteq> 0 \<Longrightarrow> \<not> p dvd 1 \<Longrightarrow> (\<And>a b. p = a * b \<Longrightarrow> a dvd 1 \<or> b dvd 1) \<Longrightarrow> thesis" shows thesis
lemma i_Exec_Stream_Init_nth_Plus1_calc: " i_Exec_Comp_Stream_Init trans_fun input c (n + 1) = trans_fun (input n) (i_Exec_Comp_Stream_Init trans_fun input c n)"
theorem ca: assumes nb: "evalDdb e\<cdot>env_empty_db \<noteq> \<bottom>" assumes "closed e" shows "\<exists>V. e \<Down> V"
lemma S_K2_empty: "S \<inter> K2 = {}"
lemma subset_dual1: "(X \<subseteq> Y) \<longleftrightarrow> (\<partial> ` X \<subseteq> \<partial> ` Y)"
lemma blinding_hash_eq: "bo x y \<Longrightarrow> h x = h y"
lemma relation_of_CSP2: "(relation_of x) is CSP2 healthy"
lemma phull_closed_mult_scalar: "p \<in> phull B \<Longrightarrow> monomial c 0 \<odot> p \<in> phull B"
theorem hurwitz_zeta_functional_equation: fixes h k :: nat and s :: complex assumes hk: "k > 0" "h \<in> {0<..k}" and s: "s \<notin> {0, 1}" defines "a \<equiv> real h / real k" shows "rGamma s * hurwitz_zeta a (1 - s) = 2 * (2 * pi * k) powr -s * (\<Sum>n=1..k. cos (s*pi/2 - 2*pi*n*h/k) * hurwitz_zeta (n / k) s)"
lemma effect_to_assignments_i: assumes "as = effect_to_assignments op" shows "as = (map (\<lambda>v. (v, True)) (add_effects_of op) @ map (\<lambda>v. (v, False)) (delete_effects_of op))"
lemma subcls_into_widen1_rtrancl: "P \<turnstile> C \<preceq>\<^sup>* D \<Longrightarrow> P \<turnstile> Class C <\<^sup>* Class D"
lemma store_bound_under: assumes "tag c = True" and "perm_store c = True" and "\<And> cv. \<lbrakk> v = Cap_v cv; tag cv \<rbrakk> \<Longrightarrow> perm_cap_store c \<and> (perm_cap_store_local c \<or> perm_global cv)" and "offset c + |memval_type v|\<^sub>\<tau> \<le> base c + len c" and "offset c < base c" shows "store h c v = Error (C2Err LengthViolation)"
lemma os_empty_impl: "imp_list_empty os_list os_empty"
lemma ball_empty: "e \<le> 0 \<Longrightarrow> ball x e = {}"
lemma "0 = dist x y \<Longrightarrow> x = y"
lemma csmall_nstep_Suc_nend: "o' \<in> csmall_nstep P \<sigma> (Suc n1) \<Longrightarrow> \<sigma> \<notin> endset"
lemma differentiable_bound_segment: fixes f::"'a::real_normed_vector \<Rightarrow> 'b::real_normed_vector" assumes "\<And>t. t \<in> {0..1} \<Longrightarrow> x0 + t *\<^sub>R a \<in> G" assumes f': "\<And>x. x \<in> G \<Longrightarrow> (f has_derivative f' x) (at x within G)" assumes B: "\<And>x. x \<in> {0..1} \<Longrightarrow> onorm (f' (x0 + x *\<^sub>R a)) \<le> B" shows "norm (f (x0 + a) - f x0) \<le> norm a * B"
lemma weakPsiCongOutputPushRes: fixes x :: name and \<Psi> :: 'b and M :: 'a and N :: 'a and P :: "('a, 'b, 'c) psi" assumes "x \<sharp> \<Psi>" and "x \<sharp> M" and "x \<sharp> N" shows "\<Psi> \<rhd> \<lparr>\<nu>x\<rparr>(M\<langle>N\<rangle>.P) \<doteq> M\<langle>N\<rangle>.\<lparr>\<nu>x\<rparr>P"
lemma squarefree_decomposition_unique: assumes "square_part m = square_part n" assumes "squarefree_part m = squarefree_part n" shows "m = n"
lemma "\<turnstile> \<lbrace>\<acute>N = 5\<rbrace> \<acute>N := 2 * \<acute>N \<lbrace>\<acute>N = 10\<rbrace>"
theorem integral_times: assumes int: "integrable f M" shows "integrable (\<lambda>t. a*f t) M" and "\<integral> (\<lambda>t. a*f t) \<partial>M = a*\<integral> f \<partial>M"
lemma mat_of_col_last_nth[simp]: "\<lbrakk> i < n; i < dim_col A \<rbrakk> \<Longrightarrow> col (mat_col_last A n) i = col A (dim_col A - n + i)"
lemma red_in_Hom [intro]: assumes "Ide t" shows "t\<^bold>\<down> \<in> HHom (Src t) (Trg t)" and "t\<^bold>\<down> \<in> VHom t \<^bold>\<lfloor>t\<^bold>\<rfloor>"
lemma splits_at_append_prefix: "splits_at v i \<alpha> N \<beta> \<Longrightarrow> splits_at (u@v) (i + length u) (u@\<alpha>) N \<beta>"
lemma line_convex_combination1: "(1 - u) *\<^sub>R line a b i + u *\<^sub>R b = line a b (i + u - i * u)"
lemma fold_const_fa[simp]: "interpret_floatarith (fold_const_fa fa) xs = interpret_floatarith fa xs"
lemma dilating_fun_image_left: assumes \<open>dilating_fun f r\<close> shows \<open>{k. f m \<le> k \<and> k < f n \<and> hamlet ((Rep_run r) k c)} = image f {k. m \<le> k \<and> k < n \<and> hamlet ((Rep_run r) (f k) c)}\<close> (is \<open>?IMG = image f ?SET\<close>)
lemma beta_lc[simp]: fixes t t' assumes "t \<rightarrow>\<^sub>\<beta> t'" shows "lc t \<and> lc t'"
lemma delete_text0[simp]: "get_pos b=0 \<Longrightarrow> get_text (delete b) = get_text b"
lemma bv_int_bv [simp]: "bv_to_int (int_to_bv i) = i"
lemma eqd_pref2: "x \<cdot> y = u \<cdot> v \<Longrightarrow> \<^bold>|x\<^bold>| \<le> \<^bold>|u\<^bold>| \<Longrightarrow> (x\<inverse>\<^sup>>u) \<cdot> v = y"
lemma seqr_or_distr: "(P ;; (Q \<or> R)) = ((P ;; Q) \<or> (P ;; R))"
lemma refl_on_program_order: "refl_onP (actions E) (program_order E)"
lemma merge_upd [simp]: "map_of (merge m (update k v n)) = map_of (update k v (merge m n))"
lemma nn_transfer_operator_cong: assumes "AE x in M. f x = g x" and [measurable]: "f \<in> borel_measurable M" "g \<in> borel_measurable M" shows "AE x in M. nn_transfer_operator f x = nn_transfer_operator g x"
lemma (in Corps) convergenceTr:"\<lbrakk>valuation K v; x \<in> carrier K; b \<in> carrier K; b \<in> (vp K v)\<^bsup>(Vr K v) n\<^esup>; (Abs (n_val K v x)) \<le> n\<rbrakk> \<Longrightarrow> x \<cdot>\<^sub>r b \<in> (vp K v)\<^bsup>(Vr K v) (n + (n_val K v x))\<^esup>"
lemma convex_translation_subtract: "convex ((\<lambda>b. b - a) ` S)" if "convex S"
lemma Cl_F: "Int_1a \<I> \<Longrightarrow> Int_2 \<I> \<Longrightarrow> Int_4 \<I> \<Longrightarrow> \<forall>A. Cl(\<F> A)"
lemma keysFor_synth [simp]: "keysFor (synth H) = keysFor H \<union> invKey`{K. Key K \<in> H}"
lemma sum_infsum: fixes f :: "'a \<Rightarrow> 'b::{topological_comm_monoid_add, t2_space}" assumes finite: \<open>finite A\<close> assumes conv: \<open>\<And>a. a \<in> A \<Longrightarrow> f summable_on (B a)\<close> assumes disj: \<open>\<And>a a'. a\<in>A \<Longrightarrow> a'\<in>A \<Longrightarrow> a\<noteq>a' \<Longrightarrow> B a \<inter> B a' = {}\<close> shows \<open>sum (\<lambda>a. infsum f (B a)) A = infsum f (\<Union>a\<in>A. B a)\<close>
lemma map_of_append: "map_of ((rev xs) @ ys) = (map_of ys) ((map fst xs) [\<mapsto>] (map snd xs))"
lemma test_bit_conj_lt: "(bit x m \<and> m < LENGTH('a)) = bit x m" for x :: "'a :: len word"
lemma deg_comp_pos: assumes "cmp u v = Lt" and "fst (rep_nat_term u) = fst (rep_nat_term v)" shows "deg_comp cmp u v = Lt"
lemma ring_chain: "R \<in> C \<Longrightarrow> ring R"
lemma l1: "-top = bot"
lemma int_cancel_factors: fixes n :: int assumes "1 < r" shows "n = 0 \<or> (\<exists>k i. n = k * r ^ i \<and> \<not> r dvd k)"
lemma GS_iter_max_code [code]: "GS_iter_max v s = (MAX a \<in> A s. GS_iter a v s)"
lemma keys_map_values [simp]: "keys (map_values f m) = keys m"
theorem condensation_test: assumes mono: "\<And>m. 0 < m \<Longrightarrow> f (Suc m) \<le> f m" assumes nonneg: "\<And>n. f n \<ge> 0" shows "summable f \<longleftrightarrow> summable (\<lambda>n. 2^n * f (2^n))"
theorem pr_gr_value: "c_assoc_value (pr_gr (loc_upb n x)) (c_pair n x) = univ_for_pr (c_pair n x)"
lemma global_reg_mod_privilege: "s' = global_reg_mod w1 n w2 s \<and> (((get_S (cpu_reg_val PSR s)))::word1) = 0 \<Longrightarrow> (((get_S (cpu_reg_val PSR s')))::word1) = 0"
theorem liftT_substT' [simp]: "k' < k \<Longrightarrow> \<up>\<^sub>\<tau> n k (T[k' \<mapsto>\<^sub>\<tau> U]\<^sub>\<tau>) = \<up>\<^sub>\<tau> n (k + 1) T[k' \<mapsto>\<^sub>\<tau> \<up>\<^sub>\<tau> n (k - k') U]\<^sub>\<tau>" "k' < k \<Longrightarrow> \<up>\<^sub>r\<^sub>\<tau> n k (rT[k' \<mapsto>\<^sub>\<tau> U]\<^sub>r\<^sub>\<tau>) = \<up>\<^sub>r\<^sub>\<tau> n (k + 1) rT[k' \<mapsto>\<^sub>\<tau> \<up>\<^sub>\<tau> n (k - k') U]\<^sub>r\<^sub>\<tau>" "k' < k \<Longrightarrow> \<up>\<^sub>f\<^sub>\<tau> n k (fT[k' \<mapsto>\<^sub>\<tau> U]\<^sub>f\<^sub>\<tau>) = \<up>\<^sub>f\<^sub>\<tau> n (k + 1) fT[k' \<mapsto>\<^sub>\<tau> \<up>\<^sub>\<tau> n (k - k') U]\<^sub>f\<^sub>\<tau>"
lemma prod_assn_precise[constraint_rules]: "precise P1 \<Longrightarrow> precise P2 \<Longrightarrow> precise (prod_assn P1 P2)"
lemma eqvtI[eqvt]: fixes P :: pi and Q :: pi and perm :: "name prm" assumes "P \<approx> Q" shows "(perm \<bullet> P) \<approx> (perm \<bullet> Q)"
lemma mk_linear_orders_decisive_on_set_r: assumes "r \<in> mk_linear_orders C B" assumes "decisive_on A f" assumes "B \<subseteq> A" shows "set r = B"
lemma Gromov_extension_onto': fixes f::"'a::Gromov_hyperbolic_space_geodesic \<Rightarrow> 'b::Gromov_hyperbolic_space_geodesic" assumes "lambda C-quasi_isometry_between UNIV UNIV f" shows "(Gromov_extension f)`Gromov_boundary = Gromov_boundary"
lemma llist_of_lprefix_llist_of [simp]: "lprefix (llist_of xs) (llist_of ys) \<longleftrightarrow> xs \<le> ys"
lemma infinite_contains_2_elems: assumes "infinite A" shows "\<exists> x y. x \<noteq> y \<and> x \<in> A \<and> y \<in> A"
lemma heapmap_nres_rel_prodI: assumes "hmx \<le> \<Down>(UNIV \<times>\<^sub>r hmr_rel) h'x" assumes "h'x \<le> SPEC (\<lambda>(_,h'). h.heap_invar h')" assumes "hmx \<le>\<^sub>n SPEC (\<lambda>(r,hm'). RETURN (r,heapmap_\<alpha> hm') \<le> \<Down>(R\<times>\<^sub>rId) hx)" shows "hmx \<le> \<Down>(R\<times>\<^sub>rheapmap_rel) hx"
lemma decide_step: assumes run: "HORun UV_M rho HOs" and decide: "decide (rho (Suc r) p) \<noteq> decide (rho r p)" shows "step r = 1"
lemma rell_FGf_mono_strong: assumes "rell_FGf L1 L2 x y" and "\<And>a b. a \<in> set1_FGf x \<Longrightarrow> b \<in> set1_FGf y \<Longrightarrow> L1 a b \<Longrightarrow> L1' a b" and "\<And>a b. a \<in> set2_FGf x \<Longrightarrow> b \<in> set2_FGf y \<Longrightarrow> L2 a b \<Longrightarrow> L2' a b" shows "rell_FGf L1' L2' x y"
theorem dist_induces_open: "open U \<longleftrightarrow> (\<forall>x\<in>U. \<exists>e>0. \<forall>y. dist x y < e \<longrightarrow> y \<in> U)"
lemma id_eq_prop_prop_7_b[PLM]: "[(p::\<o>) \<^bold>= p in v]"
lemma not_negligible_1: "\<not> negligible (\<lambda>_. 1 :: real)"
lemma varFIXvar: "(PhiWhile b \<Phi> (s,t,\<beta>)) = ((b,\<Phi>,\<beta>,s,t):var)"
lemma C_Red_term_ML: "v \<Rightarrow> v' \<Longrightarrow> C_normal\<^sub>M\<^sub>L v \<Longrightarrow> dterm\<^sub>M\<^sub>L v = C nm \<bullet>\<bullet> ts \<Longrightarrow> dterm\<^sub>M\<^sub>L v' = C nm \<bullet>\<bullet> map dterm (C\<^sub>U_args(term v')) \<and> C\<^sub>U_args(term v) [\<Rightarrow>*] C\<^sub>U_args(term v') \<and> ts = map dterm (C\<^sub>U_args(term v))" and "(vs:: ml list) \<Rightarrow> vs' \<Longrightarrow> i < length vs \<Longrightarrow> vs ! i \<Rightarrow>* vs' ! i"
lemma AbstrLevels_A8_A82: assumes "sA8 \<in> AbstrLevel i" shows "sA82 \<notin> AbstrLevel i"
lemma cut_le_inext_nth_card_eq2: " \<lbrakk> finite I; card I \<le> Suc n \<rbrakk> \<Longrightarrow> card (I \<down>\<le> (I \<rightarrow> n)) = card I"
lemma relprime: fixes q::"real poly" assumes "coprime p q" assumes "p \<noteq> 0" assumes "q \<noteq> 0" shows "changes_R_smods p (pderiv p) = card {x. poly p x = 0 \<and> poly q x > 0} + card {x. poly p x = 0 \<and> poly q x < 0}"
lemma "(\<forall>x y. \<exists>z. \<forall>w. (P(x)\<and>Q(y)\<longrightarrow>R(z)\<and>S(w))) \<longrightarrow> (\<exists>x y. P(x) \<and> Q(y)) \<longrightarrow> (\<exists>z. R(z))"
lemma max_input_Times: "max_input (Times a1 a2) = max (max_input a1) (max_input a2)"
lemma iso_view\<^sub>m: "type_definition from_view\<^sub>m to_view\<^sub>m UNIV"
lemma blinding_blinds [simp]: "is_blinded (blind_source_tree h t)"
lemma inv_state: "inv(state f n)"
lemma elements_four_block_mat_id: assumes c: "A \<in> carrier_mat nr1 nc1" "B \<in> carrier_mat nr1 nc2" "C \<in> carrier_mat nr2 nc1" "D \<in> carrier_mat nr2 nc2" shows "elements_mat (four_block_mat A B C D) = elements_mat A \<union> elements_mat B \<union> elements_mat C \<union> elements_mat D" (is "elements_mat ?four = ?X")
lemma (in cring) ideal_prod_commute: assumes "ideal I R" "ideal J R" shows "I \<cdot> J = J \<cdot> I"
lemma list_comb_cond_inj: assumes "list_comb f xs = list_comb g ys" "left_nesting f = left_nesting g" shows "xs = ys" "f = g"
lemma shiftr_less_t2n3: "\<lbrakk> (2 :: 'a word) ^ (n + m) = 0; m < LENGTH('a) \<rbrakk> \<Longrightarrow> (x :: 'a :: len word) >> n < 2 ^ m"
lemma plus_cont: "f \<in> bcontfun \<Longrightarrow> g \<in> bcontfun \<Longrightarrow> (\<lambda>x. f x + g x) \<in> bcontfun" for f g::"'a \<Rightarrow> 'b"
lemma start_clinit_wt_method: assumes "P \<turnstile> C sees M, Static : []\<rightarrow>Void = m in D" and "M \<noteq> clinit" and "\<not> is_class P Start" shows "wt_method (start_prog P C M) Start Static [] Void 1 0 [Push Unit,Return] [] start_\<phi>\<^sub>m" (is "wt_method ?P ?C ?b ?Ts ?T\<^sub>r ?mxs ?mxl\<^sub>0 ?is ?xt ?\<tau>s")
lemma ex_opt_blinfun: "\<exists>d. \<forall>s. is_arg_max (\<lambda>d. ((inv\<^sub>L (Q_GS d)) (r_det\<^sub>b d + (R_GS d) v)) s) is_dec_det d"
lemma rl_thm': assumes lp: "iszlfm p (real_of_int (i::int)#bs)" and R: "(\<lambda>(b,k). (Inum (a#bs) b,k)) ` R = (\<lambda>(b,k). (Inum (a#bs) b,k)) ` set (\<rho> p)" shows "(\<exists> (x::int). Ifm (real_of_int x#bs) p) = ((\<exists> j\<in> {1 .. \<delta> p}. Ifm (real_of_int j#bs) (minusinf p)) \<or> (\<exists> (e,c) \<in> R. \<exists> j\<in> {1.. c*(\<delta> p)}. Ifm (a#bs) (\<sigma> p c (Add e (C j)))))"