# Speedier Algorithm or Set of Steps to Increase Speed of Coefficient Generation

Good morning. I am working with higher powers of the Generalized Euler Number generating function

$$\left[\frac{n}{\sum_{j=0}^{n-1}\exp{\left(w_n^jx\right)}}\right]^\alpha$$

where $w_n=\exp{\left(2i\pi/n\right)}$. This can be written in terms of what are called Olivier functions, where

$$\Phi_{n,k}(x)=\frac{1}{n}\sum_{j=0}^{n-1}w_n^{-jk}\exp{\left(w_n^jx\right)}$$

and thus I can rewrite the exponential generating function as

$$\left[\frac{1}{\Phi_{n,0}(x)}\right]^\alpha=\sum_{j=0}^\infty{A_{n,0}^{(\alpha)}\frac{x^j}{j!}}$$

My goal is to generate the first fifty or so numbers for varying $\alpha$. So I use the following definitions to help in Mathematica:

 w[n_] := E^((2*i*\Pi)/n)
Phi[n_, k_, x_] := (1/n)*Sum[(w[n]^(-j*k)*E^(x*w[n]^j)), {j, 0, n - 1}]
NEuler[a_, n_, x_] := (1/Phi[n, 0, x])^a
NENumber[a_, n_, r_, M_] :=
FullSimplify[Coefficient[r! Normal[Series[NEuler[a, n, x], {x, 0, M}]], x, r]]


My problem here is when I go to evaluate say

 Table[NENumber[2, 3, j, M], {j, 0, M}]


If $M>20$ it seems that the calculation never actually evaluates, or if it will, it takes way too long. Is there another method in order to generate these numbers much more quickly and efficiently on my computer? My math skills are better than my Mathematica skills, as I have definitely never had formal instruction using Mathematica, and everything that I've learned I've learned by myself. Thank you for your help.

• I and i are two very different things. Thus: OlivierPhi[n_, k_, x_] := Sum[Exp[x Exp[2 π I j/n] - 2 π I j k/n], {j, 0, n - 1}]/n; With[{n = 2, a = 3}, Table[j! SeriesCoefficient[(1/OlivierPhi[n, 0, x])^a, {x, 0, j}] // RootReduce, {j, 0, 20}]] Jul 24 '16 at 14:05
• I usually use the symbolic i on the palettes. So I assume then that >I is the imaginary number? Jul 24 '16 at 14:13
• Yes, I is the imaginary unit in InputForm[]; the "fancy i" should have automatically pasted as I here if you copied things right. Jul 24 '16 at 14:14
• I actually didn't cut and paste, I just recalled from memory and typed it in. And ha ha to "fancy i"... Thanks I'm going to try this now. Jul 24 '16 at 14:15
• I am running into problems with $n=3,a=2$ and table from 0 to 40. Since $n=3$ yields complex roots of unity, is this the reason? It has been evaluating for about 5 minutes now... Jul 24 '16 at 14:29

It turns out the Olivier function is already built-in, but in a disguised form:

With[{n = 3, a = 2},
Table[j! SeriesCoefficient[1/MittagLefflerE[n, x^n]^a, {x, 0, j}],
{j, 0, 40}]]
{1, 0, 0, -2, 0, 0, 58, 0, 0, -6218, 0, 0, 1630330, 0, 0, -847053482, 0, 0,
766492673914, 0, 0, -1106653345942538, 0, 0, 2392407356983116538, 0, 0,
-7379716460043385709162, 0, 0, 31273642050397659221050618, 0, 0,
-176597979883794828225332275658, 0, 0, 1295782854051144759324367927117690, 0, 0,
-12096399366143533384617425907661145642, 0}


If you are using an older version that does not have the Mittag-Leffler function, here is some alternative code:

With[{n = 3, a = 2},
Table[j! SeriesCoefficient[1/HypergeometricPFQ[{}, Range[n - 1]/n, (x/n)^n]^a,
{x, 0, j}], {j, 0, 40}]]