src/HOL/NSA/HyperDef.thy
changeset 37765 26bdfb7b680b
parent 36409 d323e7773aa8
child 38715 6513ea67d95d
equal deleted inserted replaced
37764:3489daf839d5 37765:26bdfb7b680b
    43 
    43 
    44 instantiation star :: (scaleR) scaleR
    44 instantiation star :: (scaleR) scaleR
    45 begin
    45 begin
    46 
    46 
    47 definition
    47 definition
    48   star_scaleR_def [transfer_unfold, code del]: "scaleR r \<equiv> *f* (scaleR r)"
    48   star_scaleR_def [transfer_unfold]: "scaleR r \<equiv> *f* (scaleR r)"
    49 
    49 
    50 instance ..
    50 instance ..
    51 
    51 
    52 end
    52 end
    53 
    53 
   109 
   109 
   110 subsection {* Injection from @{typ hypreal} *}
   110 subsection {* Injection from @{typ hypreal} *}
   111 
   111 
   112 definition
   112 definition
   113   of_hypreal :: "hypreal \<Rightarrow> 'a::real_algebra_1 star" where
   113   of_hypreal :: "hypreal \<Rightarrow> 'a::real_algebra_1 star" where
   114   [transfer_unfold, code del]: "of_hypreal = *f* of_real"
   114   [transfer_unfold]: "of_hypreal = *f* of_real"
   115 
   115 
   116 lemma Standard_of_hypreal [simp]:
   116 lemma Standard_of_hypreal [simp]:
   117   "r \<in> Standard \<Longrightarrow> of_hypreal r \<in> Standard"
   117   "r \<in> Standard \<Longrightarrow> of_hypreal r \<in> Standard"
   118 by (simp add: of_hypreal_def)
   118 by (simp add: of_hypreal_def)
   119 
   119 
   433 *)
   433 *)
   434 
   434 
   435 subsection{*Powers with Hypernatural Exponents*}
   435 subsection{*Powers with Hypernatural Exponents*}
   436 
   436 
   437 definition pow :: "['a::power star, nat star] \<Rightarrow> 'a star" (infixr "pow" 80) where
   437 definition pow :: "['a::power star, nat star] \<Rightarrow> 'a star" (infixr "pow" 80) where
   438   hyperpow_def [transfer_unfold, code del]: "R pow N = ( *f2* op ^) R N"
   438   hyperpow_def [transfer_unfold]: "R pow N = ( *f2* op ^) R N"
   439   (* hypernatural powers of hyperreals *)
   439   (* hypernatural powers of hyperreals *)
   440 
   440 
   441 lemma Standard_hyperpow [simp]:
   441 lemma Standard_hyperpow [simp]:
   442   "\<lbrakk>r \<in> Standard; n \<in> Standard\<rbrakk> \<Longrightarrow> r pow n \<in> Standard"
   442   "\<lbrakk>r \<in> Standard; n \<in> Standard\<rbrakk> \<Longrightarrow> r pow n \<in> Standard"
   443 unfolding hyperpow_def by simp
   443 unfolding hyperpow_def by simp