Skip to content

Integrate a symbolic power of a trigonometric function where it is the derivative of a product - #1912

Merged
Rafael-SOWNet merged 3 commits into
masterfrom
a-symbolic-power-of-a-trigonometric-function-as-the-derivative-of-a-product
Oct 16, 2026
Merged

Rafael-SOWNet merged 3 commits into
masterfrom
a-symbolic-power-of-a-trigonometric-function-as-the-derivative-of-a-product

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

Part of #718.

f^m (alpha + beta f^2), for a symbolic m and f a sine, cosine, secant or cosecant of a linear u, is the derivative of a product where its bracket is a multiple of that derivative's. With u' = 1:

f product its derivative
sin cos sin^(m + 1) sin^m ((m + 1) - (m + 2) sin^2)
cos sin cos^(m + 1) cos^m ((m + 2) cos^2 - (m + 1))
sec tan sec^m sec^m ((m + 1) sec^2 - m)
csc cot csc^m -csc^m ((m + 1) csc^2 - m)

SolveASymbolicPowerOfATrigonometricFunctionAsTheDerivativeOfAProduct reads the integrand as f^m times a polynomial in f with only a constant and a square term. It matches alpha + beta f^2 against p0 + p2 f^2 where beta p0 = alpha p2, and answers (alpha/p0) G/u'. The match is exact, with nothing sampled. SolveAsTheDerivativeOfAProductOfPowers raises the powers an integrand has, and the sine above the bar that tan sec^m brings is not one of them.

The power is taken off by writing 1 for it rather than dividing by it, because s^m (...)/s^m is not cancelled by the simplification.

Checks

  • Exact checks at 50 and 300 digits on seven shapes, with m and n of both signs: 126/126.
  • ASymbolicPowerOfATrigonometricFunctionAsADerivativeIntegralTest: 6 cases, among them one whose bracket is not the derivative and is not claimed.

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

master this branch
pocket: every row of the 4.x.4.x files (1,821 statable) 1,798 1,804
families 0–8 samples 4.1.4.1:8, 4.5.4.1:23, 38 +3 (the same rows)
rows moved +6: 4.1.4.1:8; 4.2.4.1:50, 51; 4.5.4.1:23, 24, 38

All six solve on this branch re-run alone and none on master. No losses. Three 4.x.4.2 rows read as slow. Re-timed alone twice per arm, they are 790–854 vs 821–881 ms, 220–245 vs 217–233 ms and 268–270 vs 266–285 ms. Gate passed; suite 15,470 passed, 0 failed.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

Rafael-SOWNet and others added 3 commits October 16, 2026 14:42
…e derivative of a product

f^m (alpha + beta f^2) for f a sine, cosine, secant or cosecant of a linear is the derivative of
cos sin^(m + 1), sin cos^(m + 1), tan sec^m or cot csc^m where beta p0 = alpha p2, p0 + p2 f^2 being
that derivative's bracket. Rubi's 4.1.4.1 and 4.5.4.1 sec(c + d x)^m (m - (1 + m) sec(c + d x)^2),
sin(e + f x)^m (1 + m - (2 + m) sin(e + f x)^2) and the like were declined.

Part of #718

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
…-a-trigonometric-function-as-the-derivative-of-a-product

# Conflicts:
#	Sources/AngouriMath/Functions/Continuous/Integration/IndefiniteIntegralSolver.cs
#	Sources/AngouriMath/Functions/Continuous/Integration/Integration.Definition.cs
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 1e79b0e 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