As a property of definite integrals, we teach that definite integrals are zero if the lower and upper limits are the same (Wolfram mathworld says this too). Is this valid in general?

In the case of integrating $\dfrac1{4+\sin^2x}$ from $0$ to $π$ using the substitution $t = \tan x,$ we get both new limits $0,$ so the integral should be $0$, but if you use the symmetry of the graph and describe the integral in terms of area, you get a positive value. How would explain this to students? Do we need to say that there are exceptions?

  • 15
    $\begingroup$ You ask now and then questions here which you frame as "How can I teach my students xyz", while the wording of the post indicates that your actual problem is "I do not know the answer to xyz myself." I'd like to encourage you again to ask those questions where they belong, i.e. on Math StackExchange. Please don't get me wrong: I really appreciate that you care about being a good teacher. But before you ask "How can I teach xyz" you need to ensure that you understand xyz yourself - and if you see the need to improve your understanding of xyz, the right place to do so is Math StackExchange. $\endgroup$ Commented Feb 25, 2023 at 14:18
  • $\begingroup$ @JochenGlueck I appreciate your advice and to be honest actually I couldn't realize the point mentioned by ryang. As a lifelong learner I thought to get advice from experience seniors . $\endgroup$ Commented Feb 25, 2023 at 14:31
  • 2
    $\begingroup$ @JanakaRodrigo While composing a post, intended questions frequently get refined or self-answered and new questions surface, right? Jochen's reminder is that if after composing a post it becomes clearer that it is more suited to mathematics.SE, then consider tweaking it and submitting it there instead. $\endgroup$
    – ryang
    Commented Feb 26, 2023 at 5:53
  • $\begingroup$ @ryang Since I wanted to know much better approach to explain the issue to students I thought to ask it here from experienced professionals such as you. However I'm really grateful for your support. $\endgroup$ Commented Feb 26, 2023 at 5:59
  • $\begingroup$ The mathematical issue here has been discussed many times on math.SE. See for example this question and the ones linking to it. $\endgroup$ Commented Mar 5, 2023 at 10:40

3 Answers 3


How would explain this to students?

Explain that checking that conditions are satisfied is part of the process of applying theorems/laws.

(Admittedly, though, since integration change of variable is seldom rigorously taught or even presented as a theorem, it is not a great example to demonstrate carefully reading theorems.)

  1. In the OP's example, writing the substitution $t=\tan x$ as $t=g(x),$ the variable-change theorem requires that $g'$ is integrable on the original integration domain $[0,\pi];$ since this isn't satisfied, the substitution isn't applicable.

  2. A related fake trick is $$\int_a^b f(x)\,\mathrm dx\ne0 \\\text{and}\\u=\color{red}{g(x)} \text{ such that }g’\text{ is integrable on }[a,b]\text{ and }g(a)=k=g(b)\\\implies\\\int_a^b f(x)\,\mathrm dx=\int_k^k\color\red{\text{[this integrand doesn't matter]}}\,\mathrm du=0.$$ Here, in neglecting to attempt to determine the new integrand (doing this is another aspect of verifying that this theorem is applicable), the student is denied the discovery that the given integrand $f$ is not actually compatible with this particular choice of $g.$

  • $\begingroup$ Thanks for sharing your knowledge, is it ok if we say g should be differentiable on [0,π] because you need to differentiate g . Then in my case tanx is not differentiable on that interval and the substitution is not allowed. $\endgroup$ Commented Feb 25, 2023 at 11:05
  • 3
    $\begingroup$ @JanakaRodrigo The integrable-$g’$ condition is required by the FTC, which is invoked by the change-of-variable theorem; on the other hand, the indefinite-integral version of the theorem requires merely that $g$ is differentiable. $\quad$ In practice, though, your request is reasonable, since pathological substitutions (a $g’$ that is not integrable) almost certainly won’t be encountered. $\endgroup$
    – ryang
    Commented Feb 25, 2023 at 15:08
  • $\begingroup$ @JanakaRodrigo In your given example, $g'$ failing, somewhere within the integration domain, to even exist does immediately mean that this substitution isn’t valid. $\endgroup$
    – ryang
    Commented Feb 25, 2023 at 18:19

ryang has explained the issue, but I think it might be helpful to students to frame the issue in a more positive light--instead of "you can't use this substitution here", say "here's what you need to do to use this substitution." The problem is that $\tan x$ is not differentiable on $[0,\pi]$ because it's not even defined at $x=\frac{\pi}{2}$. So in order to use this substitution you have to find a way to rewrite the integral to avoid the troublesome point. In this example we can write \begin{align} \int_0^\pi\frac{1}{4+\sin^2x}dx&=\int_0^{\pi/2}\frac{1}{4+\sin^2x}dx+\int_{\pi/2}^\pi\frac{1}{4+\sin^2x}dx\\ &=\lim_{r\to\pi/2^-}\int_0^r\frac{1}{4+\sin^2x}dx+\lim_{r\to\pi/2^+}\int_r^\pi\frac{1}{4+\sin^2x}dx. \end{align} The purpose of introducing the limits is to keep $\frac{\pi}{2}$ out of the interval. Now your substitution works fine and you get $$ \lim_{s\to\infty}\int_0^s\frac{1}{5t^2+4}dt+\lim_{s\to-\infty}\int_s^0\frac{1}{5t^2+4}dt. $$ In this example since the integrand is an even function you can just double the first integral.

By explaining things this way, you don't have throw away a promising substitution and, by going through the process of choosing intervals carefully, you reinforce the idea of checking the needed conditions. My feeling is that by the time students are learning these kinds of substitutions they should already be strongly conditioned to recoil against any attempt to do a definite integral using the fundamental theorem of calculus over an interval where the integrand is not defined at every point. For an example of what can go badly wrong, consider how if you naively apply the fundamental theorem to $$ \int_{-1}^1\frac{1}{x^2}dx $$ you get obvious nonsense (a finite negative answer where the integrand is positive and, properly treated, the integral is infinite).

  • $\begingroup$ Yes of cause, the way you suggest saves the importance of the standard substitution for that type of integrand. Thanks for sharing your views. $\endgroup$ Commented Feb 25, 2023 at 17:55

Your question is similar to the issue raised in this post:

Should $\varphi$ be monotone in the integration by substitution?

But in your situation, there is a more critical issue in that your new variable $g(x)=\tan x$ is not defined at $x=\pi/2$.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.