Details
-
New Feature
-
Status: Closed
-
Major
-
Resolution: Won't Do
-
1.0
-
None
-
None
Description
The RegularizedBeta class computes the regularized beta function I(x, a, b). There is a functional identity for this:
1 - I(x, a, b) = I(1 - x, b, a)
See Wolfram Regularized Incomplete Beta Identities
The RegularizedBeta class currently exploits this identity to compute the value by switching to call '1.0 - value(1 - x, b, a)' depending on the parameters.
I suggest a complement for this function to compute 1 - I(x, a, b):
public class RegularizedBetac { public static double value(double x, final double a, final double b, double epsilon, int maxIterations); }
This can call RegularizedBeta.value using the same inversion logic and avoid a potential computation of the complement using multiple inversions with loss of precision:
1 - I(x, a, b) == 1 - [ 1 - I(1 - x, b, a) ] = I(1 - x, b, a) or I(1 - x, b, a) == 1 - I(x, a, b) = 1 - [ 1 - I(1 - x, b, a) ]
Attachments
Issue Links
- relates to
-
NUMBERS-181 Update the RegularizedBeta function using the Boost implementation
- Closed