src/HOL/Limits.thy
changeset 51360 c4367ed99b5e
parent 51328 d63ec23c9125
child 51471 cad22a3cc09c
equal deleted inserted replaced
51359:00b45c7e831f 51360:c4367ed99b5e
   773 
   773 
   774 abbreviation (in topological_space)
   774 abbreviation (in topological_space)
   775   tendsto :: "('b \<Rightarrow> 'a) \<Rightarrow> 'a \<Rightarrow> 'b filter \<Rightarrow> bool" (infixr "--->" 55) where
   775   tendsto :: "('b \<Rightarrow> 'a) \<Rightarrow> 'a \<Rightarrow> 'b filter \<Rightarrow> bool" (infixr "--->" 55) where
   776   "(f ---> l) F \<equiv> filterlim f (nhds l) F"
   776   "(f ---> l) F \<equiv> filterlim f (nhds l) F"
   777 
   777 
       
   778 lemma tendsto_eq_rhs: "(f ---> x) F \<Longrightarrow> x = y \<Longrightarrow> (f ---> y) F"
       
   779   by simp
       
   780 
   778 ML {*
   781 ML {*
       
   782 
   779 structure Tendsto_Intros = Named_Thms
   783 structure Tendsto_Intros = Named_Thms
   780 (
   784 (
   781   val name = @{binding tendsto_intros}
   785   val name = @{binding tendsto_intros}
   782   val description = "introduction rules for tendsto"
   786   val description = "introduction rules for tendsto"
   783 )
   787 )
       
   788 
   784 *}
   789 *}
   785 
   790 
   786 setup Tendsto_Intros.setup
   791 setup {*
       
   792   Tendsto_Intros.setup #>
       
   793   Global_Theory.add_thms_dynamic (@{binding tendsto_eq_intros},
       
   794     map (fn thm => @{thm tendsto_eq_rhs} OF [thm]) o Tendsto_Intros.get o Context.proof_of);
       
   795 *}
   787 
   796 
   788 lemma tendsto_def: "(f ---> l) F \<longleftrightarrow> (\<forall>S. open S \<longrightarrow> l \<in> S \<longrightarrow> eventually (\<lambda>x. f x \<in> S) F)"
   797 lemma tendsto_def: "(f ---> l) F \<longleftrightarrow> (\<forall>S. open S \<longrightarrow> l \<in> S \<longrightarrow> eventually (\<lambda>x. f x \<in> S) F)"
   789   unfolding filterlim_def
   798   unfolding filterlim_def
   790 proof safe
   799 proof safe
   791   fix S assume "open S" "l \<in> S" "filtermap f F \<le> nhds l"
   800   fix S assume "open S" "l \<in> S" "filtermap f F \<le> nhds l"