# p-norm of series / Mathematica

When computing the $p$-norm of the series $x_n = \mathrm e^{\mathrm i n}$ for $n \in \mathbb{Z}$ (not $\mathbb{N}$), the sum should not converge:

$$\|x\|_p^p = \sum_{n \in \mathbb{Z}} (\mathrm e^{\mathrm i n})^p = \sum_{n \in \mathbb{Z}} (\mathrm e^{\mathrm i p})^n$$ and $|\mathrm e^{\mathrm i p}|=1$, so the series diverges.

For $p = 1$ this is also the result of Mathematica and Wolfram Alpha. However, using general $p$, the result of Mathematica and Wolfram Alpha is 0. This is strange. What am I missing here?

-
That $|e^{ip}| = 1$ does not force the sum to diverge. The sum simply doesn't converge to a single value. It's analogous to what happens for $\sum_{n \in \mathbb{Z}} (-1)^n$. The sums in Wolfram alpha are finite so they most definitely do exist. –  JavaMan Jan 31 '12 at 21:52
I agree with your first statement. The sum does not converge, thus it diverges; however whether it properly diverges (which it does not) or alternates or whatever, is not interesting at the moment. However, Mathematica and Wolfram Alpha use symbolic math for series - they should return the correct result. Bug? –  Nancy Miller Jan 31 '12 at 22:09
If I try Sum[Exp[I k p], {k, -Infinity, Infinity}] in both Alpha and Mathematica, I get the "sum does not converge" warning. For Sum[Exp[I k]^p, {k, -Infinity, Infinity}] I get the erroneous result, but Assuming[Element[p, Reals], Sum[Exp[I k]^p, {k, -Infinity, Infinity}]] gives the right one. –  Ｊ. Ｍ. Feb 1 '12 at 0:08

Your series is indeed divergent but in Fourier series (and distribution theory) we may formally write : $$\delta(x)=\frac1{2 \pi} \sum_{n=-\infty}^{\infty} e^{i nx}$$ with $\delta$ the Dirac Delta distribution

From this point of view your infinite sum will be $2\pi\delta(x)$ that is $0$ for $x\ne 0$ and $\infty$ for $x=0$.

Another related form of the Dirac distribution is this integral :

$$\delta(x)=\frac1{2 \pi}\int_{-\infty}^{\infty} e^{i t x} dt$$

The Fourier inversion theorem may help too (less distribution theory required!).

EDIT: Coming back to your second Alpha link I should add that (the first time) I got : $$\sum_{n=-\infty}^{\infty} \exp^p(i n) = \frac{(e^i)^p-e^{i p}}{(-1+(e^i)^p) (-1+e^{i p})}$$

After that I got $0$ and indeed the numerator of this answer is $0$.

I don't know the rules used by Mathematica to get this (perhaps a limited sum process turning wrong or right or whatever at the limit!) but anyway these very powerful tools should not be considerer as references! They make assumptions (for example that your variables are complex numbers), apply rules that may be conflicting (real or complex analysis versus germs of distribution theory) and simplify at each stage with perhaps inapplicable methods (during a computation of limit for example). So that, sometimes, you'll get discussable answers... especially when considering divergent expressions!

-
So, one could say, the result from Mathematica / Wolfram Alpha only holds in a $L^p(\mathbb{R})$-sense, i.e. when we do not care about null sets? –  Nancy Miller Jan 31 '12 at 22:27
Hmmmm Mathematica is a formal system so that it will apply the incorporated substitutions : see at the bottom of this documentation for some of its rules concerning delta. I don't think mathematical ideas as $L^p(\mathbb{R})$ are used (else as for inspiration). Axiom, a more mathematically oriented C.A.S., could perhaps take these concepts in account... –  Raymond Manzoni Jan 31 '12 at 22:42
@Nancy: from the point of view of distributions : (en.wikipedia.org/wiki/Distribution_(mathematics)) (you'll have to select the mathematics link sorry..) functions are replaced by classes of functions (larger than and including the $L^p$ functions) : two functions identical except at a point will belong to the same class. –  Raymond Manzoni Jan 31 '12 at 23:00