The numerical integration of (4) using a low degree Gauss rule
is very accurate when
, except when
is close to but not
equal to
. In order to avoid the problems when
,
Drezner and Wesolowsky rewrote (4) as
The integrand in this expression is smooth except for the term
that is the source of relatively large errors when
is close to
.
Using the Taylor expansion
 |
(5) |
becomes
The Drezner and Wesolowsky algorithm computes the second integral numerically,
and the integral of the term
analytically, using the formula
with
,
and
.
2004-04-13