# Are functions considered continuous at endpoints?

Consider a function $f(x)$ that has no jump, infinite, or removable discontinuities in the middle anywhere -- but maybe the domain is limited:

1. Would the endpoint $[a,$ be considered continuous?

2. What about the endpoint $(a,$?

I ask because I often see "a function is continuous if we can draw it without lifting up the pencil" but I didn't know to what extent this applies to the endpoints and whether or not it matters if the points themselves are defined.

• And what is the domain of function? – Mostafa Ayaz Jan 27 '18 at 22:37
• I gave two examples, one ending in $[a$ and one ending in $(a$ – user525456 Jan 27 '18 at 22:40
• If a does not belong to the domain of the function, then the function simply cannot be continuous at a – Mariano Suárez-Álvarez Jan 27 '18 at 22:45
• Let f(x)=sin(1/x). Continuous at x=0? – herb steinberg Jan 27 '18 at 22:49
• @herbsteinberg I don't know... I guess "no"? $0$ isn't part of the function's domain right? $(-\infty, 0) \cup (0, \infty)$ – user525456 Jan 27 '18 at 22:59

## 2 Answers

The function is continuous iff it is continuous at each point of the domain, so we need only consider points in the domain.

Hence, if the domain is of the form $(a,...$, the end point $a$ is of no concern since it is not part of the domain. For example, $f(x) = {1 \over x}$ is continuous on $(0,\infty)$. The point $0$ is not an issue since it is not part of the domain.

If the domain has the form $[a,...$ then if $f$ is continuous at $x=a$ then $f$ must have values close to $f(a)$ for $x$ close to $a$ (and in the domain). In particular, $f$ must be defined at $x=a$.

One characterization is for all sequences $x_n \to a$ (with $x_n$ in the domain) we must have $f(x_n) \to f(a)$. This is equivalent to drawing the curve without lifting.

Illustrations:

The function $f(x) = -1$ for $x \in [-1,0]$ and $f(x) = 1$ for $x \in (1,2]$, with domain $[-1,0] \cup (1,2]$ is continuous everywhere.

The function $f(x) = -1$ for $x \in [-1,0]$ and $f(x) = 1$ for $x \in (0,2]$, with domain $[-1,2]$ is continuous everywhere except at $x=0$.

The function that is $0$ everywhere except at $x=0$ where $f(0) = 1$ is continuous everywhere except at $x=0$.

• If the domain has a single point $a$, then the only sequence that converges to $a$ (and lies in the domain) is the sequence $a,a,a, ...$ so we see that the corresponding function values converge to $f(a)$ (in fact, they are all $f(a)$), so yes, the function is continuous at $a$. – copper.hat Jan 27 '18 at 23:26
• @user525456: Yes, it says that the limit exists and is equal to $f$ evaluated at that point. Look at the third example in my answer. – copper.hat Jan 27 '18 at 23:30
• @user525456: Well, roughly yes. The catch is that the domain may not be connected (in a topological sense). So, in my first illustration above, you can draw the function without lifting the pencil on either of $[-1,0]$ and $(1,2]$, but you can't 'jump' from one to the other. – copper.hat Jan 27 '18 at 23:37
• @user525456: Those functions would have different domains. – copper.hat Jan 27 '18 at 23:40
• @user525456: You may end up with an empty domain. For example, the function that is $0$ on the rationals and $1$ otherwise is discontinuous everywhere. (Even though continuity is referred to as elementary, there are a lot of weird examples out there.) – copper.hat Jan 27 '18 at 23:42

To answer this question, you need a better definition of continuity than "a function is continuous if we can draw it without lifting up the pencil." The definition that is usually the first rigorous definition that students see is

Let $D \subseteq \mathbb{R}$. A function $f : D \to \mathbb{R}$ is continuous at a point $a\in D$ if for all $\varepsilon > 0$ there exists a $\delta > 0$ such that if $x\in D$ and $|x-a| < \delta$, then $|f(x) - f(a)| < \varepsilon$.

Here, the notation $f : D\to\mathbb{R}$ says that $f$ is a function with domain $D$ and codomain $\mathbb{R}$ (the real numbers). In other words, $f$ takes real numbers from some set $D$ as input, and outputs other real numbers. The definition of the domain is quite important here, as it specifies what kinds of objects or numbers $f$ can work with.

Next, the definition of continuity basically says that you set an error tolerance $\varepsilon$, and always find a region around $a$ such that choosing any value of $x$ in that region ensures that the output will be within your error tolerance.

This definition says nothing about endpoints, and can be applied to such points as easily as any other, as long as they are in the domain of the function. In particular, this means that if you define a function an an interval $[a,b]$, then it could be continuous at either $a$ or $b$. On the other hand, if it is defined on $(a,b)$, then it cannot be continuous at either $a$ or $b$, as it is not defined there.

In either case, a function is continuous on its domain if it is continuous at every point in the domain. Thus a function can be continuous on either $[a,b]$ or $(a,b)$. In the former case the function would necessarily be continuous at $a$ and $b$ (if it is continuous on its domain), and in the latter case $f$ would not be continuous at either $a$ or $b$ as it is not even defined there.

• What is $f : \mathbb{R} \to \mathbb{R}$? A function that accepts reals and outputs reals? – user525456 Jan 27 '18 at 22:57
• This says that $f$ is a function with domain and codomain $\mathbb{R}$ (the real numbers). – Xander Henderson Jan 27 '18 at 22:58
• But overall isn't the $(\epsilon, \delta)$ stuff more the definition for a two-sided limit, as opposed to the one-sided limits we might see at endpoints? – user525456 Jan 27 '18 at 23:03
• Nope. For a one sided limit, you would need the additional hypothesis that $x<a$ or $x>a$. For example, for the right-hand limit, we would have to find $\delta > 0$ such that for all $x\in D$ with $|x-a|<\delta$ and $x > a$, then $|f(x)-f(a)|<\varepsilon$. – Xander Henderson Jan 27 '18 at 23:03
• I'm confused now, since I thought you couldn't have two-sided limits at endpoints, but this definition in the answer appears to be for two-sided limits. But we still define a function as continuous on its domain even at endpoints if we have $[a, b]$ but not $(a, b)$? – user525456 Jan 27 '18 at 23:07