I have a question with regards to the use of an open interval in the following theorem:
Theorem:
Let $f, g, h$ be defined on an open interval $I$ and let $a \in I$. If
- $g(x) \le f(x) \le h(x)$ for $x \in I$,
- $g(a) = f(a) = h(a)$
- $g, h$ are continuous at $a$
… then $f$ is also continuous at $a$.
Proof:
- We want to show that for each sequence $(x_n)$ in the domain of $f$ such that $x_n \rightarrow a$, we have $f(x_n) \rightarrow f(a)$.
- Since $x_n \rightarrow a$ and $I$ is an open interval, there is an integer $N$ such that $x_n \in I$, for $n > N$.
Hence by condition 1., $g(x_n) \le f(x_n) \le h(x_n)$ for $n > N$.…
[ Rest of the proof omitted. ]
I understand the rest of the proof, which is basically an application of the Squeeze Theorem of convergent sequences.
- I was wondering why we use an open interval $I$?
- Also, I understand that we pick a sequence $(x_n)$ from the domain of $f$ which tends to $a$. To use this sequence, we also need to make sure the sequence is included in $I$. In the proof they say:
- Since $x_n \rightarrow a$ and $I$ is an open interval, there is an integer $N$ such that $x_n \in I$, for $n > N$.
I get that we show eventually $(x_n)$ will be in $I$, but how is this justified by $I$ being an open interval?
- Lastly, can we always make sure to find a sequence $(x_n)$ in the domain of $f$ which has limit $a$ and fits into an open interval?
Best Answer
The theorem works because $g \le f \le h$ is true for all points in some neighborhood of $a$ (a set of points that includes everything close to $a$ for some level of closeness). On the real line, any neighborhood of a point contains on open interval around that point. Thus the theorem works because $g \le f \le h$ on some open interval containing $a$.
This is not true for closed intervals containing $a$, since then $a$ could be an end point of the interval, and we are not guaranteed that $g\le f\le h$ on the other side. For example $$g(x) = 0\\h(x) = |x|\\f(x) = \begin{cases}1& x< 0\\0 & x \ge 0\end{cases}$$ $g \le f \le h$ on the closed interval $[0,1]$ and $g(0) = f(0) = h(0)$, but $g$ and $h$ are continuous at $0$ while $f$ is not.
That said, if the domain of $f$ lies entirely on one side of $a$, Then it is sufficient that the interval (which must contain $a$) be half-open, or even closed provided it isn't $[a,a]$ for the result to follow. This is because continuity is defined in terms of the domain.