src/HOL/Induct/QuoDataType.thy
changeset 39910 10097e0a9dbd
parent 39246 9e58f0499f57
child 40825 c55ee3793712
equal deleted inserted replaced
39818:ff9e9d5ac171 39910:10097e0a9dbd
   420 text{*However, as @{text Crypt_Nonce_neq_Nonce} above illustrates, we don't
   420 text{*However, as @{text Crypt_Nonce_neq_Nonce} above illustrates, we don't
   421 need this function in order to prove discrimination theorems.*}
   421 need this function in order to prove discrimination theorems.*}
   422 
   422 
   423 definition
   423 definition
   424   discrim :: "msg \<Rightarrow> int" where
   424   discrim :: "msg \<Rightarrow> int" where
   425    "discrim X = contents (\<Union>U \<in> Rep_Msg X. {freediscrim U})"
   425    "discrim X = the_elem (\<Union>U \<in> Rep_Msg X. {freediscrim U})"
   426 
   426 
   427 lemma discrim_congruent: "(\<lambda>U. {freediscrim U}) respects msgrel"
   427 lemma discrim_congruent: "(\<lambda>U. {freediscrim U}) respects msgrel"
   428 by (simp add: congruent_def msgrel_imp_eq_freediscrim) 
   428 by (simp add: congruent_def msgrel_imp_eq_freediscrim) 
   429 
   429 
   430 text{*Now prove the four equations for @{term discrim}*}
   430 text{*Now prove the four equations for @{term discrim}*}