The one problem I missed, 30 years ago, on my final exam in calculus

It’s been said that we often remember our failures more than our successes. In this instance, the adage rings true, because I can still remember, clear as a bell, the one problem that I got wrong on my high school calculus final that I took 30 years ago. Here it is:

\displaystyle \int (x^2+1)^2 dx

I tried every u-substitution under the sun, with no luck. I tried u = x^2+1. However, du would be equal to 2x \, dx, and there was no extra x in the integrand.

I believe I tried every crazy, unorthodox u-substitution possible given the time constraints of the exam: u = \sqrt{x}, u = \sqrt{x^2+1}, u = 1/x. Nothing worked.

We had learned trigonometric substitutions in my class, and so I also tried those. I started with x = \tan u, so that x^2 + 1 = \tan^2 x + 1 = \sec^2 x. This looked promising. However, dx = \sec^2 u \, du, so the integral became \displaystyle \int \sec^4 u \, du. From there, I was stuck. (Now that I’m older, I know that the logical train actually goes in the reverse direction than what I attempted as a student.)

I wasn’t taught integration by parts in this first course in calculus, so I didn’t even know to try it. Had I known this technique, I probably would’ve broken through my conceptual barrier to finally get the right answer. (In other words, integration by parts will yield the correct answer, but it’s a lot of work!) But I didn’t know about it then, and so I get to tell the story now.

Exasperated, I turned in my exam when time was called, and I asked my teacher how this integral was supposed to be solved.

Easy, she told me: just square out the inside:

\displaystyle \int (x^2+1)^2 dx = \displaystyle \int (x^4 + 2x^2 + 1) \, dx = \displaystyle \frac{x^5}{5} + \frac{2x^3}{3} + x + C

At the time, I was unbelievably annoyed at myself. Now, I love telling this anecdote to my students as I relate to their own frustrations as they practice the art of integration.

Functions that commute

At the bottom of this post is a one-liner that I use in my classes the first time I present a theorem where two functions are permitted to commute. At many layers of the mathematics curriculum, students learn about that various functions can essentially commute with each other. In other words, the order in which the operations is performed doesn’t affect the final answer. Here’s a partial list off the top of my head:

  1. Arithmetic/Algebra: a \cdot (b + c) = a \cdot b + a \cdot c. This of course is commonly called the distributive property (and not the commutative property), but the essential idea is that the same answer is obtained whether the multiplications are performed first or if the addition is performed first.
  2. Algebra: If a,b > 0, then \sqrt{ab} = \sqrt{a} \sqrt{b}.
  3. Algebra: If a,b > 0 and x is any real number, then (ab)^x = a^x b^x.
  4. Precalculus: \displaystyle \sum_{i=1}^n (a_i+b_i) = \displaystyle \sum_{i=1}^n a_i + \sum_{i=1}^n b_i.
  5. Precalculus: \displaystyle \sum_{i=1}^n c a_i = c \displaystyle \sum_{i=1}^n a_i.
  6. Calculus: If f is continuous at an interior point c, then \displaystyle \lim_{x \to c} f(x) = f(c).
  7. Calculus: If f and g are differentiable, then (f+g)' = f' + g'.
  8. Calculus: If f is differentiable and c is a constant, then (cf)' = cf'.
  9. Calculus: If f and g are integrable, then \int (f+g) = \int f + \int g.
  10. Calculus: If f is integrable and c is a constant, then \int cf = c \int f.
  11. Calculus: If f: \mathbb{R}^2 \to \mathbb{R} is integrable, \iint f(x,y) dx dy = \iint f(x,y) dy dx.
  12. Calculus: For most differentiable function f: \mathbb{R}^2 \to \mathbb{R} that arise in practice, \displaystyle \frac{\partial^2 f}{\partial x \partial y} = \displaystyle \frac{\partial^2 f}{\partial y \partial x}.
  13. Probability: If X and Y are random variables, then E(X+Y) = E(X) + E(Y).
  14. Probability: If X is a random variable and c is a constant, then E(cX) = c E(X).
  15. Probability: If X and Y are independent random variables, then E(XY) = E(X) E(Y).
  16. Probability: If X and Y are independent random variables, then \hbox{Var}(X+Y) = \hbox{Var}(X) + \hbox{Var}(Y).
  17. Set theory: If A, B, and C are sets, then A \cup (B \cap C) = (A \cup B) \cap (A \cup C).
  18. Set theory: If A, B, and C are sets, then A \cap (B \cup C) = (A \cap B) \cup (A \cap C).

However, there are plenty of instances when two functions do not commute. Most of these, of course, are common mistakes that students make when they first encounter these concepts. Here’s a partial list off the top of my head. (For all of these, the inequality sign means that the two sides do not have to be equal… though there may be special cases when equality happens to happen.)

  1. Algebra: (a+b)^x \ne a^x + b^x if x \ne 1. Important special cases are x = 2, x = 1/2, and x = -1.
  2. Algebra/Precalculus: \log_b(x+y) = \log_b x + \log_b y. I call this the third classic blunder.
  3. Precalculus: (f \circ g)(x) \ne (g \circ f)(x).
  4. Precalculus: \sin(x+y) \ne \sin x + \sin y, \cos(x+y) \ne \cos x + \cos y, etc.
  5. Precalculus: \displaystyle \sum_{i=1}^n (a_i b_i) \ne \displaystyle \left(\sum_{i=1}^n a_i \right) \left( \sum_{i=1}^n b_i \right).
  6. Calculus: (fg)' \ne f' \cdot g'.
  7. Calculus \left( \displaystyle \frac{f}{g} \right)' \ne \displaystyle \frac{f'}{g'}
  8. Calculus: \int fg \ne \left( \int f \right) \left( \int g \right).
  9. Probability: If X and Y are dependent random variables, then E(XY) \ne E(X) E(Y).
  10. Probability: If X and Y are dependent random variables, then \hbox{Var}(X+Y) \ne \hbox{Var}(X) + \hbox{Var}(Y).

All this to say, it’s a big deal when two functions commute, because this doesn’t happen all the time.

green lineI wish I could remember the speaker’s name, but I heard the following one-liner at a state mathematics conference many years ago, and I’ve used it to great effect in my classes ever since. Whenever I present a property where two functions commute, I’ll say, “In other words, the order of operations does not matter. This is a big deal, because, in real life, the order of operations usually is important. For example, this morning, you probably got dressed and then went outside. The order was important.”

 

How to check if a student really can perform the Chain Rule

In my experience, a problem like the following is the acid test for determining if a student really understands the Chain Rule:

Find f'(x) if f(x) = \left[6x^2 + \sin 5x \right]^3

The correct answer (unsimplified):

f'(x) = 3 \left[6x^2 + \sin 5x \right]^2 \left(12x + [\cos 5x] \cdot 5 \right)

However, even students that are quite proficient with the Chain Rule can often provide the following incorrect answer:

f'(x) = 3 \left[6x^2 + \sin 5x \right]^2 \left(12x + \cos 5x \right) \cdot 5

Notice the slightly incorrect placement of the 5 at the end of the derivative. Students can so easily get into the rhythm of just multiplying by the derivative of the inside that they can forget where the derivative of the inside should be placed.

Needless to say, a problem like this often appears on my exams as a way of separating the A students from the B students.

Teaching the Chain Rule inductively

I taught Calculus I every spring between 1996 and 2008. Perhaps the hardest topic to teach — at least for me — in the entire course was the Chain Rule. In the early years, I would show students the technique, but it seemed like my students accepted it on faith that their professor knew what he was talking about it. Also, it took them quite a while to become proficient with the Chain Rule… as opposed to the Product and Quotient Rules, which they typically mastered quite quickly (except for algebraic simplifications).

It took me several years before I found a way of teaching the Chain Rule so that the method really sunk into my students by the end of the class period. Here’s the way that I now teach the Chain Rule.

On the day that I introduce the Chain Rule, I teach inductively (as opposed to deductively). At this point, my students are familiar with how to differentiate y = x^n for positive and negative integers n, the trigonometric function, and y = \sqrt{x}. They also know the Product and Quotient Rules.

I begin class by listing a whole bunch of functions that can be found by the Chain Rule if they knew the Chain Rule. However, since my students don’t know the Chain Rule yet, they have to find the derivatives some other way. For example:

Let y = (3x - 5)^2. Then

y = (3x - 5) \cdot (3x -5)

y' = 3 \cdot (3x -5) + (3x -5) \cdot 3

y' = 6(3x-5).

Let y = (x^3 + 4)^2. Then

y = (x^3 + 4) \cdot (x^3 + 4)

y' = 3x^2 \cdot (x^3 + 4) + (x^3 + 4) \cdot 3x^2

y' = 6x^2 (x^3 + 4)

Let y = (\sqrt{x} + 5)^2. Then

y = x + 10 \sqrt{x} + 25

y' = 1 + \displaystyle \frac{5}{\sqrt{x}}

Let y = \sin^2 x. Then

y = \sin x \cdot \sin x

y' = \cos x \cdot \sin x + \sin x \cdot \cos x

y' = 2 \sin x \cos x

Let $y = \sin 2x$. Then

y = 2 \sin x \cos x

y' = 2 \cos x \cos x - 2 \sin x \sin x

y' = 2 (\cos^2 x - \sin^2 x)

y' = 2 \cos 2x

The important thing is to list example after example after example, and have students compute the derivatives. All along, I keep muttering something like, “Boy, it would sure be nice if there was a short-cut that would save us from doing all this work.” Of course, there is a short-cut (the Chain Rule), but I don’t tell the students what it is. Instead, I make the students try to figure out the pattern for themselves. This is absolutely critical: I don’t spill the beans. I just wait and wait and wait until the students figure out the pattern for themselves… though I might give suggestive hints, like rewriting the 6 in the first example as $\latex 3 \times 2$.

This can take 20-30 minutes, and perhaps over a dozen examples (like those above), as students are completely engaged and frustrated trying to figure out the short-cut. But my experience is that when it clicks, it really clicks. So this pedagogical technique requires a lot of patience on the part of the instructor to not “save time” by giving the answer but to allow the students the thrill of discovering the pattern for themselves.

Once the Chain Rule is discovered, then my experience is that students have been prepared for differentiating more complicated functions, like y = \sqrt{4 + \sin 2x} and y = \cos ( \sqrt{x} ). In other words, there’s a significant front-end investment of time as students discover the Chain Rule, but applying the Chain Rule generally moves along quite quickly once it’s been discovered.

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.