nag_elliptic_integral_rf (s21bbc) calculates an approximation to the integral
where
,
,
and at most one is zero.
The basic algorithm, which is due to
Carlson (1979) and
Carlson (1988), is to reduce the arguments recursively towards their mean by the rule:
- , ,
- remaining third intermediate value argument.
(This ordering, which is possible because of the symmetry of the function, is done for technical reasons related to the avoidance of overflow and underflow.)
and the function may be approximated adequately by a fifth order power series:
where
,
.
Within the domain of definition, the function value is itself representable for all representable values of its arguments. However, for values of the arguments near the extremes the above algorithm must be modified so as to avoid causing underflows or overflows in intermediate steps. In extreme regions arguments are prescaled away from the extremes and compensating scaling of the result is done before returning to the calling program.
You should consult the
s Chapter Introduction which shows the relationship of this function to the classical definitions of the elliptic integrals.
If two arguments are equal, the function reduces to the elementary integral
, computed by
nag_elliptic_integral_rc (s21bac).
This example simply generates a small set of nonextreme arguments which are used with the function to produce the table of low accuracy results.
None.