Conversation
…NG values; fixed simple_bca PRNG so that it gets a new rng with each particle.
…ers switched to thread-level seeds from prngs.
… algorithm for residue-preserving floating point addition
…duced non-determinism for multiple species.
…thread-local rng for starting values.
…a the LIBRUSTBCA_SEED environment variable. Added an option to Options to let the user set the PRNG seed in the standalone code; it defaults to 0.
… variable seeding with default 0 to all library functions.
…values - is fp mult associative? Guess we will find out
…ther ~5-10% speedup...
Minor code fixes
* Updated pyo3 API to latest version. * Fixes and improvements to Python library using newest version of pyo3. * Cargo.toml updates. * Update non-physics packages. * Updates to non-physics packages required some minor code changes * Add inlining type hints
* Experimental triangular lookup tables for screening lengths and Coulomb constant * Added cfg to swap between 'reasonable' Z and full periodic table * Add tests for Z1 > Z2 to test_rustbca.py * Add Python function to compute screened coulomb scattering integrals and test * cleanup of lib.rs * Added scattering integral tests to workflow * Add different option test script to tests * Final version of triangular LUTs.
* Swapped out sin, cos with sin_cos where possible * Fixed bbe call - was calling average instead of actual, ignoring input option * Fixed incorrect bulk binding model in tests. * removed unnecessary invocations of screening_length * Put DEFAULTNEWTON back to 1e-6 * replace costly heap allocations in gauss-mehler with iterator solution * Don't need lazylock for GL points, can just make them consts * Removed further unnecessary heap allocations.
* Draft of generalized RustBCA python wrapper(s) * Added tests of rustbca_py to test_different_options.py * Implemented better python error handling * Add different interaction potentials to scattering_integrals() * used macros to streamline both lib.rs geometry types and main.rs geometry types * Attempt to fix module imports across lib, main
* Update to edition 2024. Fix no_mangle configuration flags to unsafe * Remove unnecessary nan-checking * Upgrade version number to 3.0 * Removed redundant screening length calls; wrapped into scattering integral calls. * Fixed tests. * add .gitignore * Remove HDF5 * Fix workflows.
* Add improved Python error handling * Add pyresult outputs to remaining python functions. * Make new get_seed function from env vars
drobnyjt
commented
Aug 10, 2026
| -0.2912948318493851, | ||
| -2.096765499656263, | ||
| 19.16045452701010, | ||
| 19.160_454_527_010_1, |
Collaborator
Author
There was a problem hiding this comment.
I assume these literals are from clippy fix
Collaborator
Author
There was a problem hiding this comment.
Yep: https://help.klocwork.com/2026.1/en-us/reference/rs.clippy.lossy_float_literal.htm
Presumably the new written value in the highlighted case above (there are several others throughout the code) represents the actual float that the previous value would have represented.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR will bump RustBCA to v3.0.0. The increment in major version is due to different behavior caused by implementing a seeded RNG; however, all input files should be backwards-compatible and produce results within expected Monte Carlo error, with the exception of correctness fixes noted in the list below.
Correctness
Optimizations
New features
S_BV = ((S_LS)^(-ci) + (S_BB)^(-ci))^(-1/ci).Other changes