complex residue involving exponent of quotient of polynomials I was trying to work out an integral and came to trying to find the complex residue of 
$$R = \exp\left(\frac{Ax^2 + Bix}{Dx + 1}\right)$$
at $x = -D^{-1}$.  I used partial fractions to get:
$$ = \exp\left(
\frac{- B Di + A}{D^2 (D x + 1)} + \frac{B Di + A D x - A}{D^2}
\right)$$
If I try to use limits to find the coefficient:
$$\lim_{x \rightarrow -D^{-1}}\quad (Dx + 1)\exp\left(\frac{Ax^2 + Bx + C}{Dx + 1}\right)$$
$$ = \lim_{x \rightarrow -D^{-1}}\quad (Dx + 1)\exp\left(
\frac{- B Di + A}{D^2 (D x + 1)} + \frac{B Di + A D x - A}{D^2}
\right)$$
$$ = \exp\left(\frac{BDi - 2A}{D^2}\right)\lim_{x \rightarrow -D^{-1}}\quad (Dx + 1)\exp\left(
\frac{- B Di + A}{D^2 (D x + 1)}
\right)$$
which leaves finding:
$$\lim_{x \rightarrow -D^{-1}}\quad (Dx + 1)\exp\left(
\frac{K}{(D x + 1)}
\right)$$
I'm not even sure this limit is defined.  Is there a better way to find this residue?
 A: The singularity at $-D^{-1}$ is an essential singularity, so you cannot determine the residue using a method to find residues in poles.
Here, writing $w = x+D^{-1}$, polynomial division gives you an expression of the form
$$\exp\left(\frac{a}{w} + b + cw\right)$$
whose residue in $0$ you want to determine. The constant can be pulled out, so the relevant part is $\exp\left(\frac{a}{w}+cw\right)$. You can find it by expanding it into a series in powers of $\frac{a}{w}+cw$, and from each term collecting the contribution to $w^{-1}$. In my opinion better is to expand $e^{a/w}$ and $e^{cw}$ separately, and obtain the overall coefficient via the product of the two Laurent series. We find
$$\left(\sum_{n=0}^\infty \frac{a^n}{n!w^n}\right)\left(\sum_{m=0}^\infty \frac{c^mw^m}{m!}\right) = \sum_{k=-\infty}^\infty \left(\sum_{m=\max\{0,k\}}^\infty\frac{c^ma^{m-k}}{m!(m-k)!}\right)w^k,$$
for the residue, $k = -1$,
$$\operatorname{Res}\left(e^{a/w+cw}; 0\right) = \sum_{m=0}^\infty \frac{c^ma^{m+1}}{m!(m+1)!},$$
which is closely related to the modified Bessel function of the first kind, the value is
$$\sqrt{\frac{a}{c}} I_1(2\sqrt{ac}).$$
Remember that we ignored the constant $b$ so far, then we obtain
$$\operatorname{Res}\left(\exp\left(\frac{a}{w} + b + cw\right);0\right) = e^b\sqrt{\frac{a}{c}} I_1(2\sqrt{ac}).$$
Long division yields
$$a = \frac{A}{D},\quad b = \frac{BDi-2A}{D^2},\quad c = \frac{A-BDi}{D^3}$$
here (if I haven't miscalculated).
