This is documentation for Mathematica 5, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

Documentation / Mathematica / Add-ons & Links / Standard Packages / NumericalMath /


The Mathematica function Residue symbolically finds the residue of an expression at a point in the complex plane. Because it is symbolic in nature it is sometimes unable to get a result.

NResidue is the numerical version of Residue. It works by numerically integrating around a small circle centered at the point at which the residue is being sought. The obvious problem with this approach is that it in fact finds the sum of the residues at all of the points contained within the circle. By making the radius of the circle sufficiently small you can exclude all singularities but the one in question.

Numerical evaluation of residues.

Options for NResidue.

This loads the package.

In[1]:= <<NumericalMath`NResidue`

Find the residue of at the origin.

In[2]:= NResidue[1/z, {z, 0}]


Define an expression whose residue you will find.

In[3]:= f = 1/Expand[(z-1.7)(z+.2+.5 I)(z+.2-.5 I)]


Find the residue. Strictly speaking, f has no singularity at , but it has one very near to 1.7.

In[4]:= Residue[f, {z, 1.7}]


Numerically find the residue.

In[5]:= NResidue[f, {z, 1.7}]


This is another way to find the residue.

In[6]:= 1/((z+.2+.5 I)(z+.2-.5 I)) /. z -> 1.7