Foxmaths! 2.0

February 10, 2009

Math: A Different Perspective

Filed under: Maths — Fox @ 5:32 am

First, I would like to draw your attention to this article, about a processor that uses probabilistic calculations, and as such, runs 7 times as fast and at 1/30th the power of conventional hardware. The basic idea is, what information do you -really- need?

Which brings me to the point at hand. I am a math person, first and foremost. But for the last three years or so, I’ve also been pursuing physics a great deal. For the most part, if you know math, then physics is relatively easy. But, physics also provides a different perspective on math that I think is very important. In math, there is a tendency to get lost in symbolic manipulations, algorithms, problems of a specific type, and forget what the math is ‘actually’ saying. You can become entrenched. Blinded, almost. In physics, math is often treated as almost an obstacle to be dealt with. Something to be worked around to get at the ‘real’ answer. At least, the relevant answer. It’s fascinating to me. The solution is often to not do the problem at all. Doing by not doing. Math without math. And yet, at the same time, it gets straight to the matter of what the math is trying to express, and in the processes, helps you develop an intuition for it.

And if none of that made sense, here is an example. Consider the expression, for a positive value of x,

\sum_{j = 0}^\infty (2j + 1)\ e^{-j(j+1)x}

In general, we want to understand the behavior of that function with respect to x. Now, as a mathematician, I jump in and think, hmmm. What does that summation converge to? Can we express it in a nicer formula? Things start to jump out, generating functions, possible Taylor summations, etc, any one of which could be used to turn that summation into something recognizable. Usable.

But then, staring at the summation a good long while … nothing forms. The usual power series formulas are no help, due to the quadratic nature of the exponent. And the factor of (2j+1) in front of the exponent certainly complicates things. The form of the summation fits to nothing I recall seeing, ever. Asking Mathematica, it can’t find any convenient expression for the sum either. General maths suggest no reasonable way of turning this summation into something tractable. And, if we wanted to do more interesting things to that summation, such as take the log, and then various derivatives, by keeping the entire summation, formulas would rapidly turn quite nasty.

So, what is there to be done? How best to do that summation? How can we really appreciate what this function is? The answer is, to not do the summation.

Notice that, for value large, positive values of x, e^{-x} is very very small, approaching 0 as x increases. In our summation, this means that for very large values of x, e^{-j(j+1)x} starts small, and gets smaller as j increases. Writing out the first few terms,

\sum_{j = 0}^\infty (2j+1)e^{-j(j+1)x} = 1 + 3 e^{-2x} + 5 e^{-6x} + 7e^{-12x} + ...

Notice that as small as that first exponential term is, the second exponential is that cubed. And the third is that to the 6th. If e^{-2x} = 0.01 , then e^{-6x} = 0.000001 , and e^{-12x} = 0.000000000001 . So the terms of the summation go to zero, very very fast. As such, for sufficiently large x, we can assume all sufficiently small terms -are- zero. Thus we get the approximation,

\sum_{j = 0}^\infty (2j+1)e^{-j(j+1)x} \approx 1 + 3 e^{-2x}

Notice, we keep at least one non-constant term so we have some idea of how the sum is changing for large x. This is very nice! Very simple.

We also want to consider what the expression acts like, for very small values of x. Notice that for very small values of x, e^{-x} is very close to 1. This means that, unlike before, the terms of the summation do not drop off nearly as fast, and we need to include far more of them to approximate the summation well. Therefore, we will approximate the summation by an integral.

\sum_{j = 0}^\infty (2j + 1)e^{-j(j+1)x} \approx \int_{0}^\infty (2j+1)e^{-j(j+1)x} dj

Now, as it turns out, that integral is actually rather straightforward. Using the substitution y = x*j*(j+1), we can transform it thusly.

\int_{j = 0}^\infty (2j+1)e^{-j(j+1)x} dj  = \frac{1}{x} \int_{0}^{\infty} e^{-y} dy = \frac{1}{x}

A beautifully simple approximation.

To summarize, for very large values of x,

\sum_{j = 0}^\infty (2j + 1)e^{-j(j+1)x} \approx 1 + 3 e^{-2x}

For very small values of x,

\sum_{j = 0}^\infty (2j + 1)e^{-j(j+1)x} \approx \frac{1}{x}

In both cases, the approximations are simple enough that further manipulation (derivatives, etc) becomes relatively straightforward. At this point, you may, and rightly so, demand proof – just how good are these approximations?

For very small x, say x = 0.001, the summation gives approximately 1000.33, while the approximation gives 1000. And the approximation only gets better the closer x gets to zero.

For very large x, say x = 3, the summation gives approximately 1.00743633, while the approximation gives 1.00743625. And again, it only gets better as x gets larger. Of course, taking it to the extreme limit, you might as well approximate the summation as 1.

But, more interestingly, these approximations are very good, over almost all values of x. Consider the following graph.

swendsen

The top curve is the summation. The two approximations are beneath it. You can see from the graph that the limiting behavior of the summation is as anticipated. But, you can also see that, over the full range of x, the approximations are not bad at all. Given that we implicitly assumed x was either very very large or very very small, I find that agreement for midsized x quite surprising.

And that is my point. Sometimes the best solution is to ignore the problem. And, in analyzing the function this way, it presents the behavior of the function in a way the summation obscures. I think being able to appreciate math in this way is a very important thing, lest it become a game of irrelevant symbol juggling. For other examples of this, I highly recommend Built On Facts. Matt Springer does a good job of presenting good math in a very accessible fashion. It’s good stuff.

And! If all this approximating is just too much for you, consider this. Numerically, at the very least, Mathematica suggests the following limit.

lim_{x \rightarrow 0^+ } (\sum_{j = 0}^\infty (2j + 1)e^{-j(j+1)x} - \frac{1}{x}) = \frac{1}{3}

How do you feel about that?

4 Comments »

  1. This is a great write up. You should submit it to a carnival.

    Comment by Ben — February 10, 2009 @ 5:16 pm

  2. Thanks!

    I realized after the fact that I really should’ve done (2j)e^(-x*j^2). It at least looks nicer, and you can do the same thing with it. Even get that same limit at the end.

    But this particular form arose in a quantum mechanical calculation, where the energy of a certain state was j*(j+1)*E, and the degeneracy of the state was (2j + 1). That the degeneracy is the derivative of the energy in this case fascinates me, if only because it lets you do that integral : )

    Comment by Fox — February 11, 2009 @ 4:20 am

  3. [...] there’s  Math: A Different Perspective at Foxmaths! 2.0, in which Foxy derives some nice approximations for a complicated summation; these [...]

    Pingback by The 49th Carnival of Mathematics! « 360 — February 14, 2009 @ 1:53 am

  4. This is one of those tricks I put in the ‘irks but works’ category. It reminds me of various ‘common’ percentage numbers for confidence intervals, or various numbers for R-squared. The tricks work if you handle them relatively carefully and know what you’re doing. Which is a caveat not everyone follows, unfortunately :)

    Comment by Jon — February 18, 2009 @ 11:30 pm


RSS feed for comments on this post. TrackBack URI

Leave a comment

Blog at WordPress.com.