Statement:
stringlengths
7
24.3k
lemma isin_sorted_split_list_right: assumes "split_list ts x = (ls, sep#rs)" and "sorted_less ts" shows "x \<in> set (sep#rs) = (x = sep)"
lemma hnorm_triangle_ineq: "\<And>x y::'a::real_normed_vector star. hnorm (x + y) \<le> hnorm x + hnorm y"
lemma std_normal_moment_even: "has_bochner_integral lborel (\<lambda>x. std_normal_density x * x ^ (2 * k)) (fact (2 * k) / (2^k * fact k))"
lemma has_derivative_within_alt: "(f has_derivative f') (at x within s) \<longleftrightarrow> bounded_linear f' \<and> (\<forall>e>0. \<exists>d>0. \<forall>y\<in>s. norm(y - x) < d \<longrightarrow> norm (f y - f x - f' (y - x)) \<le> e * norm (y - x))"
lemma cnj_of_int [simp]: "cnj (of_int z) = of_int z"
lemma fv_eqvt[simp,eqvt]: "\<pi> \<bullet> (fv e) = fv (\<pi> \<bullet> e)"
lemma exp_Lambert_W': "x \<in> {-exp (-1)..<0} \<Longrightarrow> exp (Lambert_W' x) = x / Lambert_W' x"
lemma sum_atLeast_Suc_shift: "0 < b \<Longrightarrow> a \<le> b \<Longrightarrow> sum f {Suc a..b} = (\<Sum>i=a..b - 1. f (Suc i))"
lemma Contra: "insert (neg A) H \<turnstile> A \<Longrightarrow> H \<turnstile> A"
lemma PPs\<alpha>_of_step: "\<langle>c,m\<rangle> \<rightarrow>\<lhd>\<alpha>\<rhd> \<langle>p,m'\<rangle> \<Longrightarrow> set (PPV \<alpha>) \<subseteq> set (PPc c)"
lemma kp_5x9_ur_last: "last kp5x9ur = (4,8)"
lemma delay_lazy_cong: "delay f = delay f"
lemma PK_imply_weaken: assumes \<open>A; B \<turnstile>\<^sub>! ps \<^bold>\<leadsto>\<^sub>! q\<close> \<open>set ps \<subseteq> set ps'\<close> shows \<open>A; B \<turnstile>\<^sub>! ps' \<^bold>\<leadsto>\<^sub>! q\<close>
lemma exec_strip_guards_to_exec: assumes exec_strip: "\<Gamma>\<turnstile>\<langle>strip_guards F c,s\<rangle> \<Rightarrow> t" shows "\<exists>t'. \<Gamma>\<turnstile>\<langle>c,s\<rangle> \<Rightarrow> t' \<and> (isFault t \<longrightarrow> isFault t') \<and> (t' \<in> Fault ` (-F) \<longrightarrow> t'=t) \<and> (\<not> isFault t' \<longrightarrow> t'=t)"
lemma Abs_swap_fresh: assumes good_X: "good X" and fresh: "fresh xs x' X" shows "Abs xs x X = Abs xs x' (X #[x' \<and> x]_xs)"
lemma leftderives_induct[consumes 1, case_names Base Step]: assumes derives: "leftderives a b" assumes Pa: "P a" assumes induct: "\<And>y z. leftderives a y \<Longrightarrow> leftderives1 y z \<Longrightarrow> P y \<Longrightarrow> P z" shows "P b"
lemma ordinal_wf: "wf {(x,y::ordinal). x < y}"
lemma Transset_TC: "Transset(TC a)"
lemma While_inter_right: "interfree_aux_right \<Gamma> \<Theta> F (q, c, a) \<Longrightarrow> interfree_aux_right \<Gamma> \<Theta> F (q, While b c, AnnWhile r i a)"
lemma matches_rule_and_simp: assumes "matches \<gamma> m p" shows "\<Gamma>,\<gamma>,p\<turnstile>\<^sub>g \<langle>[Rule (MatchAnd m m') a'], s\<rangle> \<Rightarrow> t \<longleftrightarrow> \<Gamma>,\<gamma>,p\<turnstile>\<^sub>g \<langle>[Rule m' a'], s\<rangle> \<Rightarrow> t"
lemma OclOr2[simp]: "(invalid or false) = invalid"
lemma equivp_dlist_eq: "equivp dlist_eq"
lemma interpretation_grounds_all': "interpretation\<^sub>s\<^sub>u\<^sub>b\<^sub>s\<^sub>t \<theta> \<Longrightarrow> ground (M \<cdot>\<^sub>s\<^sub>e\<^sub>t \<theta>)"
lemma guha_umstaendlich: (* or maybe it's Coq where the original formulation is more beneficial *) assumes ae: "a = ofe_action fe" assumes ele: "fe \<in> set ft" assumes rest: "\<gamma> (ofe_fields fe) p" "\<forall>fe' \<in> set ft. ofe_prio fe' > ofe_prio fe \<longrightarrow> \<not>\<gamma> (ofe_fields fe') p" shows "guha_table_semantics \<gamma> ft p (Some a)"
lemma product_dvd_irreducibleD: fixes a b x :: "'a :: algebraic_semidom" assumes "irreducible x" assumes "a * b dvd x" shows "a dvd 1 \<or> b dvd 1"
lemma singular_boundary: "singular_relboundary p X {} c \<longleftrightarrow> (\<exists>d. singular_chain (Suc p) X d \<and> chain_boundary (Suc p) d = c)"
lemma simple_list_index_equality: assumes "length a = n" assumes "length b = n" assumes "\<forall>i < n. a!i = b!i" shows "a = b"
lemma sizeof_nonzero: "|t|\<^sub>\<tau> > 0"
lemma Arr_in_Hom: assumes "Arr t" shows "t \<in> HHom (Src t) (Trg t)" and "t \<in> VHom (Dom t) (Cod t)"
lemma Nil_in_Shuffle[simp]: "[] \<in> A \<parallel> B \<longleftrightarrow> [] \<in> A \<and> [] \<in> B"
lemma zip_fun_eq[dest]: assumes "f \<parallel> g = h \<parallel> i" shows "f = h" "g = i"
lemma a_consistent_thunk_once: assumes "a_consistent (ae, a, as) (\<Gamma>, Var x, S)" assumes "map_of \<Gamma> x = Some e" assumes [simp]: "ae x = up\<cdot>u" assumes "heap_upds_ok (\<Gamma>, S)" shows "a_consistent (env_delete x ae, u, as) (delete x \<Gamma>, e, S)"
lemma case_nat_in_state_measure[intro]: assumes "x \<in> type_universe t1" "\<sigma> \<in> space (state_measure V \<Gamma>)" shows "case_nat x \<sigma> \<in> space (state_measure (shift_var_set V) (case_nat t1 \<Gamma>))"
lemma (in is_functor) ntcf_arrow_id_components: "(ntcf_arrow_id \<AA> \<BB> (cf_map \<FF>))\<lparr>NTMap\<rparr> = ntcf_id \<FF>\<lparr>NTMap\<rparr>" "(ntcf_arrow_id \<AA> \<BB> (cf_map \<FF>))\<lparr>NTDom\<rparr> = cf_map (ntcf_id \<FF>\<lparr>NTDom\<rparr>)" "(ntcf_arrow_id \<AA> \<BB> (cf_map \<FF>))\<lparr>NTCod\<rparr> = cf_map (ntcf_id \<FF>\<lparr>NTCod\<rparr>)"
lemma red_simps [simp]: assumes "Ide t" shows "Src (t\<^bold>\<down>) = Src t" and "Trg (t\<^bold>\<down>) = Trg t" and "Dom (t\<^bold>\<down>) = t" and "Cod (t\<^bold>\<down>) = \<^bold>\<lfloor>t\<^bold>\<rfloor>"
lemma raw_ports_compress_dst_CannotMatch: fixes p :: "('i::len, 'a) tagged_packet_scheme" assumes generic: "primitive_matcher_generic \<beta>" and c: "l4_ports_compress pss = CannotMatch" shows "\<not> matches (\<beta>, \<alpha>) (alist_and (map (Pos \<circ> Dst_Ports) pss)) a p"
lemma r_swap_recfn [simp]: "recfn 2 f \<Longrightarrow> recfn 2 (r_swap f)"
lemma wf_chains2: fixes k assumes "S |\<subseteq>| initials G" and "wf_dia G" and "\<Pi> \<in> ps_chains2 S G" and "fcard G^V + length G^E = k + fcard S" shows "wf_ps_chain \<Pi> \<and> (post \<Pi> = [ terminals G |=> Bot ])"
lemma exists_finite_inconsistent: assumes \<open>\<not> consistent A ({\<^bold>\<not> p} \<union> V)\<close> obtains W where \<open>{\<^bold>\<not> p} \<union> W \<subseteq> {\<^bold>\<not> p} \<union> V\<close> \<open>(\<^bold>\<not> p) \<notin> W\<close> \<open>finite W\<close> \<open>\<not> consistent A ({\<^bold>\<not> p} \<union> W)\<close>
lemma msig_qmdecl_simp[simp]: "msig (qmdecl sig m) = sig"
lemma val_ringI: assumes "a \<in> carrier Q\<^sub>p" assumes "val a \<ge>0" shows " a \<in> \<O>\<^sub>p"
lemma add_anno_rel_GuarNoWrite [simp]: "\<Gamma> \<oplus>\<^sub>\<S> (v -=\<^sub>m GuarNoWrite) = \<Gamma>"
lemma ground_head: "ground s \<Longrightarrow> is_Sym (head s)"
lemma quadratic_linear1: assumes "b\<noteq>0" assumes "a \<noteq> 0" assumes "4 * a * ba \<le> aa\<^sup>2" assumes "(b::real) * (sqrt ((aa::real)\<^sup>2 - 4 * (a::real) * (ba::real)) - (aa::real)) / (2 * a) + (c::real) = 0" assumes " (\<forall>x\<in>set (les::(real*real*real)list). case x of (d, e, f) \<Rightarrow> d * ((sqrt (aa\<^sup>2 - 4 * a * ba) - aa) / (2 * a))\<^sup>2 + e * (sqrt (aa\<^sup>2 - 4 * a * ba) - aa) / (2 * a) + f < 0)" assumes "(aaa, aaaa, baa) \<in> set les" shows "aaa * (c / b)\<^sup>2 - aaaa * c / b + baa < 0"
lemma obtain_fresh_z_c_of: fixes t::"'b::fs" obtains z where "atom z \<sharp> t \<and> \<tau> = \<lbrace> z : b_of \<tau> | c_of \<tau> z \<rbrace>"
lemma (in comm_group) rel_in_carr: assumes "A \<subseteq> carrier G" "r \<in> relations A" shows "(\<lambda>a. a [^] r a) \<in> A \<rightarrow> carrier G"
lemma rbt_insert_entries_Some: "is_rbt t \<Longrightarrow> rbt_lookup t k = Some v' \<Longrightarrow> set (RBT_Impl.entries (rbt_insert k v t)) = insert (k, v) (set (RBT_Impl.entries t) - {(k, v')})"
lemma src_ipPart_motivation: fixes rs defines "X \<equiv> (\<lambda>(base,len). ipset_from_cidr base len) ` src ` match_sel ` set rs" assumes "\<forall>A \<in> X. B \<subseteq> A \<or> B \<inter> A = {}" and "s1 \<in> B" and "s2 \<in> B" shows "simple_fw rs (p\<lparr>p_src:=s1\<rparr>) = simple_fw rs (p\<lparr>p_src:=s2\<rparr>)"
lemma mkKripke_simps[simp]: "worlds (mkKripke ws rels val) = ws" "relations (mkKripke ws rels val) = (\<lambda>a. rels a \<inter> ws \<times> ws)" "valuation (mkKripke ws rels val) = val"
lemma sdrop_sconst: "sdrop n s = sconst x \<Longrightarrow> n \<le> m \<Longrightarrow> s !! m = x"
lemma bijection_transpose: \<open>bijection (transpose a b)\<close>
lemma reach2: "\<not> s\<turnstile> l reachable_from x \<Longrightarrow> \<not> s\<langle>l:=y\<rangle>\<turnstile> l reachable_from x"
lemma cdi_iff_no_strict_pd: \<open>i cd\<^bsup>\<pi>\<^esup>\<rightarrow> k \<longleftrightarrow> is_path \<pi> \<and> k < i \<and> \<pi> i \<noteq> return \<and> (\<forall> j \<in> {k..i}. \<not> (\<pi> k, \<pi> j) \<in> pdt)\<close>
lemma in_Chains_subset: "\<lbrakk> M \<in> Chains r; M' \<subseteq> M \<rbrakk> \<Longrightarrow> M' \<in> Chains r"
lemma sync_jview_jAction_eq: assumes traces: "{ t \<in> T . tLength t = n } = { t \<in> T' . tLength t = n }" assumes tT: "t \<in> { t \<in> T . tLength t = n }" shows "jAction (mkM T) t = jAction (mkM T') t"
lemma zeta_partial_sum_le_neg: assumes "s > 0" shows "\<exists>c>0. \<forall>x\<ge>1. \<bar>sum_upto (\<lambda>n. n powr s) x - x powr (1 + s) / (1 + s)\<bar> \<le> c * x powr s"
lemma Zn_neq1_cyclic_group: assumes "n \<noteq> 1" shows "cyclic_group (Z n) 1"
lemma addBalance_eq: assumes "addBalance ad val acc = Some acc'" and "ad \<noteq> ad'" shows "(accessBalance acc ad') = (accessBalance acc' ad')"
lemma Stirling_same [simp]: "Stirling n n = 1"
theorem rinss_random_bst: "distr (rinss xs \<langle>\<rangle> A) (tree_sigma (count_space A)) (map_tree fst) = restrict_space (measure_pmf (random_bst (set xs))) (trees A)"
lemma PosOrd_Stars_appendI: assumes "Stars vs1 :\<sqsubset>val Stars vs2" "flat (Stars vs1) = flat (Stars vs2)" shows "Stars (vs @ vs1) :\<sqsubset>val Stars (vs @ vs2)"
lemma decr_sorted: assumes "decr xs" shows "sorted (rev xs)"
lemma min_dist_z[simp]: "min_dist v v = 0"
lemma empty_text[simp]: "get_text empty = []"
lemma noWhileL_intro[intro]: assumes "\<And> c. c \<in> set cl \<Longrightarrow> noWhile c" shows "noWhileL cl"
lemma Derives1_rule: "Derives1 a i r b \<Longrightarrow> r \<in> \<RR>"
lemma "test (do { doc \<leftarrow> return Node_removeChild_document; s \<leftarrow> doc . createElement(''div''); tmp0 \<leftarrow> s . ownerDocument; assert_equals(tmp0, doc); tmp1 \<leftarrow> Node_removeChild_document . body; assert_throws(NotFoundError, tmp1 . removeChild(s)); tmp2 \<leftarrow> s . ownerDocument; assert_equals(tmp2, doc) }) Node_removeChild_heap"
lemma i_Exec_Comp_Stream_Acc_Output__eq_Msg_State_Idle_conv': " \<lbrakk> Suc 0 < k; State_Idle localState output_fun trans_fun ( i_Exec_Comp_Stream_Acc_LocalState k localState trans_fun input c t); m \<noteq> \<NoMsg>; t0 = t * k; s = i_Exec_Comp_Stream trans_fun (input \<odot>\<^sub>i k) c \<rbrakk> \<Longrightarrow> (i_Exec_Comp_Stream_Acc_Output k output_fun trans_fun input c t = m) = (((\<not> State_Idle localState output_fun trans_fun (localState (s t2))). t2 \<U> t1 [0\<dots>] \<oplus> t0. (output_fun (s t1) = m \<and> State_Idle localState output_fun trans_fun (localState (s t1)))) \<or> ((\<not> State_Idle localState output_fun trans_fun (localState (s t2))). t2 \<U> t1 [0\<dots>] \<oplus> t0. (output_fun (s t1) = m \<and> (\<circle> t3 t1 [0\<dots>]. ((output_fun (s t4) = \<NoMsg>. t4 \<U> t5 ([0\<dots>] \<oplus> t3). (output_fun (s t5) = \<NoMsg> \<and> State_Idle localState output_fun trans_fun (localState (s t5)))))))))"
lemma summable_on_cinner_left: assumes \<open>f summable_on I\<close> shows \<open>(\<lambda>i. cinner a (f i)) summable_on I\<close>
lemma Pring_zero: "\<zero>\<^bsub>Pring R I\<^esub> = indexed_const \<zero>"
lemma region_addresses_iff: "a' \<in> region_addresses a si \<longleftrightarrow> unat (a' - a) < si"
lemma vwalk_arcs_tl_empty: "vwalk_arcs xs = [] \<Longrightarrow> vwalk_arcs (tl xs) = []"
lemma DERIV_continuous_on: "(\<And>x. x \<in> s \<Longrightarrow> (f has_field_derivative (D x)) (at x within s)) \<Longrightarrow> continuous_on s f"
lemma stream_numeral [simp]: "stream (numeral n) = numeral n"
lemma set_of_mul_inc_right: "set_of (A * B) \<subseteq> set_of (A * B')" if "set_of B \<subseteq> set_of B'" for A :: "'a::linordered_ring interval"
lemma bounded_clinear_CBlinfun_apply: "bounded_clinear f \<Longrightarrow> cblinfun_apply (CBlinfun f) = f"
lemma max_triangle_bound: "triangle z \<le> e \<Longrightarrow> z \<le> e"
lemma sign_changes_0_Cons [simp]: "sign_changes (0 # xs :: 'a :: idom_abs_sgn list) = sign_changes xs"
lemma fmrestrict_set_inter_img: fixes A X Y shows "fmrestrict_set (X \<inter> Y) ` A = (fmrestrict_set X \<circ> fmrestrict_set Y) ` A"
lemma order_le_prod [iff]: "order(Product.le rA rB) = (order rA & order rB)"
lemma b_assn_invalid_merge3: "hn_invalid A x y \<or>\<^sub>A hn_invalid (b_assn A P) x y \<Longrightarrow>\<^sub>t hn_invalid A x y"
lemma (in \<Z>) smc_CAT_obj_initialD: assumes "obj_initial (smc_CAT \<alpha>) \<AA>" shows "\<AA> = cat_0"
lemma condensation_condense1: "(\<Sum>k=1..<2^n. f (2 ^ Discrete.log k)) = (\<Sum>k<n. 2^k * f (2 ^ k))"
lemma plossless_fail_converter [simp]: "plossless_converter \<I> \<I>' fail_converter \<longleftrightarrow> \<I> = bot" (is "?lhs \<longleftrightarrow> ?rhs")
lemma ord_of_minus_1: "n > 0 \<Longrightarrow> ord_of n = succ (ord_of (n - 1))"
lemma fpairs_vinsert: "fpairs (vinsert [a, b]\<^sub>\<circ> A) = set {[a, b]\<^sub>\<circ>} \<union>\<^sub>\<circ> fpairs A"
lemma Abs_sat'_eq_of_nat: "Abs_sat' n = of_nat n"
lemma l3_lkr_after_refines_lkr_after: "{R23s} l2_lkr_after A, l3_lkr_after A {>R23s}"
lemma sort_rev_eq_sort: "distinct xs \<Longrightarrow> sort (rev xs) = sort xs"
lemma is_weak_order_B: "weak_partial_order \<Y>"
lemma "!!a::real. a + b + c + d \<le> i + j + k + l ==> a \<le> b ==> b \<le> c ==> c \<le> d ==> i \<le> j ==> j \<le> k ==> k \<le> l ==> a + a + a + a + a + a \<le> l + l + l + l + i + l"
lemma [def_pat_rules]: "Network.resCap_cf_impl$c \<equiv> UNPROTECT resCap_cf_impl"
lemma fresh_star_insert_elim: "(insert x S \<sharp>* c \<Longrightarrow> PROP C) \<equiv> (x \<sharp> c \<Longrightarrow> S \<sharp>* c \<Longrightarrow> PROP C)"
lemma N_vector_top_pp [simp]: "N (x * top) * top = --(x * top)"
lemma vcompI[intro!]: assumes "\<langle>b, c\<rangle> \<in>\<^sub>\<circ> r" and "\<langle>a, b\<rangle> \<in>\<^sub>\<circ> s" shows "\<langle>a, c\<rangle> \<in>\<^sub>\<circ> r \<circ>\<^sub>\<circ> s"
lemma alphaAbs_qAbs_iff_alphaAbs_all_equal_or_qFresh: assumes "qGood X" and "qGood X'" shows "(qAbs xs x X $= qAbs xs' x' X') = alphaAbs_all_equal_or_qFresh xs x X xs' x' X'"
lemma (in CRR_market) case_asset: assumes "asset \<in> stocks Mkt" shows "asset = stk \<or> asset = risk_free_asset"
lemma alprio_delete_correct: assumes "al_annot \<alpha> invar annot" and "al_splits \<alpha> invar splits" and "al_app \<alpha> invar app" shows "prio_delete (alprio_\<alpha> \<alpha>) (alprio_invar \<alpha> invar) (alprio_find annot) (alprio_delete splits annot app)"
lemma map_key_PP_sum: "Poly_Mapping.map_key PP (sum f A) = (\<Sum>a\<in>A. Poly_Mapping.map_key PP (f a))"
lemma act_morph2: "\<alpha> 1 = id"