# Errors when plotting $\operatorname{Re}\sum_{n=1}^{200} \frac{(a\ln x)^n}{n!\, n\zeta (n+1)}$ in $x$

Let $$a=1/2-30.424876126i$$ ($$i^2=-1$$). Then trying to plot $$\operatorname{Re}\sum_{n=1}^{200} \frac{(a\ln x)^n}{n!\, n\zeta (n+1)}$$ in $$x$$ leads to a very inaccurate jaggy graph possibly caused by some floating point errors:

a:=1/2-30.424876126I
f[x_]:=Sum[(a Log[x])^n/(n! n Zeta[n+1]),{n,1,200}]
Plot[Re[f[x]],{x,1,5}]


The beginning of the graph is good, though. How can the errors be mitigated?

• If your value of a is supposed to be a zero of the zeta function, have you also tried including more decimal values? Jul 20 at 23:59
• @zeattledave Combining SetPrecision and WorkingPrecision solved the problem.
– Wane
Jul 21 at 0:54

Use higher WorkingPrecision:
f[u_] = Sum[u^n/(n n! Zeta[1 + n]), {n, 1, 200}];

• The option PlotPoints -> 100 instead of WorkingPrecision -> 100 works too. BTW, the plot is different from yours. Jul 19 at 17:59