Skip to content

A rational function with symbols in it beside a root of a linear is split into partial fractions first - #1741

Merged
Rafael-SOWNet merged 2 commits into
masterfrom
a-rational-function-beside-the-root-of-a-linear-is-split-first
Oct 4, 2026
Merged

Rafael-SOWNet merged 2 commits into
masterfrom
a-rational-function-beside-the-root-of-a-linear-is-split-first

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

Part of #718.

1/(x (1 + x^2) sqrt(a + b x)) was declined, while 1/(x sqrt(a + b x)) and x/((1 + x^2) sqrt(a + b x)), its two partial fractions beside the root, were each answered: under v = sqrt(a + b x) it is a rational function over a sextic with symbols in it, which nothing factors. 2.5.0 declined them too:

integrand 2.5.0 master 6bbed69f this
1/(x (1 + x^2) sqrt(a + b x)) declined declined after 1 s arctangents and a logarithm in sqrt(a + b x), in 1.6 s
1/((x + c) (x + d) sqrt(a + b x)) declined declined after 1 s the same, in 0.5 s
cot(x)/sqrt(a + b tan(x)) declined declined after 1 s the same in tan(x), in 1.3 s
cot(x)^2/(a + b tan(x))^(3/2) declined declined after 3 s the same beside a power, in 2.6 s

What changes. A rational function with symbols in it and two or more factors below the bar, beside a power of a linear that is not whole, is split over its factors as written before anything substitutes for the root: the whole part of the power goes among the factors, so that each term stands over a root, and the terms are integrated one at a time. That is what the tangent substitution makes of Rubi's 4.3.2.1, cot(x)/sqrt(a + b tan(x)).

Tests: SplitBesideARootIntegralTest, five rows differentiated back with the symbols pinned, on both sides of zero; all five are declined on master.

Measured first on the 1,058 problems of Rubi's 1.1.1.2 to 1.1.1.7, 1.3.2, 4.3.2.1 and 4.3.3.1 with a root of a linear in x or in tan(x) beside a rational function, at the corpus's 5-second budget, against master 8f3757cd, the branch's base:

master this
solved 876 911
wrong 0 0
past the budget 80 61

Measured then on the Rubi corpus against master 8f3757cd:

master this
family 0, independent suites (1814) 1766 1766
family 1, 40 a file (1381) 1296 1298
families 2 to 8, sampled (2410) 2215 2220

No answer is wrong in the pocket or the sample on either build. Of the 43 problems the two builds disagreed on, pocket and sample together, run again one build at a time, master answers 5 and this 37. Thirty-three are Rubi's (a + b tan)^m (c + d tan)^n, with and without A + B tan beside it, answered here in three seconds on average and declined or past the budget on master; three more, from 1.1.1.3, 1.1.4.3 and 7.3.2, take eight to twenty-one seconds here. The four master answered and this did not took seventeen to nineteen seconds there, at the edge of the harness's patience, and run again on each build in turn both run past it. Alternating the builds with a ninety-second budget, (A + B x + C x^2 + D x^3)/((a + b x)^4 sqrt(c + d x)), the one of them with a root, takes 45 and 29 s on master and 44 and 25 s here, and 1/(x (a x + b x^3 + c x^5)^2) 34 and 25 s against 24 and 24 s.

The suite on the commit measured, d1facdac, passes 14,595 of 14,596 tests with 13 skipped, and the allocation gate passes. The one failure is AnIntegralWithNoAnswerStillFinishesQuickly, which bounds sin(x)/(x^3 + 1)^2 integrated and simplified at thirty seconds: it took 39 s there and 43 s in the run on the merge below, with four corpus chains beside both, and passes run alone; on its own that integral takes about three seconds on master 6bbed69f and on the merge alike, two runs each, alternating. On the merge with master 6bbed69f, eef262cb, the other 4,086 calculus and corpus tests that run pass, with 2 skipped. Every row of the first table is as it says on the merge.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

Rafael-SOWNet and others added 2 commits October 4, 2026 04:24
…plit into partial fractions first

1/(x (1 + x^2) sqrt(a + b x)) was declined while each of its partial fractions
beside the root was answered: under v = sqrt(a + b x) it is a rational function
over a sextic with symbols in it, which nothing factors. With two or more
factors below the bar, the rational function is split over them as written --
the whole part of the power among them, so each term stands over a root -- and
integrated term by term. Rubi's 4.3.2.1, cot(x)/sqrt(a + b tan(x)), under the
tangent. Part of #718.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
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 4, 2026
@Rafael-SOWNet
Rafael-SOWNet merged commit cb8e133 into master Oct 4, 2026
34 checks passed
@Rafael-SOWNet
Rafael-SOWNet deleted the a-rational-function-beside-the-root-of-a-linear-is-split-first branch October 29, 2026 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant