freealg.distributions.DeformedWigner.roots#

DeformedWigner.roots(z)#

Roots of polynomial implicitly representing Stieltjes transform

Parameters:
zcomplex or numpy.ndarray

A complex scalar or a 1D or 2D array of query points.

Returns:
rnumpy.ndarray

Roots of polynomial with the following array shape:

  • If z is scalar, returned array is of the shape (r+1,).

  • If z is array-like, returned array if of shape z.shape + (r+1,).

See also

stieltjes
poly

Examples

>>> import numpy
>>> from freealg.distributions import DeformedWigner

>>> dwg = DeformedWigner(t=[2.0, 5.5], w=[0.75, 1-0.75],
...     sigma=1.0)

>>> z = numpy.linspace(0, 2, 10) + 2.0j
>>> r = dwg.roots(z)