6
$\begingroup$

I wonder how Wolfram can solve this series and provide the solution symbolically:

$$\sum_{k=1}^\infty\frac 1{(2k-1)^4}$$

In this particular case I know how to use a Fourier series on a triangle function to get the result by employing Parseval's theorem, but this is only a particular example. The proof for $\sum_{k=1}^{k=\infty} \frac{1}{k^2} = \frac{\pi^2}{6}$ was found by Euler and uses a taylor series of a special function.

But is there a recipe working correctly for each possible series? I cannot imagine that such algorithm exists. But how can Wolfram do it?

  • 1
    Presumably wolfram just knows some special cases, like $\sum\limits_{k=1}^{\infty}\frac{1}{k^s}$, and performs some simple manipulations on rational functions to get the result in terms of the known sums.2017-02-03
  • 1
    For indefinite integrals, they have a complicated algorithm, trying to transform the function into some kind of very [general function](https://en.wikipedia.org/wiki/Meijer_G-function) for which the primitive are known. For definite integrals and series, there is no such trick/theory, and the algorithm is probably "get a huge database of particular cases and transformation rules, and use backtracking". Also, when the function `HurwitzZeta[s,a]=Series[(n+a)^(-s),{n,0,Infinity}]` is implemented in WA, when you type `Series[(2*n+a)^{1-s}, {n,0,Infinity}]` the algorithm automatically recognizes it2017-02-03
  • 1
    This is a very interesting question that I'd love to see a detailed answer to. You might want to try to ask it at [Mathematica SE](http://mathematica.stackexchange.com/) instead as they are more likely to have people (some users there are developers of Mathematica) who knows this better (Mathematica is made by Wolfram and it's likely the same code that is used by Alpha to evaluate this). Here you are more likely to get completely off-topic answers like two of the answers below that don't even try to answer the question.2017-02-04

3 Answers 3

5

I bet that WolframAlpha has a database of the most common expressions. Wolfram publicly provides a huge list of functions, containing various series expansions of most functions, so it's not very hard to build an optimized database with the mapping series$\to$function.

For example, WolframAlpha returns $$\sum_{k=1}^\infty\frac 1{(k+a)^n} = \zeta(n, a+1)\text.$$

To evaluate your input, apply a general technique: try to eliminate any integer factors from the summation variable. $$\sum_{k=1}^\infty\frac 1{(2k-1)^4}=\sum_{k=1}^\infty\frac1{2^4}\cdot\frac 1{(k-\frac12)^4}=\frac1{16}\cdot\sum_{k=1}^\infty\frac 1{(k-\frac12)^4}=\frac1{16}\cdot\zeta(4, 1/2)$$

Now, without even knowing what this $\zeta$ function is, we just need to know the value at the point $(4,1/2)$, and we're done.

There is a database of special values of this function. It does not contain $(4, 1/2)$ though.

So, try the transformation database. It has $$\zeta(n, 1/2)=(2^n-1)\zeta(n)$$ which brings us to another $\zeta$ function (one argument). Again, we need to know nothing about the function, just its value at $n=4$. Here, the database yields $$\zeta(4)=\frac{\pi^4}{90}$$

and we're done.


Disclaimer: I don't know exactly how WolframAlpha works, so this is just a guess.

  • 0
    Not sure if WolframAlpha just directly looks this one up in a database: http://functions.wolfram.com/02.03.06.0032.012017-02-03
  • 0
    I don't think this is quite as simple. If I were to design such a system, a simple lookup would certainly be a part of it, but I think it's quite likely it also does some kind of BFS, applying some various transformations, and trying to reach some familiar form.2017-02-04
0

If you can show that

$$\sum_{n=1}^\infty\frac1{n^2+x}=-\frac1{2x}+\frac\pi{2\sqrt x\tanh(\pi\sqrt x)}$$

Then just differentiate a few times and plug in appropriate values for $x$. You can likewise solve the following series:

$$\sum_{n=1}^\infty\frac1{(ak+x)^2}$$

Differentiate twice and put $a=2$ and $x=-1$.

0

I do not know how symbolic programs evaluate series in closed form. But I thought it might be instructive to see one methodology to solve the problem of interest. It is to that end we now proceed.


Note that $\zeta(4)=\sum_{n=1}^\infty\frac{1}{n^4}$. Next, we can write $\zeta(4)$ as

$$\begin{align} \zeta(4)&=\sum_{n=1}^\infty\frac{1}{n^4}\\\\\ &=\sum_{n=1}^\infty\frac{1}{(2n-1)^4}+\sum_{n=1}^\infty\frac{1}{(2n)^4}\tag 1 \end{align}$$

by pairing even and odd terms. But $\sum_{n=1}^\infty\frac{1}{(2n)^4}=\frac1{16}\zeta(4)$. Using this in $(1)$ and solving for the term of interest reveals

$$\sum_{n=1}^\infty\frac{1}{(2n-1)^4}=\frac{15}{16}\zeta(4)$$


FINDING $\displaystyle \zeta(4)$:

To find $\zeta(4)$, we can use contour integration. Let $f(z)=\frac{\pi \cot(\pi z)}{z^4}$ and $C$ be a circular contour of radius $N+1/2$. Then, we have

$$\begin{align} \oint_C \frac{\pi \cot(\pi z)}{z^4}\,dz&=2\pi i \sum_{n=-N}^N \text{Res}\left(\frac{\pi \cot(\pi z)}{z^4}, z=n\right)\\\\ &=2\pi i \sum_{|n|\ge 1} \frac1{n^4}+2\pi i \text{Res}\left(\frac{\pi \cot(\pi z)}{z^4}, z=0\right) \tag 2 \end{align}$$

As $N\to \infty$, the integral in $(2)$ approaches $0$. Hence, from $(2) we have

$$\sum_{n=1}^\infty \frac1{n^4}=-\frac12 \text{Res}\left(\frac{\pi \cot(\pi z)}{z^4}, z=0\right) \tag 3$$


EVALUATING THE RESIDUE AT $0$:

Noting that $z=0$ is a fifth-order pole, we could calculate the residue by applying the formula

$$\text{Res}\left(\frac{\pi \cot(\pi z)}{z^4}, z=0\right)=\frac1{4!}\lim_{z\to 0}\frac{d^4 (\pi z \cot(\pi z))}{dz^4} $$

Rather than pursue this approach, we expand the integrand as

$$\begin{align} \frac{\pi\cot(\pi z)}{z^4}&= \frac{1-\frac12(\pi z)^2+\frac{1}{24}(\pi z)^4+O(z^6)}{ z^5\left(1-\frac16 (\pi z)^2+\frac{1}{120}(\pi z)^4+O(z^6)\right)}\\\\ &=\frac{1}{z^5}\left(1-\frac12(\pi z)^2+\frac{1}{24}(\pi z)^4+O(z^6)\right)\left(1+\frac16 (\pi z)^2+\frac{7}{360}(\pi z)^4+O(z^6)\right) \end{align}$$

The residue is the coefficient on the term $z^{-1}$. Therefore,

$$\text{Res}\left(\frac{\pi \cot(\pi z)}{z^4}, z=0\right)=\left(-\frac1{12}+\frac{1}{24}+\frac{1}{360}\right)\,\pi^4=-\frac{\pi^4}{45} \tag 4$$


Using $(4)$ in $(3)$ we find that $\zeta(4)=\frac{\pi^4}{90}$. And finally, we have

$$\sum_{n=1}^\infty\frac{1}{(2n-1)^4}=\frac{\pi^4}{96}$$

And we are done!

  • 2
    Would the cowardly down voters care to comment?2017-02-04
  • 3
    You are not even trying to answer the question at hand and you are surprised? Shocking.2017-02-04
  • 0
    @winther Drop the sarcasm. Or is that simply built into your character? And read the preamble.2017-02-04
  • 3
    Are you interested in feedback or is the comment above just for yourself? I just gave you the feedback you asked for. This is a completely off-topic answer. This is a question about algorithms for symbolic math and OP clearly states that the series is just an example.2017-02-04
  • 0
    @Winther I disagree, there is nothing wrong with this answer.2017-02-04
  • 2
    @SimplyBeautifulArt Given that you have also added a completely off-topic answer that is not that surprising to hear. If you feel like answering a different question then ask it yourself and add an answer to it there. This is an interesting question and these answers just adds noise to it.2017-02-04
  • 0
    "But is there a recipe working correctly for each possible series? I cannot imagine that such algorithm exists. But how can Wolfram do it?" I provided an answer that explains how one could tackle this problem for almost any series of a form close to the OP's example. Clearly, it is impossible for me to provide an algorithm to solve all problems, and I don't know how WolframAlpha does it, so I tackled a similar more general problem. What is off-topic with that?2017-02-04
  • 0
    @winther Feedback is fine. I said "Drop the sarcasm." Your reply was, therefore, "off of that topic." Hypocrisy does not become you. ;-)2017-02-04