Skip to content

A fixed duration is its atom's time; integrated costs compared to rounding - #359

Merged
derrynknife merged 1 commit into
devfrom
fix/fixed-duration-atom
Oct 16, 2026
Merged

derrynknife merged 1 commit into
devfrom
fix/fixed-duration-atom

Conversation

@derrynknife

Copy link
Copy Markdown
Owner

Summary

The last failure of test (minimum dependencies) on the release pull request (#353), after #358: test_maintenance_that_takes_time_is_a_planned_outage compared a run's costs, which are the exact means integrated by quadrature, with whole numbers exactly; at the floors (numpy 2.0.0) the integrals come out at 19.999999999999996 and 20.000000000000057 for 20, where newer numpy sums them exactly. The comparison is to rounding (pytest.approx).

Also, with the tolerance #358 set, a time known exactly is told fixed on every numpy but was given its mean, which numpy 2.0 sums to 1.9999999999999996 for a duration of 2: it is now the time of its one atom (_atoms), exact.

At the floors: test_preventive_maintenance.py, test_expected_window.py, test_start_from_state.py, test_point_availability.py, test_hidden_failures_timed.py and test_total_cost.py pass (249 passed), and the full suite at the floors is being run locally before this merges. Currently the same files pass; black, flake8 and mypy clean.


Generated by Claude Code

…nding

With the fixed-duration tolerance rounding cannot cross (#358), a time
known exactly is told fixed on every numpy, but was given its mean,
which numpy 2.0 sums to 1.9999999999999996 for 2: it is now the time of
its one atom. The planned-outage test that compares a run's costs, the
exact means integrated by quadrature, with whole numbers compares them
to rounding: at the floors the integrals come out at 19.999999999999996
and 20.000000000000057 for 20.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016Ng6hwUY8zznhm1jRfZJqZ
@derrynknife
derrynknife merged commit c7528bb into dev Oct 16, 2026
@derrynknife
derrynknife deleted the fix/fixed-duration-atom branch October 16, 2026 21:51
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.

2 participants