Two ways of doing an integral (Part 2)

A colleague placed the following problem on an exam, expecting the following solution:

\displaystyle \int \frac{dx}{\sqrt{4x-x^2}} = \sin^{-1} \left( \displaystyle \frac{x-2}{2} \right) + C

However, one student produced the following solution (see yesterday’s post for details):

\displaystyle \int \frac{dx}{\sqrt{4x-x^2}} = 2 \sin^{-1} \left( \displaystyle \frac{\sqrt{x}}{2} \right) + C

As he couldn’t find a mistake in the student’s work, he assumed that the two expressions were equivalent. Indeed, he differentiated the student’s work to make sure it was right. But he couldn’t immediately see, using elementary reasoning, why they were equivalent. So he walked across the hall to my office to ask me if I could help.

Here’s how I showed they are equivalent.

Let \alpha = \displaystyle \sin^{-1} \left( \frac{x-2}{2} \right) and \beta = \sin^{-1} \left( \displaystyle \frac{\sqrt{x}}{2} \right) . Then

\displaystyle \sin(\alpha - 2\beta) = \sin \alpha \cos 2\beta - \cos \alpha \sin 2\beta.

Let’s evaluate the four expressions on the right-hand side.

First, \sin \alpha is clearly equal to \displaystyle \frac{x-2}{2}.

Second, \cos 2\beta = 1 - 2 \sin^2 \beta, so that

\cos 2\beta = \displaystyle 1 - 2\left( \frac{\sqrt{x}}{2} \right)^2 = \displaystyle 1 - \frac{x}{2} = \displaystyle -\frac{x-2}{2}.

Third, to evaluate $\cos \alpha$, I’ll use the identity \displaystyle \cos \left( \sin^{-1} x \right) = \sqrt{1 - x^2}:

\cos \alpha = \displaystyle \sqrt{1 - \left( \frac{x-2}{2} \right)^2 } = \displaystyle \frac{\sqrt{4x-x^2}}{2}

Fourth, \sin 2\beta = 2 \sin \beta \cos \beta. Using the above identity again, we find

\sin 2\beta = \displaystyle 2 \left( \frac{ \sqrt{x} }{2} \right) \sqrt{ 1 - \left( \frac{ \sqrt{x} }{2} \right)^2 }

= \sqrt{x} \sqrt{1 - \displaystyle \frac{x}{4}}

= \displaystyle \frac{\sqrt{4x-x^2}}{2}

 Combining the above, we find

\sin(\alpha - 2 \beta) = \displaystyle -\left( \frac{x-2}{2} \right)^2 - \left( \frac{\sqrt{4x-x^2}}{2} \right)^2

\sin(\alpha - 2 \beta) = \displaystyle \frac{-(x^2 - 4x + 4) - (4x - x^2)}{4}

\sin(\alpha - 2 \beta) = -1

\alpha - 2 \beta = \displaystyle -\frac{\pi}{2} + 2\pi n for some integer n

Also, since -\pi/2 \le \alpha \le \pi/2 and 0 \le -2\beta \le \pi, we see that -\pi/2 \le \alpha - 2 \beta \le 3\pi/2. (From its definition, $\beta$ is the arcsine of a positive number and therefore must be nonnegative.) Therefore, \alpha - 2\beta = -\pi/2.

In other words,

\sin^{-1} \left( \displaystyle \frac{x-2}{2} \right) and 2 \sin^{-1} \left( \displaystyle \frac{\sqrt{x}}{2} \right)

differ by a constant, thus showing that the two antiderivatives are equivalent.

 

Two ways of doing an integral (Part 1)

A colleague placed the following problem on an exam:

\displaystyle \int \frac{dx}{\sqrt{4x-x^2}}

He expected students to solve this problem by the standard technique, completing the square:

\displaystyle \int \frac{dx}{\sqrt{4x-x^2}} = \displaystyle \int \frac{dx}{4-(x-2)^2} = \sin^{-1} \left( \displaystyle \frac{x-2}{2} \right) + C

However, one student solved this problem by some clever algebra and the substitution u = \sqrt{x}, so that x = u^2 and dx = 2u \, du = 2 \sqrt{x} \, du:

\displaystyle \int \frac{dx}{\sqrt{4x-x^2}} = \displaystyle \int \frac{dx}{\sqrt{x} \sqrt{4-x}}

= \displaystyle \int \frac{dx}{\sqrt{x} \sqrt{4 - (\sqrt{x})^2}}

= \displaystyle \int \frac{2 \, du}{\sqrt{4 - u^2}}

= 2 \sin^{-1} \left( \displaystyle \frac{u}{2} \right) + C

= 2 \sin^{-1} \left( \displaystyle \frac{\sqrt{x}}{2} \right) + C

As he couldn’t find a mistake in the student’s work, he assumed that the two expressions were equivalent. Indeed, he differentiated the student’s work to make sure it was right. But he couldn’t immediately see, using elementary reasoning, why they were equivalent. So he walked across the hall to my office to ask me if I could help.

After a few minutes, I was able to show that the two expressions were equivalent.

I’ll leave this one as a cliff-hanger for now. In tomorrow’s post, I’ll show why they’re equivalent.

Approximating pi

I was recently interviewed by my city’s local newspaper about \pi Day and the general fascination with memorizing the digits of \pi. I was asked by the reporter if the only constraint in our knowledge of the digits of \pi was the ability of computers to calculate the digits, and I answered in the affirmative.

Here’s the current state-of-the-art for calculating the digits of \pi. Amazingly, this expression was discovered  1995… in other words, very recently.

\pi = \displaystyle \sum_{n=0}^\infty \frac{1}{16^n} \left( \frac{4}{8n+1} - \frac{2}{8n+4} - \frac{1}{8n+5} - \frac{1}{8n+6} \right)

Because of the term 16^n in the denominator, this infinite series converges very quickly.

Proof: If k < 8, then we calculate the integral I_k, defined below:

I_k = \displaystyle \int_0^{1/\sqrt{2}} \frac{x^{k-1}}{1-x^8} dx

= \displaystyle \int_0^{1/\sqrt{2}} x^{k-1} \sum_{n=0}^\infty x^{8n} dx

= \displaystyle \int_0^{1/\sqrt{2}} \sum_{n=0}^\infty x^{8n+k-1} dx

= \displaystyle \sum_{n=0}^\infty \int_0^{1/\sqrt{2}} x^{8n+k-1} dx

= \displaystyle \sum_{n=0}^\infty \left[ \frac{x^{8n+k}}{8n+k} \right]^{1/\sqrt{2}}_0

= \displaystyle \sum_{n=0}^\infty \frac{1}{8n+k} \left[ \left( \frac{1}{\sqrt{2}} \right)^{8n+k} - 0 \right]

= \displaystyle \sum_{n=0}^\infty \frac{1}{2^{k/2}} \frac{1}{16^n (8n+k)}

We now form the linear combination P = 4\sqrt{2} I_1 - 8 I_4 - 4\sqrt{2} I_5 - 8 I_6:

P = \displaystyle \sum_{n=0}^\infty \left( \frac{4\sqrt{2}}{2^{1/2}} \frac{1}{16^n (8n+1)} - \frac{8}{2^{4/2}} \frac{1}{16^n (8n+4)} - \frac{4\sqrt{2}}{2^{5/2}} \frac{1}{16^n (8n+5)} - \frac{8}{2^{6/2}} \frac{1}{16^n (8n+6)} \right)

P = \displaystyle \sum_{n=0}^\infty \frac{1}{16^n} \left( \frac{4}{8n+1} - \frac{2}{8n+4} - \frac{1}{8n+5} - \frac{1}{8n+6} \right)

Also, from the original definition of the I_k,

P = \displaystyle \int_0^{1/\sqrt{2}} \frac{4\sqrt{2} - 8x^3 -4\sqrt{2} x^4 - 8x^5}{1-x^8} dx.

Employ the substitution x = y/\sqrt{2}:

P = \displaystyle \int_ 0^1 \frac{4\sqrt {2} - 2\sqrt {2} y^3 - \sqrt {2} y^4 - \sqrt {2} y^5}{1 - y^8/16}\frac {dy} {\sqrt {2}}

P = \displaystyle \int_ 0^1 \frac{16 (4 - 2 y^3 - y^4 - y^5)}{16 - y^8} dy

P = \displaystyle \int_0^1 \frac{16(y-1)(y^2+2)(y^2+2y+2)}{(y^2-2)(y^2+2)(y^2+2y+2)(y^2-2y+2)} dy

P = \displaystyle \int_0^1 \frac{16y-16}{(y^2-2)(y^2-2y+2)} dy

Using partial fractions, we find

P = \displaystyle \int_ 0^1\frac{4 y}{y^2 - 2} dy - \int_ 0^1 \frac{4 y - 8}{y^2 - 2 y + 2} dy

The expression on the right-hand side can be simplified using standard techniques from Calculus II and is equal to \pi.

green line

So that’s the proof… totally accessible to a student who has mastered concepts in Calculus II. But this begs the question: how in the world did anyone come up with the idea of starting with the integrals $I_k$ to develop an infinite series that leads to \pi? Let me quote from page 118 of J. Arndt and C. Haenel, \pi - Unleashed (Springer, New York, 2000):

Certainly not by chance, even if luck played some part in the discovery. All three parties [David Bailey, Peter Borwein and Simon Plouffe] are established mathematicians who have been working with the number \pi for a considerable time… Yet the series was not discovered through mathematical deduction or inference. Instead, the researchers used a tool called Computer Algebra System and a particular procedure called the “PSQL algorithm” to generate their series. They themselves write that they found their formula “through a combination of inspired testing and extensive searching.”

The original paper that announced the discovery of this series can be found at http://www.cecm.sfu.ca/personal/pborwein/PAPERS/P123.pdf.

Is there an easy function without an easy Taylor series expansion?

After class one day, a student approached me with an interesting question:

Is there an easy function without an easy Taylor expansion?

This question really struck me for several reasons.

  1. Most functions do not have an easy Taylor (or Maclaurin) expansion. After all, the formula for a Taylor expansion involves the nth derivative of the original function, and higher-order derivatives usually get progressively messier with each successive differentiation.
  2. Most of the series expansions that are taught in Calculus II arise from functions that somehow violate the above rule, like f(x) = \sin x, f(x) = \cos x, f(x) = e^x, and f(x) = 1/(1-x).
  3. Therefore, this student was under the misconception that most easy functions have easy Taylor expansions, while in reality most functions do not.

It took me a moment to answer his question, but I answered with f(x) = tan x. Successively using the Quotient Rule makes the derivatives of tan x messier and messier, but tan x definitely qualifies as an easy function that most students have seen since high school. It turns out that the Taylor expansion of f(x) = \sin x can be written as an infinite series using the Bernoulli numbers, but that’s a concept that most calculus students haven’t seen yet.

Earlier posts on Taylor series:

https://meangreenmath.com/2013/07/01/reminding-students-about-taylor-series-part-1/

https://meangreenmath.com/2013/07/02/reminding-students-about-taylor-series-part-2/

https://meangreenmath.com/2013/07/03/giving-students-a-refresher-about-taylor-series-part-3/

https://meangreenmath.com/2013/07/04/giving-students-a-refresher-about-taylor-series-part-4/

https://meangreenmath.com/2013/07/05/reminding-students-about-taylor-series-part-5/

https://meangreenmath.com/2013/07/06/reminding-students-about-taylor-series-part-6/

https://meangreenmath.com/2013/07/24/taylor-series-without-calculus-2/

Getting the right answer the wrong way

I just read “But My Physics Teacher Said… A Mathematical Approach to a Physical Problem,” which was a very interesting pedagogical article concerning the teaching of calculus. Here’s the central problem:

I included on their exam a question involving average velocity. I gave the students a quadratic function and asked them to calculate the average velocity over a given interval… One of my students… got the final numerical answer correct, but he hadn’t used the average velocity formula he had learned in our course. Instead… he had calculated the average of the velocities at the end points of the given interval. When I explained this to him, he stated that he didn’t understand the difference because he had learned the latter formula to calculate average velocity in his physics class.

It turns out that this alternative approach always work under the condition of constant acceleration (i.e., a quadratic function), and since constant acceleration is such an important special case in freshman physics, the formula was presented and the student remembered the formula. Of course, the student probably was not aware of the formula was only generally true under this specific circumstance.

After some pedagogical reflection, the author concluded

My student and I both learned from this experience. He gave me the opportunity to look at a familiar topic with the eye of a physicist, and I taught him the importance of context when using a formula. Specific adventures such as the one my student and I encountered will undoubtedly strengthen my approach to teaching this course and my students’ ability to think like mathematicians.

The full article can be found at http://digitaleditions.walsworthprintgroup.com/publication/?i=187509&p=19.

MAA Calculus Study: Persistence through Calculus

I just read a recent post by David Bressoud, former president of the Mathematical Association of America, concerning the percentage of college students in Calculus I who ultimately enroll in Calculus II. Some interesting quotes:

[J]ust because a student needs further mathematics for the intended career and has done well in the last mathematics course is no guarantee that he or she will decide to continue the study of mathematics. This loss between courses is a significant contributor to the disappearance from STEM fields of at least half of the students who enter college with the intention of pursuing a degree in science, technology, engineering, or mathematics.

And:

Our study offered students who had chosen to switch out a variety of reasons from which they could select any with which they agreed. Just over half reported that they had changed their major to a field that did not require Calculus II. A third of these students, as well as a third of all switchers, identified their experience in Calculus I as responsible for their decision. It also was a third of all switchers who reported that the reason for switching was that they found calculus to require too much time and effort.
This observation was supported by other data from our study that showed that switchers visit their instructors and tutors more often than persisters and spend more time studying calculus. As stated before, these are students who are doing well, but have decided that continuing would require more effort than they can afford.

And:

[W]e do need to find ways of mitigating the shock that hits so many students when they transition from high school to college. We need to do a better job of preparing students for the demands of college, working on both sides of the transition to equip them with the skills they need to make effective use of their time and effort.
Twenty years ago, I surveyed Calculus I students at Penn State and learned that most had no idea what it means to study mathematics. Their efforts seldom extended beyond trying to match the problems at the back of the section to the templates in the book or the examples that had been explained that day. The result was that studying mathematics had been reduced to the memorization of a large body of specific and seemingly unrelated techniques for solving a vast assortment of problems. No wonder students found it so difficult. I fear that this has not changed.

The full post can be found at http://launchings.blogspot.com/2013/12/maa-calculus-study-persistence-through.html.

Graphing a function by plugging in points

I love showing this engaging example to my students to emphasize the importance of the various curve-sketching techniques that are taught in Precalculus and Calculus.

Problem. Sketch the graph of f(x) = x^5 - 5x^3 + 4x + 6.

“Solution”. Let’s plug in some convenient points, graph the points, and then connect the dots to produce the graph.

  • f(-2) = (-32) - 5(-8) + 4(-2) + 6 = 6
  • f(-1) = (-1) - 5(-1) + 4(-1) + 6 = 6
  • f(0) = (0) - 5(0) + 4(0) + 6 = 6
  • f(1) = (1) - 5(1) + 4(1) + 6 = 6
  • f(2) = (32) - 5(8) + 4(2) + 6 = 6

That’s five points (shown in red), and surely that’s good enough for drawing the picture. Therefore, we can obtain the graph by connecting the dots (shown in blue). So we conclude the graph is as follows.

linearquinticgreen line

Of course, the above picture is not the graph of f(x) = x^5 - 5x^3 + 4x + 6, even though the five points in red are correct. I love using this example to illustrate to students that there’s a lot more to sketching a curve accurately than finding a few points and then connecting the dots.

Volume of solid of revolution

In Calculus I, we teach two different techniques for finding the volume of a solid of revolution:

  • Disks (or washers), in which the cross-section is perpendicular to the axis of revolution, and
  • Cylindrical shells, in which the cross-section is parallel to the axis of revolution.

Both of these could be expressed as either an integral with respect to x or as an integral with respect to y, depending on the axis of revolution. I won’t go into a full treatment of the procedure here; this can be found in places like http://www.cliffsnotes.com/math/calculus/calculus/applications-of-the-definite-integral/volumes-of-solids-of-revolution or http://mathworld.wolfram.com/SolidofRevolution.html or http://en.wikipedia.org/wiki/Disk_integration or http://en.wikipedia.org/wiki/Shell_integration.

A natural question asked by students is, “If I have the choice, should I use disks or shells?” The correct answer, of course, is “Pick the method that gives you the easier integral to compute.” But that’s not a very satisfying answer for novice students who’ve just been exposed to integral calculus. So, over the years, I developed a standard reply to this query:

That’s an excellent question, and it’s one of the classic conundrums faced by mankind over the years.

Should I choose Coke… or Pepsi?

McDonald’s… or Burger King?

Ginger… or Mary Ann?

Disks… or shells?

The answer is, it just takes a little practice and experience to determine which technique gives you the easier integral.

If you don’t get the cultural reference, here’s a reminder. As of 10 years ago, I could still tell this joke to college students and still get smiles of acknowledgement. But, given the passage of time, I’m not sure if this same joke would fly college students now.