5

The main question was how many values of $x$ satisfy the equation $\tan x+\sec x=2\cos x$ in the interval $[0,2\pi]$

Solving for $x$ gives two valid solutions (namely $\frac\pi 6$ and $\frac{5\pi} 6$) and one invalid solution (namely $\frac{3\pi}{2}$) because $\tan(\frac{3\pi}{2})$ is undefined. But graphing the equation over the given interval in Desmos shows $\frac{3\pi}{2}$ as a valid solution, why is that? Or is it really a valid solution?

My guess is that since Desmos is showing a decimal approximation instead of the exact form of $\frac{3\pi}{2}$ maybe the $0$ as well is an approximate of some value really really close to $0.$

function

Blue
  • 85,834
Noor
  • 1,069
  • 10
    The thing is that $$\tan x + \sec x = \frac{\sin x + 1}{\cos x}$$ has a removable singularity at $(2k-1/2)\pi$. So if you consider $\tan x + \sec x - 2\cos x$ as a meromorphic function with all removable singularities removed, $\frac{3\pi}{2}$ is a pukka zero. If you consider $\frac{\sin x}{\cos x} + \frac{1}{\cos x} - 2\cos x$ as a recipe for computation, it's undefined at $\frac{3\pi}{2}$. – Dermot Craddock Aug 16 '25 at 11:13
  • 2
    Your guess is right. In fact, if you zoom in enough around the root you'll see desmos finds hundreds of "roots" near the point. – jjagmath Aug 16 '25 at 11:25
  • @DermotCraddock that answers my question, but at a highschool level we don't deal with with removable singularities so $\frac{3\pi}{2}$ should be considered an invalid solution right? – Noor Aug 16 '25 at 11:29
  • 3
    I can't speak with authority for all high schools, but I consider it a pretty safe bet that $\frac{3\pi}{2}$ should not be considered a solution in a high school context. ;) – Dermot Craddock Aug 16 '25 at 11:35
  • @DermotCraddock please write the answer in the answers section, so that this question can be removed from the "Unanswered" list. – Tveltzel Aug 16 '25 at 12:20
  • @Tveltzel Already done :) – Dermot Craddock Aug 16 '25 at 12:21
  • 1
    Awesome!

    at a highschool level, since we don't deal with removable singularities, this solution would usually not be accepted (at least in Singapore).

    – Tveltzel Aug 16 '25 at 12:25
  • @Tveltzel not here in Bangladesh either – Noor Aug 16 '25 at 12:54

2 Answers2

5

In a typical high-school (or college calculus) context, the left hand side of the equation is undefined for $x = \frac{3\pi}{2}$ since $\cos \frac{3\pi}{2} = 0$. However, as the graph on Desmos suggests, this singularity can be removed, and the function \begin{equation} f(x) = \tan x + \sec x \end{equation} can be continuously extended by setting $f\bigl((2k-\frac{1}{2})\pi\bigr) = 0$. For $0 < \lvert\varepsilon\rvert < \frac{\pi}{4}$, consider \begin{align} f\biggl(\frac{3\pi}{2} + \varepsilon\biggr) &= \frac{1 + \sin \bigl(\frac{3\pi}{2} + \varepsilon\bigr)}{\cos \bigl(\frac{3\pi}{2} + \varepsilon\bigr)} \\ &= \frac{1 - \sin\bigl(\frac{\pi}{2} - \varepsilon\bigr)}{\cos \bigl(\frac{\pi}{2} - \varepsilon\bigr)} \\ &= \frac{1 - \cos \varepsilon}{\sin \varepsilon} \\ &= \frac{1 - \bigl(\cos^2 \frac{\varepsilon}{2} - \sin^2 \frac{\varepsilon}{2}\bigr)}{2\sin \frac{\varepsilon}{2}\cos \frac{\varepsilon}{2}} \\ &= \frac{2\sin^2 \frac{\varepsilon}{2}}{2\sin\frac{\varepsilon}{2}\cos \frac{\varepsilon}{2}} \\ &= \tan \frac{\varepsilon}{2}\,, \end{align} where $\sin (2\pi - y) = -\sin y$, $\cos (2\pi - y) = \cos y$, $\sin \bigl(\frac{\pi}{2} - y\bigr) = \cos y$ and the double-angle formulæ have been used. This shows that indeed \begin{equation} \lim_{x \to \frac{3\pi}{2}} f(x) = 0\,. \end{equation}

Dermot Craddock
  • 6,299
  • 2
  • 16
  • 36
  • 1
    Another way to remove the discontinuity is to write (subject to a sign ambiguity in cosine) $$\sec x+\tan x=\frac{1+\sin x}{\cos x}=\pm\sqrt{\frac{(1+\sin x)^2}{1-\sin^2 x}}=\pm\sqrt{\frac{(1+\sin x)^2}{(1+\sin x)(1-\sin x)}}=\pm\sqrt{\frac{1+\sin x}{1-\sin x}}$$ Canceling $1+\sin x$ allows substituting $x=3\pi/2$ in the denominator, yielding an overall value of $0$ (so the $\pm$ isn't an issue). Although technically we're left with a hole, as a practical matter we often hand-wave such holes away ... but, of course, not when identifying holes is part of the purpose of an exercise. – Blue Aug 16 '25 at 14:53
  • This makes so much sense, that too at a high-school level! In fact there is exactly a problem like this in my textbook which asks to simplify $\tan x + \sec x$ as such. – Noor Aug 23 '25 at 07:00
3

For any $\;x\in\Bbb R\;$ such that $\;x\neq\dfrac\pi2+k\pi\;$ for all $\;k\in\Bbb Z\;,\,$
we have that
$\begin{align}\tan x+\sec x&=\dfrac{\sin x+1}{\cos x}=\dfrac{(\sin x+1)(1-\sin x)}{\cos x(1-\sin x)}=\\[3pt]&=\dfrac{1-\sin^2\!x}{\cos x(1-\sin x)}=\dfrac{\cos^2\!x}{\cos x(1-\sin x)}=\\[3pt]&=\dfrac{\cos x}{1-\sin x}\;.\end{align}$

Therefore ,
$\lim\limits_{x\to\frac{3\pi}2}\big(\tan x+\sec x\big)=\lim\limits_{x\to\frac{3\pi}2}\dfrac{\cos x}{1-\sin x}=\dfrac0{1-(-1)}=0\;.$

Consequently, the function $\;f(x)=\tan x+\sec x\;$ has a removable singularity at $\,x\!=\!\dfrac{3\pi}2\,$ which can be removed by setting $\;f\!\left(\!\dfrac{3\pi}2\!\right)\!\!=\!0\,.$

By removing that singularity, the following equation$\color{white}{\bigg(}$
$\tan x+\sec x=2\cos x\;$
does also have the solution $\;x\!=\!\dfrac{3\pi}2\,$ on the interval $\;[0,2\pi]\,.$

Angelo
  • 14,583