Skip to content

A polynomial may stand beside a root of a ± a cos(y) - #1474

Merged
Rafael-SOWNet merged 1 commit into
masterfrom
polynomial-beside-the-root
Sep 23, 2026
Merged

Rafael-SOWNet merged 1 commit into
masterfrom
polynomial-beside-the-root

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

x^3 sqrt(a + a cos(c + d x)) was left as written, while sqrt(a + a cos(x)) came out in four milliseconds.

SolveByTheHalfAngleWhereOnePlusASineIsASquare rewrites a ± a cos(y) as a square of the half angle and then substitutes the angle — so anything else that mentioned the variable made inU.ContainsNode(x) true and the rule declined, a polynomial among them.

What is left of the variable is the variable itself. With u half the angle (a quarter turn further for the sine's identity, u = y/2 + pi/4), x is (2u - offset)/rate, so a polynomial in x is a polynomial in u — and what is handed on is one times a cosine of u, which the closed rule for a polynomial times a trigonometric answers.

Measured (final build):

  • Family 4 (familycap.sh 4 6): 287 → 290/422, 0 wrong, timeouts 32 → 30 — 4.2.10:188/202 and 4.3.4.2:114; nothing lost.
  • Family 6: 377/417, 0 wrong, unchanged. 1774-problem suite: 1707, 0 wrong, 0 timeout, unchanged.
  • Unit suite: 12,649 tests, 0 failed. bench.sh: PASSED on all 19 gated benchmarks.
  • Every new row differentiates back with a positive and a negative — the sign the rule writes (sgn(cos(y/2)) or sgn(sin(y/2))) is what changes between them — and each was checked at five points, worst relative deviation 0.

Part of #718.

🤖 Generated with Claude Code

https://claude.ai/code/session_012sonx8iAspMiwRwokT1Ura

`x^3 sqrt(a + a cos(c + d x))` was left as written. The half angle at
which `a ± a cos(y)` is a square answers the root alone, and it
substitutes the angle -- so anything else that mentioned the variable
stopped it, a polynomial among them, and the rule declined rather than
handing on a question it had already made simpler.

What is left of the variable is the variable itself. With `u` half the
angle -- a quarter turn further for the sine's identity -- `x` is
`(2u - offset)/rate`, so a polynomial in `x` is a polynomial in `u`, and
what is handed on is one times a cosine of `u`: the shape the closed
rules answer.

Family 4 of the Rubi suite: 287 -> 290 of 422, 0 wrong; family 6 377/417
and the 1774-problem suite 1707 unchanged. Suite 12649 passed; allocation
gate passed on all 19 gated benchmarks. Each row differentiates back with
`a` positive and negative, where the sign the rule writes is what changes.

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 0c2ad34 into master Sep 23, 2026
31 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