Skip to content

Half-odd powers of two conjugate tangent sums are integrated as the exponential they make - #1798

Merged
Rafael-SOWNet merged 3 commits into
masterfrom
a-conjugate-pair-of-imaginary-tangent-sums-is-integrated-as-an-exponential
Oct 5, 2026
Merged

Rafael-SOWNet merged 3 commits into
masterfrom
a-conjugate-pair-of-imaginary-tangent-sums-is-integrated-as-an-exponential

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

Part of #718.

(a + i a tan(pe + f x))^(7/2) (A + B tan(pe + f x))/(c - i c tan(pe + f x))^(9/2) ran past the budget, with 43 more rows of Rubi's 4.3.3.1 that put both conjugate sums beside A + B tan:

integrand 2.5.0 master a5ce1c55 this
(a + i a tan(x))^(7/2) (A + B tan(x))/(c - i c tan(x))^(9/2) declined 2,075 characters 271 characters
(a + i a tan(x))^(3/2) (A + B tan(x))/(c - i c tan(x))^(3/2) declined 531 characters 243 characters
(A + B tan(x))/((a + i a tan(x))^(3/2) (c - i c tan(x))^(3/2)) declined 645 characters 388 characters

With x alone master answers these since #1795. With the corpus's pe + f x, master a5ce1c55 runs past the 5-second budget on all 44 problems this answers, each asked alone, and this branch answers every one of them in under a second.

What changes. a + i a tan(z) is a sec(z) e^(i z) on the real line and c - i c tan(z) is c sec(z) e^(-i z), so two powers of them adding up to a whole number k are a constant on every interval where they are continuous times sec(z)^k e^(i (p - q) z), and in w = e^(i z), beside any function of the tangent, the secant, the cosine or the sine of z, the integrand is a rational function of w times a power of it. SolveAConjugatePairOfImaginaryTangentSums, asked after the rule for one sum beside the secant, integrates there, and returns the integrand times the antiderivative in w over what that antiderivative differentiates back to, as the rule for one sum does; #1791's rule integrates in one of the sums beside a whole power of the other, and with both half-odd neither is. The antiderivative in w is checked in w, where it is the only thing computed: checked at sampled x, the quotient's constant need not be the same on both sides of the points, and right answers were declined that way.

Tests: ConjugatePairOfImaginaryTangentSumsIntegralTest, five rows, with and without A + B tan, compared as complex numbers at real points.

Measured on the 338 corpus problems with both conjugate sums in the integrand, at the corpus's 5-second budget, against master 2aae852a, the base the branch was measured on (bc6de839):

master this
solved 287 331
unverifiable on the reals 1 1
past the budget 50 6

The 44 problems the two builds disagreed on, all from 4.3.3.1, run again one build at a time: master answers none inside the budget, and this branch answers all 44, in 0.7 seconds on average with the check and 2.1 at most. The 161 rows of 4.3.2.1 in the pocket are answered alike by both, 158 of them.

The suite on the commit measured, bc6de839, passes, 15,056 tests, and so does the allocation gate: every gated benchmark allocates what the baseline says. The head here, 649b3b8f, merges master e604369d; the calculus and corpus tests pass on it, 4,355 tests, and the library builds for netstandard2.0.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

Rafael-SOWNet and others added 3 commits October 5, 2026 14:17
…xponential they make

(a + i a tan(z))^(7/2) (A + B tan(z))/(c - i c tan(z))^(9/2) ran past the budget,
with the rest of Rubi's 4.3.2.1 and 4.3.3.1 that put half-odd powers on both sums:
the rule for one sum integrates in it beside a whole power of the other, and with
both half-odd neither is. a + i a tan(z) is a sec(z) e^(i z) on the real line and
c - i c tan(z) is c sec(z) e^(-i z), so two powers of them adding up to a whole
number k are a constant on every interval where they are continuous times
sec(z)^k e^(i (p - q) z), rational in w = e^(i z) beside any function of the
tangent, secant, cosine or sine of z.

SolveAConjugatePairOfImaginaryTangentSums integrates in w, after the rule for one
sum beside the secant, and returns the integrand times the antiderivative in w
over what that differentiates back to. The antiderivative in w is checked there,
where it is the only thing computed. 23 of the 24 such rows of 4.3 answered,
where master answers 2 within 20 seconds.

Part of #718.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
…-imaginary-tangent-sums-is-integrated-as-an-exponential
…-imaginary-tangent-sums-is-integrated-as-an-exponential
@Rafael-SOWNet Rafael-SOWNet added this to the 2.6.0 milestone Oct 5, 2026
@Rafael-SOWNet
Rafael-SOWNet merged commit 15aae3d into master Oct 5, 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