Repository navigation
Add libeta and libetac, the logarithms of ibeta and ibetac - #1500
Conversation
|
|
|
@NAThompson please add the CUDA tests here as well. If need be I can go back through your flurry of recent PRs and add them where need be. Need to also fix the breakage identified this morning |
d7b951c to
aafcb8a
Compare
Logs of the smaller of ibeta and ibetac, switching to log-space power terms over the continued fraction where it underflows. Closes #1173. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Its first term is 0/0 there; the target can underflow with a = 1 when x or b is tiny. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… type Only targets that underflow it are checked, so the result comes from the new generic power terms. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…an error Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks @NAThompson , things are moving quite fast here lately. This will be very helpful over at SciPy! I know that it is a big ask but would it be possible to test all the already existing ibeta cases with libeta as well (if not already done, cannot evaluate the full diff arm)? The incomplete beta has many branches and special cases that caused some pain in the past. |
|
@dschmitz89 : Good point-I created ulps plots for tons of regimes locally but didn't post them. I also think that the ulps plot code needs to be extended to 2D so that we can tackle more regimes in a single graphic. Lemme create an issue. |
|
Thank you for this! |
Logs of the smaller of ibeta and ibetac, switching to log-space power terms over the continued fraction where it underflows. Closes #1173.
Builds on #1498 (lbeta), so its first commits are that PR's; supersedes #1359.
ulps against Arb's
arb_hypgeom_beta_lower: libeta/libetac in blue, log(ibeta)/log(ibetac) in orange; crosses are clipped or -inf. The scatter near the mean is ibeta's own error, which libeta inherits there (ibeta(1000, 1000, x) is off by up to 391 eps near x = 0.5).🤖 Generated with Claude Code