Definitions of Continuity and Discontinuity

 

Consider a function \(f\) whose graph is shown in the following figure. We can intuitively say that \(f\) is discontinuous at \(x=-3,-1,3\), and \(5\) and is continuous at any other points; we don’t have to lift the pen to draw the graph of \(f\) except when \(x=-3,-1,3,5\).

Figure 1: The function \(f\) is not continuous at \(x=-3,-1,3\) and \(5\).

 

Read more detail about the above example

  • The function is discontinuous at \(x=-3\) because it is not defined there.

  • The function has a jump discontinuity at \(x=-1\); the left-hand limit is not equal to the right-hand limit. Because \(\lim_{x\to-1^{-}}f(x)=f(-1)\), we say the function is continuous from the left.

  • The function is not continuous at \(x=3\) because \(f(3)\) is not equal to the limit of the function as \(x\to3\). \[\lim_{x\to3}f(x)=-1\neq f(3)=5\]

  • The function is discontinuous at \(x=5\) because \[\lim_{x\to5^{-}}f(x)=3\neq f(5)=1.\] However, we intuitively say the function continuous at \(x=-5\) because \[\lim_{x\to-5^{+}}f(x)=f(5)=1.\] Because \(x=\pm5\) are endpoints of the domain of \(f\), only one-sided limits exist.

 

Here is the formal definition of continuity.

Definition 1: The function \(f\) is continuous at \(a\) if \[\lim_{x\to a}f(x)=f(a)\]

It follows from the above definition that when the function \(f\) is continuous at \(a\) then

  1. \(f\) is defined at \(a\).
  2. \(\lim_{x\to a}f(x)\) exits (which requires that \(f\) to be defined on some open interval containing \(a\)).
  3. \(\lim_{x\to a}f(x)=f(a)\)
  • When \(f\) is not continuous at \(a\) we say \(f\) is discontinuous at \(a\) or has a discontinuity at \(a\).

 

Left and Right Continuities

 

In a similar fashion, we can define left and right continuities.

Definition 2: The function \(f\) is left-continuous at \(a\) (or continuous from the left) if \[\lim_{x\to a^{-}}f(x)=f(a)\] The function is right-continuous at \(a\) (or continuous from the right) if \[\lim_{x\to a^{+}}f(x)=f(a).\]

  • It follows from the definitions that the function \(f\) is continuous at \(x=a\) if and only if it is left-continuous and right-continuous at the point \(a\).

 

Continuity on an Interval

 

  • If a function is continuous at every \(x\) in an open interval \((a,b)\), we say it is continuous over \((a,b)\).
  • We say a function is continuous over a closed interval \([a,b]\) if it is continuous over the open interval \((a,b)\) and is left-continuous at \(a\) and right-continuous at \(b\).
Example 1
Show that \(f(x)=3-\sqrt{4-x^{2}}\) is continuous on \([-2,2]\).

Solution

For \(-2<a<2\), we have

\[\begin{aligned}
\lim_{x\to a}f(x) & =\lim_{x\to a}(3-\sqrt{4-x^{2}})\\
& =\lim_{x\to a}3-\lim_{x\to a}\sqrt{4-x^{2}} & {\small(\text{by Difference Rule in Sec. 4.4)}}\\
& =3-\sqrt{\lim_{x\to a}(4-x^{2})} & {\small( \text{by Root Rule})}\\
& =3-\sqrt{4-a^{2}}& {\small ((4-x^2) \text{ is a Polynomial})}\\
& =f(a)
\end{aligned}\]

Similarly, we can show \[\lim_{x\to-2^{+}}f(x)=3=f(-2),\quad\lim_{x\to2^{-}}f(x)=3=f(2)\] The graph of \(f\) is shown in the following figure.

Figure 2

 

Types of Discontinuity

1. Removable Discontinuity

 

We say that \(f\) has a removable discontinuity at \(x=a\) if \[\lim_{x\to a}f(x)=L,\] and either \(f\) is not defined at \(a\) or \(f(a)\neq L\). We can make \(f(x)\) continuous at \(x=a\), if \(L\) is assumed as the value of \(f(a).\)

Read More on Removable Discontinuity

For example, the function \[f(x)=\frac{x^{2}-4}{x-2}\] is not defined for \(x=2\) (because there would be division by zero), but for every other value of \(x\), \[f(x)=\frac{(x-2)(x+2)}{x-2}=x+2.\] Because \[\lim_{x\to2}(x+2)=4,\] we obtain \[\lim_{x\to2}\frac{x^{2}-4}{x-2}=4.\] Although the function is not defined when \(x=2\), if we arbitrarily assign \(f(x)\) the value 4 when \(x=2\) (that is, \(f(2)=4\)), then it becomes continuous at \(x=2\) (see Figure 3).

(a) $f(x)=\frac{x^{2}-4}{x-2}$ is discontinuous at $x=2$ (b) The discontinuity of $f$ at $x=2$ is removed if we define $f(x)=\begin{cases} \frac{x^{2}-4}{x-2} & x\neq2\\ 4 & x=2 \end{cases}$.

Figure 3

2. Jump Discontinuity

We say \(f\) has a jump discontinuity at \(x=a\) if the right and left limits exist but have different values \[\lim_{x\to a^{-}}f(x)\neq\lim_{x\to a^{+}}f(x).\]

Read More on Jump Discontinuity

For example, the Heaviside step function \(H(x)\) is defined as \[H(x)=\begin{cases} 1 & \text{if }x\geq0\\ 0 & \text{if }x<0 \end{cases}\] This function has a jump discontinuity at \(x=0\) because \[\lim_{x\to0^{-}}H(x)=0\neq\lim_{x\to0^{+}}H(x)=1.\] We note that \(H(x)\) is right continuous at \(x=0\) because \(H(0)=\lim_{x\to0^{+}}H(x)=1\). (See Figure 4).

Figure 4: Graph of \(H(x)=\begin{cases} 1 & \text{if }x\geq0\\ 0 & \text{if }x<0 \end{cases}\)

The greatest integer function (also known as the floor function) \(y=\left\lfloor x\right\rfloor\) (or $y=[\![ x]\!]$) has a jump discontinuity at every integer (see Figure 5). For example, \[\lim_{x\to2^{-}}\left\lfloor x\right\rfloor =1\neq\lim_{x\to2^{+}}\left\lfloor x\right\rfloor =2.\]

Figure 5: Graph of \(y=\left\lfloor x\right\rfloor\)

 

3. Infinite Discontinuity

We say \(f\) has an infinite discontinuity at \(x=a\) if one of the one-sided limits or both of them are plus or minus infinity.

Read More on Infinite Discontinuity

For example, \(f(x)=1/x^{2}\) has an infinite discontinuity at \(x=0\) (See Figure 6). Note that we can choose a value for \(f(0)\) but we cannot make it continuous at \(x=0\) because \(\lim_{x\to0}f(x)=\infty\) and \(\infty\) is not a number to assign it to \(f(0)\).

Figure 6: Graph of \(f(x)=\dfrac{1}{x^{2}}\).

4. Oscillating Discontinuity

Read More on Oscillating Discontinuity

For example, \(f(x)=\sin\left(\frac{1}{x}\right)\) oscillates between \(-1\) and \(1\) infinitely often as \(x\to0\) (See the following figure). Because this function does not approach a single number, it does not have a limit as \(x\to0\).

Figure 7: Graph of \(f(x)=\sin\left(\dfrac{1}{x}\right)\).

A function that is discontinuous at every point of its domain

Consider the Dirichlet function defined as \[D(x)=\begin{cases} 1 & \text{if }x\text{ is rational}\\ 0 & \text{if }x\text{ is irrational} \end{cases}\] This function is discontinuous at every point; \(D(x)\) fails to have a limit at any point.

Suppose \(D(x)\) has a limit \(L\) at a point \(a\). Suppose \(\epsilon=1/2\) is given, we should be able to find a \(\delta>0\) such that \[0<|x-a|<\delta\implies|D(x)-L|<\frac{1}{2}\] Because each deleted neighborhood \(0<|x-a|<\delta\) contains a rational point \(x_{1}\) and irrational point \(x_{2}\), we should have \[|D(x_{1})-L|=|1-L|<\frac{1}{2}\] and \[|D(x_{2})-L|=|0-L|<\frac{1}{2}\] and hence \[{\small 1=|D(x_{1})-L-(D(x_{2})-L)|\leq|D(x_{1})-L|+|D(x_{2})-L|<\frac{1}{2}+\frac{1}{2}}\] Because this is impossible, \(D(x)\) cannot have a limit.

For a type of discontinuity that is different from all the above see Example 4.

Elementary Continuous Functions

Here are some elementary continuous functions

  1. Power functions. \(y=x^{n}\) where \(n\) is a positive integer is continuous everywhere.

  2. Polynomials are continuous everywhere, because for any \(a\), \(\lim_{x\to a}P(x)=P(a)\)

  3. Rational functions. Let \(P(x)\)and \(Q(x)\) be two polynomials and \(Q(a)\neq0\). Then the rational function \[R(x)=\frac{P(x)}{Q(x)}\] is continuous at \(x=a\). In other words, a rational function is continuous on their domains and is discontinuous at the points where the denominator is zero.

  4. Root functions (1). \(y=\sqrt[n]{x}\) where \(n\) is a positive odd integer is continuous everywhere.

  5. Root functions (2). \(y=\sqrt[n]{x}\) where \(n\) is a positive even integer is continuous on its domain \([0,\infty)\).

  6. The sine and cosine functions are continuous on \(\mathbb{R}=(-\infty,\infty)\).
    Figure 8: $y=\sin x$ and $y=\cos x$ are continuous everywhere.
  7. The tangent, cotangent, secant and cosecant functions are continuous where they are defined; that is, on their domains. Specifically \(y=\tan x\) is continuous everywhere except where \(\cos x=0\); that is when \(x=\frac{\pi}{2}+k\pi\) for all integers \(k\). Thus \(y=\tan x\) is continuous on \[\left\{ x\Big|\ x\neq\frac{\pi}{2}+k\pi,\quad k\in\mathbb{Z}\right\}\]

    Figure 9: \(y=\tan x\) is continuous on its domain

    The graphs of the rest of trigonometric functions are illustrated in Figure . The domains of these functions are apparent from their graphs.

    (a) \(y=\cot x\) (b) \(y=\sec x\) (c) \(y=\text{csc}x\)

    Figure 10

  8. Inverse trigonometric functions are continuous on their domains. For example, \(y=\arcsin x\) and \(y=\arccos x\) are continuous on \([-1,1]\)and \(y=\arctan x\) is continuous on \(\mathbb{R}=(-\infty,\infty)\).

  9. Exponential functions. \(y=e^{x}\) is continuous on its domain \(\mathbb{R}=(-\infty,\infty)\).

  10. Logarithmic functions. \(y=\ln x\) is continuous on its domain \((0,\infty)\).

In fact, most of the functions that we deal with in this course are continuous on their domains. Some exceptions are:

  1. The greatest integer function (also known as the floor function) \(f(x)=\left\lfloor x\right\rfloor\) (or $y=[\![x]\!]$) which is discontinuous at every integer (although it is defined everywhere).

    Graph of \(y=\left\lfloor x\right\rfloor\)

  2. Piece-wise defined functions are not necessarily continuous on their domains. For example, \[y=|x|=\begin{cases} x & \text{if }x\ge0\\ -x & \text{if }x<0 \end{cases}\] is continuous everywhere but the sign function \(y=\text{sgn}(x)\) and the Heaviside step function \(y=H(x)\) are continuous everywhere except when \(x=0\). \[\text{sgn}(x)=\begin{cases} 1 & \text{if }x>0\\ 0 & \text{if }x=0\\ -1 & \text{if }x<0 \end{cases}\] \[H(x)=\begin{cases} 1 & \text{if }x\geq0\\ 0 & \text{if }x<0 \end{cases}\] [The Heaviside step function is right-continuous at \(x=0\)]

    (a) \(y=|x|\) is continuous everywhere (b) \(y=\text{sgn}(x)\) is discontinuous at \(x=0\) (c) \(y=H(x)\) is discontinuous at \(x=0\)

    Figure 11

Example 2

Let \[f(x)=\begin{cases} x^{2}+3 & \text{if }x\geq3\\ mx+5 & \text{if }x<3 \end{cases}\]

For what value of the constant \(m\) is the function\(f\) continuous at \(x=3\)?

Solution

The function\(f\) is right-continuous at \(x=3\): \[\begin{aligned} \lim_{x\to3^{+}}f(x) & =\lim_{x\to3^{+}}(x^{2}+3)\\ & =3^{2}+3=12\\ & =f(3).\end{aligned}\] Therefore, \(f\) must be left-continuous at \(x=3\) to be continuous at \(x=3\). That is, we must have \(\lim_{x\to3^{-}}f(x)=f(3)\) or \[\lim_{x\to3^{-}}(mx+5)=3m+5=12\] or \[m=\frac{7}{3}.\]

Example 3

For what values of \(x\) is there a discontinuity in the graph of \[f(x)=\frac{x^{2}-4}{x^{2}-3x+2}?\]

Solution

\(f\) is a rational function, so it is discontinuous at the points where the denominator \(x^{2}-3x+2\) is zero: \[x^{2}-3x+2=0\Rightarrow x=\frac{3\pm\sqrt{3^{2}-4(2)}}{2(1)}\] [Recall that if \(ax^{2}+bx+c=0\), then \(x=\left(-b\pm\sqrt{b^{2}-4ac}\right)/(2a)\)] \[\Rightarrow x=2\ \text{or}\ x=1\] Therefore, \(f\) is discontinuous at \(x=1\) and \(x=2\). However, \(f\) has a removable discontinuity at \(x=2\), because \[\frac{x^{2}-4}{x^{2}-3x+2}=\frac{(x-2)(x+2)}{(x-1)(x-2)}=\frac{x+2}{x-1}\quad(\text{if }x\neq2).\] [Recall that \(A^{2}-B^{2}=(A-B)(A+B)\)], and \[\lim_{x\to2}f(x)=\lim_{x\to2}\frac{x+2}{x-1}=4.\] That is, if we define a new function \[g(x)=\begin{cases} \frac{x^{2}-4}{x^{2}-3x+2} & \text{if }x\neq2\\ 4 & \text{if }x=2 \end{cases}\] then \(g\) is continuous at \(x=2\), and its graph does not have a hole when \(x=2\) (compare with the graph of \(f\) shown in the following figure.

Figure 12: Graph of \(f(x)=\frac{x^{2}-4}{x^{2}-3x+2}\).

Example 4
Is $f(x)=\sqrt{(x-1)^2(x-2)}$ continuous on its domain?

Solution

First, let’s determine the domain of $f$:

\large x \(-\infty\)   \(1\)   \(2\)   \(\infty\)
sign of \((x-1)^2\)   + + + + 0 + + + + + + + + +  
sign of \((x-2)\)   – – – – – – – – $0$ + + + +  
\(\therefore\) sign of \((x-1)^2(x-2)\)   – – – – $0$ – – – – $0$ + + + +  

 

Because $(x-1)^2(x-2)\geq 0$ when $x=1$ or $x\geq 2$, the domain of $f$ is \[Dom(f)=\{1\}\cup[2,+\infty).\]

We can consider an open interval containing $x=1$ (for example, the interval $(-0.5,1.5)$) on which the domain of $f$ contains no point other than $x=1$. Therefore, $\lim_{x\to 1} f(x)$ does not exist, and $f$ is not continuous at $x=1$.  Because $f$ is discontinuous at $x=1$, it is not continuous on its entire domain.

The function is continuous on $(2,+\infty)$, because for every $a\in(2,+\infty)$:

\[\lim_{x\to a}\sqrt{(x-1)^2(x-2)}=\sqrt{\lim_{x\to a}\left[(x-1)^2(x-2)\right]}=\sqrt{(a-1)^2(a-2)}=f(a).\]

The function $f$ is left continuous at $x=2$, because 

\[\lim_{x\to 2^+}\sqrt{(x-1)^2(x-2)}=0=f(2)\]

Therefore, $f$ is continuous on $[2,+\infty)$. 

The graph of $f$ is shown in Figure 13. The discontinuity of $f$ at $x=1$ is subtle and none of the four cases that we studied before. 

Figure 13

Algebraic Operations on Continuous Functions

Theorem 1: If the functions \(f\) and \(g\) are continuous at \(x=a\), and \(k\) is a number then the following functions are continuous at \(x=a\):
1. Sum \[f(x)+g(x)\] 2. Difference \[f(x)-g(x)\] 3. Constant Multiple \[kf(x)\] 4. Product \[f(x)g(x)\] 5. Quotient \[\frac{f(x)}{g(x)}\qquad\text{provided }g(a)\neq0\] 6. Power \[\left(f(x)\right)^{n}\qquad n\text{ is a positive integer}\]

The results of the above theorem follow from the corresponding Limit Laws. For instance, to prove the sum property we have \[\begin{aligned} \lim_{x\to a}(f(x)+g(x)) & =\lim_{x\to a}f(x)+\lim_{x\to a}g(x)\\ & =f(a)+g(a)\end{aligned}\]

Continuity of Composite Functions

Theorem 2: If \(\lim_{x\to a}g(x)=b\) and \(f\) is continuous at the point \(b\), then \[\begin{aligned} \lim_{x\to a}f(g(x)) & =f(\lim_{x\to a}g(x))\\ & =f(b).\end{aligned}\]

Intuitively, the above theorem is plausible because \(\lim_{x\to a}g(x)=b\) means that when \(x\) is close to \(a\), \(g(x)\) is close to \(b\) and the continuity of \(f\)at the point \(b\) means that if the input (which is here \(g(x)\)) is close to \(b\), the output (which is here \(f(g(x))\)) is close to \(f(b)\).


Show the rigorous proof

The mathematically rigorous proof is as follows. Let \(\epsilon>0\) be given. We need to find a number \(\delta>0\) such that for all \(x\) \[0<|x-a|<\delta\Rightarrow\left|f(g(x))-f(b)\right|<\epsilon.\] Because \(f\) is continuous at \(b\), we have \[\lim_{y\to b}f(y)=f(b)\] and therefore, there exists a number \(\delta_{1}>0\) such that for all \(y\) \[|y-b|<\delta_{1}\Rightarrow|f(y)-f(b)|<\epsilon\] [Because \(f\) is continuous, we did not exclude \(y=b\) and wrote \(|y-b|<\delta_{1}\) instead of \(0<|y-b|<\delta_{1}\)].
Because \(\lim_{x\to a}g(x)=b\), there exists a \(\delta>0\) such that for all \(x\) \[0<|x-a|<\delta\Rightarrow|g(x)-b|<\delta_{1}\] If we let \(y=g(x)\), we can combine these two statements: For all \(x\) if \(0<|x-a|<\delta\) then \(|g(x)-b|<\delta_{1}\) which implies that \(\left|f(g(x))-f(b)\right|<\epsilon\). From the definition of limit, it follows that \[\lim_{x\to a}f(g(x))=f(b).\]


  • The theorem holds when \(a\) is an endpoint of the domain, provided we use an appropriate one-sided limit in place of a two-sided one.

Proof of the Root Rule from Sec. 4.4

We can use Theorem 2 to prove Theorem 5 from Section 4.4. Let assume \(\lim_{x\to a}g(x)\) and the indicated \(n\)th roots exist. Let \(f(x)=\sqrt[n]{x}\). In Section 4.4, we discussed that (see Theorem 4) \[\lim_{x\to a}f(x)=\lim_{x\to a}\sqrt[n]{x}=\sqrt[n]{a}\] That is, \(f(x)\) is continuous on its domain. Applying Theorem 2 which states that \[\lim_{x\to a}f(g(x))=f\left(\lim_{x\to a}g(x)\right)\] we obtain \[\lim_{x\to a}\sqrt[n]{g(x)}=\sqrt[n]{\lim_{x\to a}g(x)}.\]

Example 5

Evaluate the following limits
(a) \({\displaystyle \lim_{x\to-3}\sin\left(\frac{x+3}{x^{2}+3x}\right)}\)
(b) \({\displaystyle \lim_{x\to1}\arctan\left(x+\cos\left(\frac{\pi}{2}x\right)\right)}\)
(c) \({\displaystyle \lim_{x\to0}\ln\left(1+e^{\tan x}\right)}\)

Solution

(a) Because \(y=\sin x\) is a continuous function everywhere, by Theorem 2 we have \[\lim_{x\to-3}\sin\left(\frac{x+3}{x^{2}+3x}\right)=\sin\left(\lim_{x\to-3}\frac{x+3}{x^{2}+3x}\right)\] If we substitute \(x=-3\) in \((x+3)/(x^{2}+3x)\) we get \(0/0\), which shows the numerator and the denominator have a common factor: \[\frac{x+3}{x^{2}+3x}=\frac{x+3}{x(x+3)}=\frac{1}{x}\qquad(x\neq-3)\] Therefore, \[\begin{aligned} \sin\left(\lim_{x\to-3}\frac{x+3}{x^{2}+3x}\right) & =\sin\left(\lim_{x\to-3}\frac{\cancel{x+3}}{x\cancel{(x+3)}}\right)\\ & =\sin\left(\lim_{x\to-3}\frac{1}{x}\right)\\ & =\sin\left(\frac{1}{-3}\right)\\ & =\sin\left(\frac{-1}{3}\right)\approx-0.3272.\end{aligned}\]

(b) Because \(y=\arctan x\) is a continuous function, we have \[\begin{aligned} \lim_{x\to1}\arctan\left(x+\cos\left(\frac{\pi}{2}x\right)\right) & =\arctan\left(\lim_{x\to1}\left(x+\cos\left(\frac{\pi}{2}x\right)\right)\right)\\ & =\arctan\left(\lim_{x\to1}x+\lim_{x\to1}\cos\left(\frac{\pi}{2}x\right)\right)\end{aligned}\] and again because \(y=\cos x\) is a continuous function, we have \[\begin{aligned} \arctan\left(\lim_{x\to1}x+\lim_{x\to1}\cos\left(\frac{\pi}{2}x\right)\right) & =\arctan\left(\lim_{x\to1}x+\cos\left(\lim_{x\to1}\frac{\pi}{2}x\right)\right)\\ & =\arctan\left(1+\cos\left(\frac{\pi}{2}\right)\right)\\ & =\arctan\left(1+0\right)\\ & =\frac{\pi}{4}.\end{aligned}\] Therefore, \[\lim_{x\to1}\arctan\left(x+\cos\left(\frac{\pi}{2}x\right)\right)=\frac{\pi}{4}.\]

(c) Because \(y=\ln x\) is a continuous function on its domain \((0,\infty)\), we have \[\begin{aligned} \lim_{x\to0}\ln\left(1+e^{\tan x}\right) & =\ln\left(\lim_{x\to0}\left(1+e^{\tan x}\right)\right)\\ & =\ln\left(\lim_{x\to0}1+\lim_{x\to0}e^{\tan x}\right)\end{aligned}\] Because \(y=e^{x}\) is continuous everywhere, \[\begin{aligned} \ln\left(\lim_{x\to0}1+\lim_{x\to0}e^{\tan x}\right) & =\ln\left(\lim_{x\to0}1+e^{\lim_{x\to0}\tan x}\right)\\ & =\ln(1+e^{0})\\ & =\ln(1+1)=\ln2.\end{aligned}\] That is, \[\lim_{x\to0}\ln\left(1+e^{\tan x}\right)=\ln2.\]

Example 6

Find \[\lim_{x\to\infty}\sin\frac{1}{x}.\]

Solution

Because \(f(x)=\sin x\) is continuous everywhere, \[\lim_{x\to\infty}\sin\frac{1}{x}=\sin\left(\lim_{x\to\infty}\frac{1}{x}\right).\] [Recall that \(\lim_{x\to\pm\infty}\frac{1}{x^{r}}=0\) where \(r>0\) is a rational number (Theorem 1 in Section 4.7)]. Thus \[\sin\left(\lim_{x\to\infty}\frac{1}{x}\right)=\sin(0)=0.\] The graph of \(y=\sin\frac{1}{x}\) is shown below.

Figure 14: Graph of \(y=\sin\frac{1}{x}\). We can see from this figure that \(\lim_{x\to\pm\infty}\sin\frac{1}{x}=0\).

Example 7

Find
(a) \({\displaystyle \lim_{x\to0^{+}}\arctan\left(\frac{1}{x}\right)}\)
(b) \({\displaystyle \lim_{x\to0^{-}}\arctan\left(\frac{1}{x}\right)}\)
(c) \({\displaystyle \lim_{x\to\infty}\arctan\left(\frac{1}{x}\right)}\)
(d) \({\displaystyle \lim_{x\to-\infty}\arctan\left(\frac{1}{x}\right)}\)

Solution

(a) Because \(y=\arctan x\) is a continuous function, we can find the limit of its input first. That is, \[\begin{aligned} \lim_{x\to0^{+}}\arctan\left(\frac{1}{x}\right) & =\arctan\left(\lim_{x\to0^{+}}\frac{1}{x}\right)\\ & =\arctan(+\infty)\\ & =\frac{\pi}{2}\end{aligned}\] [To be accurate, we cannot write \(\arctan(+\infty)\) because \(+\infty\) is not a number] (b) Similar to part (a) \[\begin{aligned} \lim_{x\to0^{-}}\arctan\left(\frac{1}{x}\right) & =\arctan\left(\lim_{x\to0^{-}}\frac{1}{x}\right)\\ & =\arctan(-\infty)\\ & =-\frac{\pi}{2}.\end{aligned}\]

(c) \[\begin{aligned} \lim_{x\to+\infty}\arctan\left(\frac{1}{x}\right) & =\arctan\left(\lim_{x\to+\infty}\frac{1}{x}\right)\\ & =\arctan(0)\\ & =0.\end{aligned}\]

(d) \[\begin{aligned} \lim_{x\to-\infty}\arctan\left(\frac{1}{x}\right) & =\arctan\left(\lim_{x\to-\infty}\frac{1}{x}\right)\\ & =\arctan(0)\\ & =0.\end{aligned}\] The graph of \(y=\arctan(1/x)\) is shown in the following figure.

Figure 14: Graph of \(y=\arctan\frac{1}{x}\).

It follows from Theorem 2 that

Theorem 3: If \(g\) is a continuous function at \(a\) and if \(f\) is continuous at \(g(a),\)then \(f\circ g\) is continuous at \(a\)


Show the proof

To prove the above theorem, we need to show \[\lim_{x\to a}(f\circ g)(x)=(f\circ g)(a)\] or \[\lim_{x\to a}f(g(x))=f(g(a)).\] Because \(g\) is continuous at \(x=a\), then \[\lim_{x\to a}g(x)=g(a)\] and because \(f\) is continuous at \(g(a),\) by Theorem 2 \[\begin{aligned} \lim_{x\to a}f(g(x)) & =f\left(\lim_{x\to a}g(x)\right)\\ & =f(g(a)).\end{aligned}\]


Example 8
Where are the following functions continuous?
(a) \(h(x)=\cos(x^{3}+1)\)
(b) \(F(x)=\left|\dfrac{x\cos x}{x^{2}+1}\right|\)
(c) \(G(x)=\sqrt{x^{2}+2x-2}\)

Solution

(a) We have \(h(x)=f(g(x))\) where \[f(x)=\cos x\ \text{and}\ g(x)=x^{3}+1.\] Because both \(f\) and \(g\) (which is a polynomial) are continuous on \(\mathbb{R}\), it follows from Theorem 3 that \(h=f\circ g\) is also continuous on \(\mathbb{R}\).

(b) Notice that \(F\) is the composition of the following functions \(F=f\circ g\): \[f(x)=|x|\ \text{and}\ g(x)=\frac{x\cos x}{x^{2}+1}\] Obviously \(f\) is continuous on \(\mathbb{R}\). We can write \(g(x)=u(x)v(x)/w(x)\) where \[u(x)=x,\ v(x)=\cos x,\ w(x)=x^{2}+1\] Because \(u,v\) and \(w\) are continuous functions on \(\mathbb{R}\) and \(w(x)\neq0\), by the product and quotient rules (Theorem 1), \(g\) is continuous on \(\mathbb{R}\) too. Because \(f\) and \(g\) are both continuous on \(\mathbb{R}\) and \(F=f\circ g\), it follows from Theorem 3 that \(F\) is also continuous on \(\mathbb{R}\).

(c) We have \(G=f\circ g\) where \[f(x)=\sqrt{x},\ \text{and}\ g(x)=x^{2}+2x-2\] The square root function is continuous on its domain \([0,\infty)\), and \(g\) which is a polynomial is continuous on \(\mathbb{R}\). So by Theorem 3, \(G\) is continuous on its domain, which is \[\left\{ \left.x\in\mathbb{R}\right|\ x^{2}+2x-2\geq0\right\}\] We can use the sign table to determine where \(g(x)=x^{2}+2x-2\geq0\): \[x^{2}+2x-2=0\Rightarrow x=\frac{-b\pm\sqrt{b^{2}-4ac}}{2a}=\frac{-2\pm\sqrt{2^{2}+4\times2}}{2}=-1\pm\sqrt{3}\] So we can write \[x^{2}+2x-2=(x+1-\sqrt{3})(x+1+\sqrt{3})\]

\large x \(-\infty\)   \(-1-\sqrt{3}\)   \(-1+\sqrt{3}\)   \(\infty\)
sign of \((x+1-\sqrt{3})\)   – – – – – – – – $0$ + + + +  
sign of \((x+1+\sqrt{3})\)   – – – – $0$ + + + + + + + + +  
\(\therefore\) sign of \(x^{2}+2x-2\)   + + + + $0$ – – – – $0$ + + + +  

Therefore, $G$ is continuous on the following set: \[\left\{ \left.x\in\mathbb{R}\right|\ x^{2}+2x-2\geq0\right\} =(-\infty,-1-\sqrt{3}]\cup[-1+\sqrt{3},\infty)\]