Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dsmc and fusion binary collisions #4572

Merged
merged 2 commits into from
Jan 4, 2024

Conversation

dpgrote
Copy link
Member

@dpgrote dpgrote commented Jan 3, 2024

This PR makes two updates:

For the DSMC test cast Python_dsmc_1d, this now sets the numpy random number seed, to ensure consistent results.

For DSMC and fusion, when calculating the probability, the code now uses std::expm1, which ensures accurate results even for small exponents. This is a simplification of the code.

@dpgrote dpgrote added the component: collisions Anything related to particle collisions label Jan 3, 2024
@RemiLehe RemiLehe enabled auto-merge (squash) January 3, 2024 21:19
Copy link
Member

@roelof-groenewald roelof-groenewald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing! I'm surprised the checksum values do not need to be updated. Or did you somehow set the random seed to be the same as what it was before?

@RemiLehe RemiLehe merged commit 54486e7 into ECP-WarpX:development Jan 4, 2024
41 checks passed
@dpgrote dpgrote deleted the update_dsmc_fusion branch January 4, 2024 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: collisions Anything related to particle collisions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants