Skip to content

Integrate a function of an inverse times its derivative up to a factor constant though written with x - #1909

Merged
Rafael-SOWNet merged 3 commits into
masterfrom
a-function-of-an-inverse-times-its-derivative-up-to-a-constant
Oct 16, 2026
Merged

Rafael-SOWNet merged 3 commits into
masterfrom
a-function-of-an-inverse-times-its-derivative-up-to-a-constant

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

Part of #718.

u = atan(c x/sqrt(a - c^2 x^2)) has the derivative c/sqrt(a - c^2 x^2). Rubi's 5.3.7 puts 1/sqrt(d - c^2 d x^2/a) beside it, which is that derivative times sqrt(a - c^2 x^2)/(c sqrt(d - c^2 d x^2/a)). That factor is constant wherever it is real, though written with x in it. Nothing read it as constant, so atan(...)^m/sqrt(d - c^2 d x^2/a) was declined, and the rules before it spent up to 28 seconds getting there.

SolveAFunctionOfAnInverseTimesItsDerivativeUpToAConstant takes each inverse sine, cosine or tangent of something not linear, substitutes t for it, and divides by its derivative. It splits what is left into the factors that hold t and those that do not. If the second are constant, the integral is their product times the integral over t.

"Constant" is decided by comparing the factor with its value at x = 3/10, at the sampled points with every symbol pinned. I tried two symbolic tests first. Asking Simplify whether the factor's derivative vanished took four seconds a row. The factor's square stayed a power of a quotient of roots, so the cheaper test of its square could not read it. A point the comparison cannot settle counts against constancy, and the answer is then checked where the integrand is real.

It is asked early, after the constant sums are folded, at the question asked only. It fires only where that factor holds x; a factor free of x is the ordinary substitution's.

Checks

  • Exact checks at 50–2000 digits on the twelve corpus shapes, three pin sets each: 432/432.
  • AFunctionOfAnInverseTimesItsDerivativeIntegralTest: 5 cases.

Corpus, measured against master 90c9d3e (this branch then merged adba48c):

master this branch
pocket: every row of family 5 (1,774 statable) 1,690 1,702
families 0–8 samples 5.3.7:186, 190, 194 +3 (the same rows)
rows moved +12: 5.3.7:185–196

All twelve solve on this branch re-run alone and none on master; on this branch the slowest takes 0.12 s. No losses. Two family-1 rows read as slow (1.2.1.6:191, 194). Re-timed alone they are 1,735 vs 1,695 ms and 446 vs 414 ms; the rule does not reach them, since they hold no inverse function. Gate passed; suite 15,469 passed, 0 failed.

One pocket row is wrong on master and on this branch alike: 5.1.4:650, answered NaN. A separate branch fixes it.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

Rafael-SOWNet and others added 3 commits October 16, 2026 13:54
…r constant though written with x

atan(c x/sqrt(a - c^2 x^2)) has the derivative c/sqrt(a - c^2 x^2), and beside it
1/sqrt(d - c^2 d x^2/a) is that times a factor constant wherever it is real. With u the inverse,
the integrand over u' splits into a function of u and that factor, and the integral is the factor
times the integral of the function. The factor is taken as constant where it holds its value
across sampled points; asking Simplify for its derivative took four seconds. Rubi's 5.3.7
atan(c x/sqrt(a - c^2 x^2))^m/sqrt(d - c^2 d x^2/a) and eleven more were declined, master spending
up to 28 seconds on one.

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 16, 2026
@Rafael-SOWNet
Rafael-SOWNet merged commit 87be872 into master Oct 16, 2026
34 checks passed
@github-project-automation github-project-automation Bot moved this from Todo to Done in AngouriMath Oct 16, 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