*You might also like to read the first part of this article.*

This article is about the integral of , given by calculus using the formula

(1) |

(2) |

(1) |

This suggestion was made rather cryptically in the article [1] referenced below. So why is (3) better than (1)?

First consider the (easy) case . If we fix and differentiate then we obtain

### Does it matter?

Leonhard Euler, 1707-1783, made significant contributions to the development of calculus.

First let us consider why the exceptional case matters. After all, it is only one point out of an infinity of other values for . The formula (1) is valid for all , so why not just ignore this singular awkward case? Intriguingly, in mathematics such exceptional cases occur rather more often than you might expect if you just stuck a pin in the number line, or even if you chose an integer at random. The article [1], where the suggestion that (3) might be better than (1) appears, is concerned with computer algebra systems, which are rather like advanced calculators. They can manipulate algebraic expressions and perform *symbolic* manipulations such as differentiation and integration. They work at a symbolic level — just as we
are when we are manipulating expressions containing letters to represent numbers — rather than by using approximate numerical values. In a symbolic machine that does not know a value for , automatically using the formula (1) might result in an error creeping into a much longer calculation. Mistakes like this are very hard to track down and can lead to serious malfunctioning of the whole program.

### The special case *k*=-1 and Euler's special formula

If we try to substitute into the right hand side of

*limit*, that is

To do this we shall make use of a formula discovered by Leonhard Euler. Euler showed that

Use the slider to increase |

If you are still skeptical, here is a proof of this identity.

At first glance, the limit

Use the slider to change the value of |

So we can say that (3) is indeed valid for all , including the special case , when we define the value of (3) in this case by the limit This limit happens to give the right answer to the integral for In this sense (3) is indeed somewhat better than (1). The key to all of this is to choose the constant of integration in (1) so that the resulting formula also holds in the awkward limiting case, This sort of arbitrary choice looks like a "wizard's trick" the first time you see it, but like many tricks in mathematics it is a technique which occasionally has useful applications elsewhere.

### Have a go yourself

If this article has inspired you to do some calculus, here is a problem for you:

Write . Integrate the right hand side by parts. Explain why this, and any similar method, fails to find the integral of .

### Reference

[1] D.R. Stoutemyer, *Crimes and misdemeanors in the computer algebra trade*, Notices of the American Mathematical Society, 38(7):778--785, September 1991.

Chris Sangwin is a member of staff in the School of Mathematics at the University of Birmingham. He is a Research Fellow for the Higher Education Academy MSOR Network. He has written the popular mathematics books *Mathematics Galore!*, with Chris Budd, and How
round is your circle? with John Bryant, and edited Euler's Elements of Algebra.