I'm currently using Reduce
to find zeros of a function in a region on a complex plane:
Reduce[q[s]==0 && 0 < Re[s] < 1 && 0 < Im[s] < 50]
q[s]
is a large Dirichlet polynomial:
q[s_] := Sum[a[n]/n^s, {n, 1, 70}]
(the sum in my case is explicit with explicit coefficients, but it does not matter here, I believe)
This function is entire, and so I expected Mathematica to find its zeros rather quickly - as far as I know, there exist special algorithms for finding zeros of a holomorphic function in a region. However, Reduce
is very slow - on my machine it could easily take 2-3 hours or even more to locate zeros of one polynomial.
Does Mathematica have some special built-in algorithm for this? For example, Maple has RootFinding[Analytic]
function which does indeed find zeros of my functions relatively quickly (usually in less than a minute or two), but it fails for unknown reason when the degree of a polynomial is above 60-70 and when the region is larger than approximately 1x50 (and anyway I prefer using Mathematica for my computations). Numeric approximation of roots is perfectly acceptable for me, absolute accuracy is unnecessary - however, if I use NSolve
it works even slower :( Maybe there is a way to tweak the performance of Reduce
somehow? I couldn't find any relevant options in its documentation.
I believe it is possible to run FindRoot
over some grid of points in the region but I don't want to do it because it is easy to miss some zeros this way.
Here is an example of the Dirichlet polynomials I'm working with.
s
? If so, this seems like it might be difficult since it's not polynomial. $\endgroup$s
. I searched the internet and found some papers which suggest methods of numerical approximations of zeros of holomorphic functions - and it seems that one of them is used in Maple. I wonder if Mathematica also has something like it, maybe in form of parameters to generic functions like withNIntegrate
and its methods of integration. $\endgroup$Reduce
although I am not absolutely certain it is used in this example. That of course does not address the speed issue under consideration. One thing I will suggest is that you post an explicit example (no symbolica[n]
, that is). That way readers might have something to test against. $\endgroup$