@@ -11,17 +11,14 @@ import order.filter
11
11
12
12
The main definition is the type class `topological space α` which endows a type `α` with a topology.
13
13
Then `set α` gets predicates `is_open`, `is_closed` and functions `interior`, `closure` and
14
- `frontier`. Each point `x` of `α` gets a neighborhood filter `nhds x`, and relative versions
15
- `nhds_within x s` for every set `s` in `α`.
14
+ `frontier`. Each point `x` of `α` gets a neighborhood filter `nhds x`.
16
15
17
16
This file also defines locally finite families of subsets of `α`.
18
17
19
18
For topological spaces `α` and `β`, a function `f : α → β` and a point `a : α`,
20
19
`continuous_at f a` means `f` is continuous at `a`, and global continuity is
21
- `continuous f`. There are also relative versions `continuous_within_at` and `continuous_on`
22
- and continuity `pcontinuous` for partially defined functions. Some basic properties
23
- of these various notions of continuity are proved in `topology.order`, after the
24
- ordering on topologies has been established.
20
+ `continuous f`. There is also a version of continuity `pcontinuous` for
21
+ partially defined functions.
25
22
26
23
## Implementation notes
27
24
@@ -549,129 +546,6 @@ noncomputable def lim (f : filter α) : α := epsilon $ λa, f ≤ nhds a
549
546
lemma lim_spec {f : filter α} (h : ∃a, f ≤ nhds a) : f ≤ nhds (lim f) := epsilon_spec h
550
547
end lim
551
548
552
- /-- The "neighborhood within" filter. Elements of `nhds_within a s` are sets containing the
553
- intersection of `s` and a neighborhood of `a`. -/
554
- def nhds_within (a : α) (s : set α) : filter α := nhds a ⊓ principal s
555
-
556
- theorem nhds_within_eq (a : α) (s : set α) :
557
- nhds_within a s = ⨅ t ∈ {t : set α | a ∈ t ∧ is_open t}, principal (t ∩ s) :=
558
- have set.univ ∈ {s : set α | a ∈ s ∧ is_open s}, from ⟨set.mem_univ _, is_open_univ⟩,
559
- begin
560
- rw [nhds_within, nhds, lattice.binfi_inf]; try { exact this },
561
- simp only [inf_principal]
562
- end
563
-
564
- theorem nhds_within_univ (a : α) : nhds_within a set.univ = nhds a :=
565
- by rw [nhds_within, principal_univ, lattice.inf_top_eq]
566
-
567
- theorem mem_nhds_within (t : set α) (a : α) (s : set α) :
568
- t ∈ nhds_within a s ↔ ∃ u, is_open u ∧ a ∈ u ∧ u ∩ s ⊆ t :=
569
- begin
570
- rw [nhds_within, mem_inf_principal, mem_nhds_sets_iff], split,
571
- { rintros ⟨u, hu, openu, au⟩,
572
- exact ⟨u, openu, au, λ x ⟨xu, xs⟩, hu xu xs⟩ },
573
- rintros ⟨u, openu, au, hu⟩,
574
- exact ⟨u, λ x xu xs, hu ⟨xu, xs⟩, openu, au⟩
575
- end
576
-
577
- theorem self_mem_nhds_within {a : α} {s : set α} : s ∈ nhds_within a s :=
578
- begin
579
- rw [nhds_within, mem_inf_principal],
580
- simp only [imp_self],
581
- exact univ_mem_sets
582
- end
583
-
584
- theorem inter_mem_nhds_within (s : set α) {t : set α} {a : α} (h : t ∈ nhds a) :
585
- s ∩ t ∈ nhds_within a s :=
586
- inter_mem_sets (mem_inf_sets_of_right (mem_principal_self s)) (mem_inf_sets_of_left h)
587
-
588
- theorem nhds_within_mono (a : α) {s t : set α} (h : s ⊆ t) : nhds_within a s ≤ nhds_within a t :=
589
- lattice.inf_le_inf (le_refl _) (principal_mono.mpr h)
590
-
591
- theorem nhds_within_restrict'' {a : α} (s : set α) {t : set α} (h : t ∈ nhds_within a s) :
592
- nhds_within a s = nhds_within a (s ∩ t) :=
593
- le_antisymm
594
- (lattice.le_inf lattice.inf_le_left (le_principal_iff.mpr (inter_mem_sets self_mem_nhds_within h)))
595
- (lattice.inf_le_inf (le_refl _) (principal_mono.mpr (set.inter_subset_left _ _)))
596
-
597
- theorem nhds_within_restrict' {a : α} (s : set α) {t : set α} (h : t ∈ nhds a) :
598
- nhds_within a s = nhds_within a (s ∩ t) :=
599
- nhds_within_restrict'' s $ mem_inf_sets_of_left h
600
-
601
- theorem nhds_within_restrict {a : α} (s : set α) {t : set α} (h₀ : a ∈ t) (h₁ : is_open t) :
602
- nhds_within a s = nhds_within a (s ∩ t) :=
603
- nhds_within_restrict' s (mem_nhds_sets h₁ h₀)
604
-
605
- theorem nhds_within_le_of_mem {a : α} {s t : set α} (h : s ∈ nhds_within a t) :
606
- nhds_within a t ≤ nhds_within a s :=
607
- begin
608
- rcases (mem_nhds_within _ _ _).1 h with ⟨u, u_open, au, uts⟩,
609
- have : nhds_within a t = nhds_within a (t ∩ u) := nhds_within_restrict _ au u_open,
610
- rw [this , inter_comm],
611
- exact nhds_within_mono _ uts
612
- end
613
-
614
- theorem nhds_within_eq_nhds_within {a : α} {s t u : set α}
615
- (h₀ : a ∈ s) (h₁ : is_open s) (h₂ : t ∩ s = u ∩ s) :
616
- nhds_within a t = nhds_within a u :=
617
- by rw [nhds_within_restrict t h₀ h₁, nhds_within_restrict u h₀ h₁, h₂]
618
-
619
- theorem nhds_within_eq_of_open {a : α} {s : set α} (h₀ : a ∈ s) (h₁ : is_open s) :
620
- nhds_within a s = nhds a :=
621
- by rw [←nhds_within_univ]; apply nhds_within_eq_nhds_within h₀ h₁;
622
- rw [set.univ_inter, set.inter_self]
623
-
624
- @[simp] theorem nhds_within_empty (a : α) : nhds_within a {} = ⊥ :=
625
- by rw [nhds_within, principal_empty, lattice.inf_bot_eq]
626
-
627
- theorem nhds_within_union (a : α) (s t : set α) :
628
- nhds_within a (s ∪ t) = nhds_within a s ⊔ nhds_within a t :=
629
- by unfold nhds_within; rw [←lattice.inf_sup_left, sup_principal]
630
-
631
- theorem nhds_within_inter (a : α) (s t : set α) :
632
- nhds_within a (s ∩ t) = nhds_within a s ⊓ nhds_within a t :=
633
- by unfold nhds_within; rw [lattice.inf_left_comm, lattice.inf_assoc, inf_principal,
634
- ←lattice.inf_assoc, lattice.inf_idem]
635
-
636
- theorem nhds_within_inter' (a : α) (s t : set α) :
637
- nhds_within a (s ∩ t) = (nhds_within a s) ⊓ principal t :=
638
- by { unfold nhds_within, rw [←inf_principal, lattice.inf_assoc] }
639
-
640
- theorem tendsto_if_nhds_within {f g : α → β} {p : α → Prop } [decidable_pred p]
641
- {a : α} {s : set α} {l : filter β}
642
- (h₀ : tendsto f (nhds_within a (s ∩ p)) l)
643
- (h₁ : tendsto g (nhds_within a (s ∩ {x | ¬ p x})) l) :
644
- tendsto (λ x, if p x then f x else g x) (nhds_within a s) l :=
645
- by apply tendsto_if; rw [←nhds_within_inter']; assumption
646
-
647
- lemma map_nhds_within (f : α → β) (a : α) (s : set α) :
648
- map f (nhds_within a s) =
649
- ⨅ t ∈ {t : set α | a ∈ t ∧ is_open t}, principal (set.image f (t ∩ s)) :=
650
- have h₀ : directed_on ((λ (i : set α), principal (i ∩ s)) ⁻¹'o ge)
651
- {x : set α | x ∈ {t : set α | a ∈ t ∧ is_open t}}, from
652
- assume x ⟨ax, openx⟩ y ⟨ay, openy⟩,
653
- ⟨x ∩ y, ⟨⟨ax, ay⟩, is_open_inter openx openy⟩,
654
- le_principal_iff.mpr (set.inter_subset_inter_left _ (set.inter_subset_left _ _)),
655
- le_principal_iff.mpr (set.inter_subset_inter_left _ (set.inter_subset_right _ _))⟩,
656
- have h₁ : ∃ (i : set α), i ∈ {t : set α | a ∈ t ∧ is_open t},
657
- from ⟨set.univ, set.mem_univ _, is_open_univ⟩,
658
- by { rw [nhds_within_eq, map_binfi_eq h₀ h₁], simp only [map_principal] }
659
-
660
- theorem tendsto_nhds_within_mono_left {f : α → β} {a : α}
661
- {s t : set α} {l : filter β} (hst : s ⊆ t) (h : tendsto f (nhds_within a t) l) :
662
- tendsto f (nhds_within a s) l :=
663
- tendsto_le_left (nhds_within_mono a hst) h
664
-
665
- theorem tendsto_nhds_within_mono_right {f : β → α} {l : filter β}
666
- {a : α} {s t : set α} (hst : s ⊆ t) (h : tendsto f l (nhds_within a s)) :
667
- tendsto f l (nhds_within a t) :=
668
- tendsto_le_right (nhds_within_mono a hst) h
669
-
670
- theorem tendsto_nhds_within_of_tendsto_nhds {f : α → β} {a : α}
671
- {s : set α} {l : filter β} (h : tendsto f (nhds a) l) :
672
- tendsto f (nhds_within a s) l :=
673
- by rw [←nhds_within_univ] at h; exact tendsto_nhds_within_mono_left (set.subset_univ _) h
674
-
675
549
676
550
/- locally finite family [General Topology (Bourbaki, 1995)] -/
677
551
section locally_finite
@@ -731,14 +605,9 @@ def continuous (f : α → β) := ∀s, is_open s → is_open (f ⁻¹' s)
731
605
if `f x` tends to `f x₀` when `x` tends to `x₀`. -/
732
606
def continuous_at (f : α → β) (x : α) := tendsto f (nhds x) (nhds (f x))
733
607
734
- /-- A function between topological spaces is continuous at a point `x₀` within a subset `s`
735
- if `f x` tends to `f x₀` when `x` tends to `x₀` while staying within `s`. -/
736
- def continuous_within_at (f : α → β) (s : set α) (x : α) : Prop :=
737
- tendsto f (nhds_within x s) (nhds (f x))
738
-
739
- /-- A function between topological spaces is continuous on a subset `s`
740
- when it's continuous at every point of `s` within `s`. -/
741
- def continuous_on (f : α → β) (s : set α) : Prop := ∀ x ∈ s, continuous_within_at f s x
608
+ lemma continuous_at.preimage_mem_nhds {f : α → β} {x : α} {t : set β} (h : continuous_at f x)
609
+ (ht : t ∈ nhds (f x)) : f ⁻¹' t ∈ nhds x :=
610
+ h ht
742
611
743
612
lemma continuous_id : continuous (id : α → α) :=
744
613
assume s h, h
@@ -747,13 +616,22 @@ lemma continuous.comp {g : β → γ} {f : α → β} (hg : continuous g) (hf :
747
616
continuous (g ∘ f) :=
748
617
assume s h, hf _ (hg s h)
749
618
619
+ lemma continuous_at.comp {g : β → γ} {f : α → β} {x : α}
620
+ (hg : continuous_at g (f x)) (hf : continuous_at f x) :
621
+ continuous_at (g ∘ f) x :=
622
+ hg.comp hf
623
+
750
624
lemma continuous.tendsto {f : α → β} (hf : continuous f) (x) :
751
625
tendsto f (nhds x) (nhds (f x)) | s :=
752
626
show s ∈ nhds (f x) → s ∈ map f (nhds x),
753
627
by simp [nhds_sets]; exact
754
628
assume t t_subset t_open fx_in_t,
755
629
⟨f ⁻¹' t, preimage_mono t_subset, hf t t_open, fx_in_t⟩
756
630
631
+ lemma continuous.continuous_at {f : α → β} {x : α} (h : continuous f) :
632
+ continuous_at f x :=
633
+ h.tendsto x
634
+
757
635
lemma continuous_iff_continuous_at {f : α → β} : continuous f ↔ ∀ x, continuous_at f x :=
758
636
⟨continuous.tendsto,
759
637
assume hf : ∀x, tendsto f (nhds x) (nhds (f x)),
0 commit comments