Skip to content

Leave a half-angle question whose logarithms want a sum over roots to the second pass - #1998

Merged
Rafael-SOWNet merged 1 commit into
masterfrom
leave-a-half-angle-question-wanting-a-sum-over-roots-to-the-second-pass
Oct 21, 2026
Merged

Rafael-SOWNet merged 1 commit into
masterfrom
leave-a-half-angle-question-wanting-a-sum-over-roots-to-the-second-pass

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

1/(1 + sin(x)^5) is asked one level down as (1 + sin^5)^(-1). The half-angle substitution then asks for 2 (t^2 + 1)^4/((t^2 + 1)^5 + 32 t^5), whose denominator is (t + 1)^2 times an irreducible octic. Its logarithms want residues of degree eight, which only the second pass writes, as a sum over roots. The first pass declined only after partial fractions had tried every split and spelling for 28 seconds; the second pass then answered in half a second.

In the first pass, the half-angle substitution now declines at once and sets ASumOverRootsWouldAnswer, when the question in t meets three conditions:

  • its coefficients are rational;
  • Hermite's reduction, the resultant and its factors show a residue field of degree past two;
  • no product of the denominator's irreducible factors is a polynomial in (t + s)^k with k >= 2. That form covers the binomials, biquadratics and blocks that the closed-form rules read; x^5 + 1 is caught as a whole.

The test is RothsteinTrager.WantsASumOverRootsAlone. Its residue fields come from a helper, ResidueFields, that LogarithmicPart now shares. #1996's mod-p screen, which spares the factorization where a field past the second degree is a decline anyway, moved into that helper behind a parameter and is applied exactly where it was.

Measured on 20a4b391, branch against master:

Run Problems Master Branch
Pocket: Rubi's 4.1, 4.2, 6.1.7, 6.2.7 and 6.7.1, sampled 1,886 1,826 solved 1,827 solved
Family 1, 40 a file 1,381 1,370 1,370
Family 0, whole 1,814 1,796 1,796
Families 2 to 8, sampled 2,410 2,391 2,390

Re-run alone, 4.1.7:326 goes from timed out to answered. Measured as one process each, it drops from 29.4 s and 56 GB to 2.3 s and 0.75 GB, with the same answer character for character. 4.1.7:329 and sin(x)/(1 + sin(x)^5) go from 12 s and 31 GB to under a second, also with identical answers.

The one-row sample difference is 6.6.1:25, which master answers in 23 s; both builds answer it alone. None of the following changed its answer, character for character: 394 solved rows of 4.1.7, 86 of 4.2.7, 244 of 6.7.1 and 302 reciprocals of radicals. 1/(1 + cos(x)^3), over a binomial the first pass writes at its roots, keeps its closed form. On the combined build, #1996's Hearn 365 and Bronstein 22 still answer. No run had a wrong answer.

ASumOverRootsLeftToTheSecondPassIntegralTest checks that these come back with a sum over roots, or in closed form for the even block, differentiated back. 190 related tests pass. No answer changes, so BREAKING-CHANGES.md has no entry.

Part of #233.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

… the second pass

1/(1 + sin(x)^5) is asked one level down as (1 + sin^5)^(-1), and the
half-angle substitution asks 2 (t^2 + 1)^4/((t^2 + 1)^5 + 32 t^5), whose
denominator is (t + 1)^2 times an irreducible octic: its logarithms want
residues of degree eight, which only the second pass writes, as a sum over
roots. The first pass declined it after partial fractions had tried every
split and spelling for 28 seconds, and the second answered in half a second.
In the first pass the half-angle substitution now declines at once, setting
ASumOverRootsWouldAnswer, where the question in t has rational coefficients,
Hermite's reduction, the resultant and its factors show a residue field of
degree past two, and no product of the denominator's factors is a
polynomial in (t + s)^k with k >= 2 -- the binomials, biquadratics and
blocks the closed-form rules read. The residue fields come from a helper
LogarithmicPart now shares.

Rubi's 4.1.7:326 goes from 29.4 s and 56 GB to 2.3 s and 0.75 GB, and 329
and sin(x)/(1 + sin(x)^5) likewise, with the same answers, character for
character; 394 solved rows of 4.1.7, 86 of 4.2.7 and others answer as
before.

Part of #233.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
@Rafael-SOWNet Rafael-SOWNet added this to the 2.6.0 milestone Oct 21, 2026
@Rafael-SOWNet
Rafael-SOWNet merged commit 069ad12 into master Oct 21, 2026
34 checks passed
@github-project-automation github-project-automation Bot moved this from Todo to Done in AngouriMath Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant