# Thomas Eckert

< writing /

## Approximation by Taylor Series

8 Nov 2018 | Rochester, NY

Last Winter, I was driving from Ottawa, Ontario to Rochester, New York. I pulled off the highway to make a quick stop and found that I couldn't get back on. This was precarious as I don't have a data plan in Canada or map of the area I was traveling through. As this photo taken by Sophia on a similar drive shows, the area is lovely to look at but not very hospitable that time of year.

To solve the problem of getting to the border and back to Rochester, I had to figure out some working solution. So, I used a compass. Thankfully, the United States is large enough that if I continuously drove South, I was bound to hit it!

I had, what is called in mathematics, a first-order solution: drive south-southwest. As I gathered more information, I was able to form a second-order solution: follow the signs for Route 401. Then a third-order: follow Route 401 West.

Before I knew it, I was at the border and could turn on my phone's data again. Although I don't want to be stuck in such a position again, I have to admit there is something satisfying about solving a problem by starting off in a direction and adding details as I go along. It got me thinking about how frequently I use this type of problem solving and how the structure behind it is so similar to that of a Taylor Series.

James Gregory

Brook Taylor

The Taylor Series was formulated by James Gregory but it is named after Brook Taylor, who formally presented it. It is a method of approximating a function by taking a general shape of the function and adding finer and finer details until it eventually resembles, and sometimes equals, the original function. In this way, we bring the original function into focus.

In undergrad, my advisor Dr. Yuly, spoke endlessly about the virtues of the Taylor Series. At first, I thought they were a neat mathematical trick, but since then I have found them to be indispensable to solving some incredibly complex problems.

In the same way Dr. Yuly's endorsement alone didn't convince me of the Taylor Series' beauty, I doubt my advocacy would bring the average reader into this fold of belief. Instead, I want to walk through one example to give the reader a taste of its elegance.

### II. The Philosophy of the Taylor Series

Imagine a vehicle approaching from a distance. The first things we might notice about the car are probably its color and size. As the vehicle gets closer, we can make further observations: speed, make, model, year, who is driving, etc. We add these to our description of the vehicle until we have a good approximation of what we are seeing.

One great thing about the Taylor Series is that we determine what a good approximation is. If all we need to know about a vehicle is its color, instead of making a complete study of it, we can quickly glance at it from a distance. This saves us time and energy.

This is where I really see a use for the Taylor Series outside of mathematics. It represents a thought process that resonates well with how I try to solve problems. While I probably use a Taylor Series every week or so in work, I use the philosophy behind it daily.

When I schedule my day, I begin with the important, immovable things I have to do and fill in the gaps with increasingly minute details. When I paint, I begin with structural elements that give the image depth and form then fill in smaller parts of the canvas until it is complete. When I write a post, I begin with the idea that runs through the whole of the piece and figure out exact wording as I go along.

### III. A Mathematical Example to Get Your Blood Pumping

Let's look at an example of a Taylor Series, graphically at first, and simply admire it. Here, we will be using what is technically a MacLaurin Series, because it is centered about $$x=0$$. We will be approximating a Sine function. The function itself looks like this:$$y(x) = \sin(x)$$

The first-order approximation is $$y(x)=x$$. It looks nothing like the sine function yet, aside from being zero and having an upward trend on either side of the origin.

The second-order approximation, $$y(x)=x−\frac{x^3}{6}$$, brings in some of the expected curvature.

The third-order approximation, $$y(x)=x−\frac{x^3}{6} +\frac{x^5}{120}$$, is funky and getting closer.

If we can see where things are going here, let's skip ahead to the fifth-order approximation$$y(x)=x−\frac{x^3}{6} +\frac{x^5}{120} −\frac{x^7}{7!} +\frac{x^9}{9!}$$where I'm sure we all remember that the excited numbers represent factorials.

By the seventh-order approximation, the series looks very much like our sine function, at least in the region we are looking at. If you zoom out on the plot, you can see how it diverges at the edges: