Skip to content

Decline a substitution through a step its own node declines - #2356

Merged
Rafael-SOWNet merged 1 commit into
masterfrom
a-substitution-declines-a-step-its-node-declines
Nov 3, 2026
Merged

Rafael-SOWNet merged 1 commit into
masterfrom
a-substitution-declines-a-step-its-node-declines

Conversation

@Rafael-SOWNet

Copy link
Copy Markdown
Member

A follow-up to #2355. limitcheck found it at DEPTH=3, SEED=19. No issue was filed.

2.6.0 and master now
limitright(x / floor(arcsin(x)), x, 1) 1, where the values tend to (1 + i)/2 unevaluated
limitleft(x / floor(arcsin(x)), x, -1) 1/2, where they tend to (2 - i)/5 unevaluated
limit(floor(1/x!), x, +oo) 93 ms in 2.6.0, 3.9 s since #2355 0.18 s
  • The substitution. Since Ask the side a complex argument of a step arrives from #2355, a floor or ceil whose argument is real at the destination and complex just off it declines its own limit. SolveBySubstitution reads an expression's value at the destination, and it answered the expression the step sits in anyway: x / floor(arcsin(1 + 1/t)) at t = +oo is 1 / floor(pi/2), which is 1. All the way in, floor(arcsin(x)) is 1 - i in the library's own evaluation. The substitution already declines a step that sits on a real jump, mirroring the node's own decline, and now it declines this one too.
  • The cost Ask the side a complex argument of a step arrives from #2355 added. On the way to an infinity, Ask the side a complex argument of a step arrives from #2355 asked whether the argument was real at the integer 10^6, which for 1/x! built 10^6!. Both checks now take the argument at the decimal 1e6 with the downcasting off, as limitcheck samples.

limitcheck at SEED=16, and at DEPTH=3 on SEED=18 and 19, changes only the two wrong limits, now unevaluated. The other declined limits are master's exactly. 883 limit tests pass.

Tests: ASubstitutionDeclinesAStepItsNodeDeclinesTest, 7 cases. The two declines and the 2 s cap on floor(1/x!) fail on master; the 4 real steps pass on both. The full suite, AOT and the nine harnesses pass. #2355's BREAKING-CHANGES entry gains the two rows, measured on 2.6.0.

🤖 Generated with Claude Code

Since #2355 a floor or a ceil whose argument is real at the destination
and complex just off it declines its own limit, and SolveBySubstitution,
which reads an expression's value at the destination, answered the
expression it is in anyway: x / floor(arcsin(x)) at 1 from the right was
1, the value at 1, where the floor all the way in is 1 - i and the
quotient (1 + i)/2; at -1 from the left it was 1/2 for (2 - i)/5. 2.6.0
answers the same. The substitution declines such a step as it already
declines one that sits on a jump.

And #2355 asked whether an argument was real at the integer 10^6 on the
way to an infinity, which for 1/x! built 10^6!: the limit of floor(1/x!)
at +oo went from 93 ms to 3.9 s. Both checks now take the argument at the
decimal 1e6 with the downcasting off, as limitcheck samples, and it is
back to about 0.2 s.

limitcheck at SEED=16 and at DEPTH=3 on SEED=18 and 19 changes only the
two wrong limits, now unevaluated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Rafael-SOWNet Rafael-SOWNet added this to the 2.7.0 milestone Nov 3, 2026
@Rafael-SOWNet Rafael-SOWNet moved this from Todo to In review in AngouriMath Nov 3, 2026
@codecov

codecov Bot commented Nov 3, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 80.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.77%. Comparing base (5df9686) to head (e86f4bb).

Files with missing lines Patch % Lines
...nctions/Continuous/Limits/Solvers/Limit.Classes.cs 66.66% 0 Missing and 1 partial ⚠️
...nctions/Continuous/Limits/Solvers/Limit.Solvers.cs 80.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2356   +/-   ##
=======================================
  Coverage   86.77%   86.77%           
=======================================
  Files         312      312           
  Lines       68777    68783    +6     
  Branches    20034    20037    +3     
=======================================
+ Hits        59680    59686    +6     
  Misses       4910     4910           
  Partials     4187     4187           
Flag Coverage Δ
cpp 37.77% <ø> (ø)
csharp 87.31% <80.00%> (+<0.01%) ⬆️
fsharp 32.97% <ø> (ø)
interactive 40.72% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...ath/Functions/Continuous/Limits/Transformations.cs 87.75% <100.00%> (+0.04%) ⬆️
...nctions/Continuous/Limits/Solvers/Limit.Classes.cs 72.80% <66.66%> (-0.11%) ⬇️
...nctions/Continuous/Limits/Solvers/Limit.Solvers.cs 86.36% <80.00%> (-0.22%) ⬇️

... and 5 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Rafael-SOWNet
Rafael-SOWNet merged commit 195da7f into master Nov 3, 2026
53 of 62 checks passed
@github-project-automation github-project-automation Bot moved this from In review to Done in AngouriMath Nov 3, 2026
@Rafael-SOWNet
Rafael-SOWNet deleted the a-substitution-declines-a-step-its-node-declines branch November 3, 2026 22:23
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