Skip to content

A symbolic exponent that is -1 as a value is integrated to the logarithm - #1723

Merged
Rafael-SOWNet merged 2 commits into
masterfrom
a-symbolic-exponent-of-minus-one-as-a-value-is-the-logarithm
Oct 4, 2026
Merged

Rafael-SOWNet merged 2 commits into
masterfrom
a-symbolic-exponent-of-minus-one-as-a-value-is-the-logarithm

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

Part of #718.

x^(-1 - 3n) (a + b x^n)^3 came back as a sum whose last term was x^0/0, so that the answer had no value anywhere, and x^(-n/n) as NaN + C. Both were so on 2.5.0 too:

integrand master 51cb049a this
x^(-1 - 3n) (a + b x^n)^3 three powers and x^0/0, no value anywhere the three powers and b^3 ln(x)
x^(-1 - 3n + 3n) x^(-1 - 3n + 3n + 1)/(-1 - 3n + 3n + 1), no value anywhere ln(x)
x^(-n/n) NaN ln(x)
1/(a (b x^m)^n)^(1/(m n)) NaN (a b^n)^(-1/(m n)) ln(x), provided b > 0 and a b^n > 0

What changes. Expanded, x^(-1 - 3n) (a + b x^n)^3 leaves x^(-1 - 3n + 3n) for its last term, which is x^(-1) for every n. The power rule reads -1 once the exponent is the number (#1258's fix), but InnerSimplified keeps -3n + 3n as two terms, and the rule read this one as written and divided by its zero. It asks whether the exponent plus one vanishes as a value now -- at pinned values first and then simplified, as the integrator asks elsewhere -- and gives the logarithm where it does. A symbolic exponent that is -1 for one value only, x^n itself, is the power rule's as before.

Tests: ExpandedSquareNaNTest.AnExponentThatIsMinusOneAsAValue, five rows, each differentiated back with the symbols pinned; all five fail on master. x^n and x^(n - 1) join ThePowerRuleIsUnchanged.

Found by work/intbench, which counts an answer that has no value anywhere as wrong, on every fourth problem of Rubi's 1.1.2.2 and 1.1.3.2: five there, the four rows of this shape and the last row above. Its usual sample of forty a file reaches none of them.

Measured first on every sixth of the 6,519 problems in the corpus with a symbolic exponent, 1,087, at the corpus's 5-second budget, against master 8f3757cd, the branch's base:

master this
solved 944 947
wrong 3 0

The three are 1.1.3.2's 1/(a x^n)^(1/n), x^(-1 - 4n) (a + b x^n)^5 and x^(-1 - 8n) (a + b x^n)^8.

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 1297
families 2 to 8, sampled (2410) 2215 2219

No answer is wrong in the sample on either build. Of the eight problems the two builds disagreed on, run again one build at a time, three are the pocket's wrong answers, right here, and the other five are answered on both.

The suite passes on the commit measured, a0c1e98e, 14,598 tests, and so does the allocation gate. Master 51cb049a is merged in since, without conflicts; the calculus tests pass on the merge, 3,990 of them, and the four rows above are right on it.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

Rafael-SOWNet and others added 2 commits October 3, 2026 17:44
x^(-1 - 3n) (a + b x^n)^3 expanded leaves x^(-1 - 3n + 3n) for its last term, which is x^(-1)
for every n, and InnerSimplified keeps -3n + 3n as two terms. The power rule read the exponent
as written and divided by its zero, so the whole answer had no value anywhere; x^(-n/n) came
back NaN. It asks whether the exponent plus one vanishes as a value now, and gives the logarithm
where it does.

Part of #718.

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 3, 2026
@Rafael-SOWNet
Rafael-SOWNet merged commit 098cb2b into master Oct 4, 2026
34 checks passed
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