BUG: besselpoly: fix the Neumann series for large `nu` #594
All Vouch review confidence checks passed
Residual risk 0.23 = Change Risk (0.40) × (1 − Review Confidence (0.43)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.40 · 160 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Shallow Review Depth
shallow_review_depth
0.344
Diff Size
diff_size
0.304
Ai Authored
ai_authored
0.050
Real PR Conversation Timeline
1 comments
"Review active on #594"
general
weight: 0.35
jorenham
Reference issue
No issue; follow-up to #485:
On
main:What does this implement/fix?
The Neumann series is normalized with $J_{\nu+1}(2a)$ and $J_{\nu+2}(2a)$. For noninteger orders $v$ with $4a < v < 500$ and $2a \ge 3.6\sqrt{v}$,
cephes::jvgets these by recurring down from the power series at order $v + 2a + 1$, which loses digits throughexp(lgam(...))and returns 0 once that $J$ underflows. There, this takes them from AMOS instead, likescipy.special.jv, and keepscephes::jvwhere AMOS flushes them to 0 or reports an error.Additional information
The new test fails on
mainwith GCC and Clang (relative errors 7e-9 and 1.0) and passes with the fix; the xsrefbesselpolytable test passes. In a random sweep of the Neumann domain, the 99th-percentile relative error drops from 1 to 6e-13.AI Generation Disclosure
Claude Opus 5.5 (Claude Code) wrote the fix, the test, and this description, following the plan in this comment. GPT-6.2 Sol (Codex CLI) reviewed it.