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

Velocity Vectors are not updated when rays change directions #39

Open
gsgall opened this issue Jun 3, 2024 · 0 comments
Open

Velocity Vectors are not updated when rays change directions #39

gsgall opened this issue Jun 3, 2024 · 0 comments

Comments

@gsgall
Copy link
Collaborator

gsgall commented Jun 3, 2024

Bug Description

Because we store a 3D velocity vector in ray data that is separate from the direction stored on the ray the velocity vector will not always be consistent with the direction if a ray were to change trajectory during a trace. This shouldn't really happen except in the case where a particle might reflect off a boundary. In this case the 3D velocity vector we store on the ray will be inconsistent with the direction the ray is actually traveling and we will need to update this vector on a trajectory change.

Steps to Reproduce

Create a particle with some velocity pointed at a boundary, set the maximum distance to be large enough that the particle will hit the boundary and condition with a different direction. The ray direction and the velocity stored in ray data at this point will be inconsistent.

Impact

This may happen on occasion but since we have not yet established the boundary conditions that particles will have when they interact with a boundary and current mapping is still underdevelopment the impact of this is unclear but it should be sorted out to ensure true consistency.

Suggested Design

Since the only time a particles trajectory should ever change is when it would hit a boundary or during collisions and velocity updates, which do not occur during tracing, it probably makes the most sense to create an extended ReflectRayBC which also ensures consistency between the velocity vector stored in ray data and the direction the ray is traveling in.

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

No branches or pull requests

1 participant