Skip to content

[WIP] Recoil generation #288

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

Open
wants to merge 7 commits into
base: dev
Choose a base branch
from
Open

[WIP] Recoil generation #288

wants to merge 7 commits into from

Conversation

drobnyjt
Copy link
Collaborator

@drobnyjt drobnyjt commented Jul 11, 2025

Thank you for your contribution to rustBCA!

Before submitting this PR, please make sure you have:

  • Opened an issue
  • Referenced the relevant issue number(s) below
  • Provided a description of the changes below
  • Ensured all tests pass and added any necessary tests for new code

Fixes #286

Description

User @dmonah observed deviations in sputtering yields when ions were incident on a flat surface from different directions (e.g., other than in the +x direction).

dmonah did lots of tests that suggested the problem lay in the recoil generation routine. These routines were a big part of the problem, as they introduced two issues for incident directions with non-zero z elements: first, a subtle distortion in the recoil locations is introduced for directions close to +/-z. Second, generated recoils were not consistently located in the plane of atomic deflection. This caused near-surface physics - particularly, low energy reflection and sputtering - to be affected for any incident atoms with a significant +/- z component to their velocity.

To fix this, I re-derived formulas for the recoil location and deflection. The updated formulas keep these directions consistent for all incident directions, fixing the issue

Tests

See comments in #286 for details on the various tests I'm running to make sure this is working correctly.

@drobnyjt drobnyjt changed the base branch from main to dev July 18, 2025 23:53
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