Evaluating definite integrals using Fundamental Theorem of Calculus

Here is a statement of the second part of the Fundamental Theorem of Calculus (FTC2), from a well-known calculus text (James Stewart, Calculus, 4th ed):

If $$f$$ is continuous on $$[a,b]$$, then $$\int_a^b f(x) \, dx = F(b)-F(a)$$, where $$F$$ is any [emphasis mine] antiderivative of $$f$$, that is, a function such that $$F'=f$$.

The following, however, seems to give a counterexample.*
Can someone resolve this for me?:

Let $$f(x) = \frac{1}{4 \sin (x)+5}$$.

$$f$$ is continuous on $$[0, 2 \pi]$$: Consider two antiderivatives of $$f$$, $$F_1$$ and $$F_2$$:

$$F_1(x) = \frac{x}{3}+\frac{2}{3} \tan^{-1}\left(\frac{\cos (x)}{\sin (x)+2}\right)$$

$$F_2(x)=\frac{1}{3} \left(\tan ^{-1}\left(2-\frac{3}{\tan \left(\frac{x}{2}\right)+2}\right)-\tan^{-1}\left(2-\frac{3}{\cot \left(\frac{x}{2}\right)+2}\right)\right).$$

Using Mathematica, I've confirmed that both $$F_1'= f$$ and $$F_2'= f$$. According to my reading of the above statement of FTC(2), $$\int_0^{2\pi} f (x) \, dx = F_1(2\pi)-F_1(0)= F_2(2\pi)-F_2(0)$$

However,

$$F_1(2\pi)-F_1(0)=2\pi/3$$

$$F_2(2\pi)-F_2(0)=0$$

Note from the plots below that $$F_1$$ is continuous on $$[a,b]$$, while $$F_2$$ is not. Given all of this, it seems the sufficient condition for $$\int_a^b f (x) \, dx = F(b)-F(a)$$ is that the antiderivative be continuous on $$[a,b]$$, not the integrand.

$$F_1 =$$ $$F_2=$$ *I've taken this example function from a wolfram.com blog.

• It's obvious just from the graphs that $F_2$ is not an antiderivative. At the points of discontinuity, $F_2$ has a limit of its derivative, but that's not the same thing as being differentiable at that point. – aschepler Jan 20 at 3:56
• The integral function of any function is continuous period. So if you got an $F$ that wasn't continuous then it wasn't an integral. By integral I mean $\int_0^x f(t) dt = F(x)$. An integral need not be differentiable though. – The Great Duck Jan 20 at 7:19
• $F_1$ and $F_2$ can be made equal by adding constants, $c_i$, in each interval where $F_2$ is continuous. For instance $c_i\approx0.524$ when $x\in(-0.93, 4.07)$ and so on. These $c_i$ account for the discontinuities in $f(x)$ but as long as you're not integrating over any discontinuities, $F_2$ would be valid. This is all because the antiderivative of a discontinuous function may have multiple constants of integration (even in the case of $\int \frac1x\mathrm{d}x$). – Jam Jan 20 at 20:10
• Great Duck forgets about the Heavyside impulse function. – richard1941 Jan 24 at 5:33
• @richard1941 The Heaviside step function is not the antiderivative of a function. The Dirac delta function is not a true function in the sense of real analysis (though it can be addressed by the theory of "generalized functions"). – Christian Sykes Feb 13 at 4:48

A differentiable function is continuous. If your "antiderivative" is not continuous, it is not an antiderivative of a continuous function.

• It's also worth mentioning that any integral function is also always continuous regardless of whether or not an antiderivative actually exists. Though when the antiderivative exists then the set of integral functions and antiderivatives will be one and the same. – The Great Duck Jan 20 at 7:17
• Thanks Martin. That clears it up. I'll just wait the requisite additional day or so before accepting an answer. I'm curious: Is the proper phrasing to say that F2 is not differentiable, period, or can we say it is (piecewise?) differentiable on the domain x ∈ ℝ, where: x ≠ {- 2(arctan + n𝜋) || - 2(cotan + n𝜋)} & n ∈ ℤ? [I understand that, even if one could say the latter, it wouldn't change the fact that F2 is not an antiderivative of f.] – theorist Jan 20 at 21:51
• Glad I could help. And yes, you are right. It is piecewise differentiable. – Martin Argerami Jan 20 at 23:52

@Martin Argerami posted a succinct and correct answer:

A differentiable function is continuous. If your "antiderivative" is not continuous, it is not an antiderivative of a continuous function.

To elaborate, $$F_2$$ is not continuous due to the multi-valued nature of $$\arctan$$. Since $$\tan$$ is a periodic function (with a period of $$\pi$$), this means that $$\arctan$$ has an infinite number of values. Its plot looks like this: To make it a proper function (one unique output value), we usually pick the primary branch (the one through the origin). However, notice that the primary branch is discontinuous at infinity - if we pass through positive infinity and come back out at negative infinity, we've jumped from $$\pi/2$$ to $$-\pi/2$$. What we really wanted was to move to the next branch up to preserve continuity, but to do that we'd no longer have a single valued function. We wouldn't have a function at all, really, since the common definition of function requires it to be single valued.

The discontinuities of $$F_2$$ are precisely where the argument of $$\arctan$$ becomes infinite - where $$2+\cot\frac{x}{2}$$ and $$2+\tan\frac{x}{2}$$ become zero - approximately 4.07 and 5.36.

• Since we are talking about functions on the real numbers, of which $\infty$ is a not a member, there no such thing as "discontinuous at infinity". – Paul Sinclair Jan 20 at 1:35
• @Paul Sinclair: True, I'm playing a bit loose with that term. 3/(2+tan(x/2)) approaches negative infinity (at x=4.07), becomes indeterminate, then reappears coming in from positive infinity. Applying arctan to two minus that value, it approaches -pi/2, becomes indeterminate, then reappears decreasing from pi/2. Strictly speaking, it's a non-removable discontinuity that can be understood by looking at the limiting behavior of arctan as it approaches $\pm\infty$ – Brent Baccala Jan 20 at 3:21

The top paragraph apparently has an error. The integral of f(x) dx from a to b is F(b) - F(a), not F(a) - F(b), where F is any antiderivative of f.

• Thanks, fixed it! Though, for future reference, since this isn't an answer, according to site guidelines it should be posted as a comment on my post rather than an answer. [Stack Exchange likes to distinguish the two to maintain site readability.] – theorist Jan 25 at 0:34