Skip to content

The other four trigonometric functions are written as sine and cosine before the complement of a substitution is, and never where that leaves an odd power of the complement under a root - #1312

Merged
Rafael-SOWNet merged 1 commit into
masterfrom
secant-under-the-complement
Sep 13, 2026
Merged

Rafael-SOWNet merged 1 commit into
masterfrom
secant-under-the-complement

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

Charlwood's arctan(sqrt(sec(x) - 1)) sin(x) had no antiderivative. By parts it leaves
sin(x)/sqrt(sec(x) - 1), and under u = cos(x) -- the complement of the written
sine, a candidate since #1307 -- that is -1/sqrt(1/u - 1), a root of a quotient of
two linears, which is the linear-radical substitution's since #1308. With the
secant left standing it kept its x and the candidate was refused. The pass
that writes the complement's even powers in u writes the secant, cosecant,
tangent and cotangent of the argument as quotients of the sine and cosine
first now, and substitutes u again where that has written the function anew.

And refuses the rewriting where it leaves an odd power of the complement under
a root. The first draft did not, and Timofeev's
(sec(x)^2 - 3 sqrt(4 sec(x)^2 + 5 tan(x)^2) tan(x))/(sin(x)^2 (...)^(3/2)) under
u = sin(x) became a root of a quotient by cos(x)^2, which the simplification the
substitution runs takes as .../cos(x) -- its value where the cosine is positive
and its negative elsewhere -- and the integrand was answered wrongly on half the
line, measured at two of six sampled points and pinned as declined-or-right on
both sides. An even power of the complement under a root is 1 - u^2 by then and
is no such hazard.

One answer changes shape: sin(x) sin(2x) over cos(x) is 2 sin(x)^2 once the
simplification has written the double angle out, and the second pass reads the
sine that wrote as u again, so it is 2 sin(x)^3/3 now rather than
product-to-sum's cosines of x + 2x; the test that pinned the old shape pins
the new one.

Measured

Every answer differentiated back on both sides of zero.

Rubi corpus, 463-problem sample, on the same evening:

master at #1309     401/463, 0 wrong, 0 timeouts, 100 s
with this           402/463, 0 wrong, 0 timeouts, 99 s

One more, nothing lost: Charlwood 32.

The five test suites are green.

Part of #718.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

… before the complement of a substitution is, and never where that leaves an odd power of the complement under a root

Charlwood's `arctan(sqrt(sec(x) - 1)) sin(x)` had no antiderivative. By parts it leaves
`sin(x)/sqrt(sec(x) - 1)`, and under `u = cos(x)` -- the complement of the written
sine, a candidate since #1307 -- that is `-1/sqrt(1/u - 1)`, a root of a quotient of
two linears, which is the linear-radical substitution's since #1308. With the
secant left standing it kept its `x` and the candidate was refused. The pass
that writes the complement's even powers in `u` writes the secant, cosecant,
tangent and cotangent of the argument as quotients of the sine and cosine
first now, and substitutes `u` again where that has written the function anew.

And refuses the rewriting where it leaves an odd power of the complement under
a root. The first draft did not, and Timofeev's
`(sec(x)^2 - 3 sqrt(4 sec(x)^2 + 5 tan(x)^2) tan(x))/(sin(x)^2 (...)^(3/2))` under
`u = sin(x)` became a root of a quotient by `cos(x)^2`, which the simplification the
substitution runs takes as `.../cos(x)` -- its value where the cosine is positive
and its negative elsewhere -- and the integrand was answered wrongly on half the
line, measured at two of six sampled points and pinned as declined-or-right on
both sides. An even power of the complement under a root is `1 - u^2` by then and
is no such hazard.

One answer changes shape: `sin(x) sin(2x)` over `cos(x)` is `2 sin(x)^2` once the
simplification has written the double angle out, and the second pass reads the
sine that wrote as `u` again, so it is `2 sin(x)^3/3` now rather than
product-to-sum's cosines of `x + 2x`; the test that pinned the old shape pins
the new one.

## Measured

Every answer differentiated back on both sides of zero.

Rubi corpus, 463-problem sample, on the same evening:

    master at #1309     401/463, 0 wrong, 0 timeouts, 100 s
    with this           402/463, 0 wrong, 0 timeouts, 99 s

One more, nothing lost: Charlwood 32.

The five test suites are green.

Part of #718.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
@Rafael-SOWNet
Rafael-SOWNet merged commit 82cef00 into master Sep 13, 2026
31 checks passed
@Rafael-SOWNet
Rafael-SOWNet deleted the secant-under-the-complement branch September 13, 2026 19:00
Rafael-SOWNet added a commit that referenced this pull request Oct 9, 2026
… 2.5.0

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura
Rafael-SOWNet added a commit that referenced this pull request Oct 9, 2026
* Breaking-changes entries for #1828 to #1832 and #1374

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

* And for #1368, #1611 and #1517, each measured on 2.5.0

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

* And for #1289, #1312, #1315, #1377, #1380 and #1371, each measured on 2.5.0

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>
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