Monday, November 11, 2019

momentum - Vector equation of final velocity of two spheres after a fully elastic collision in 3D space



I'm experimenting with 3D graphics a bit and I'm trying to implement collision between some fully elastic moving spheres. The problem is I couldn't find a proper equation for collision in 3D space.


The wikipedia page for elastic collision contains equations for linear and collision in 2D plane. https://en.wikipedia.org/wiki/Elastic_collision



Answer



Sorry about the cross product reference, it's difficult to judge who knows what about a subject, and I usually get it wrong.


If this answer is no good to you, I will delete it:


This is all taken from 3-D collisions modelling , so my apologies if it's familiar to you.



When two particles contact each other, the force between the molecules is directed along an imaginary line that connects their centers. If you rotate your frame of reference so this center-line is along the x-axis, this is simply a 1-D collision problem, where in an elastic collision, the forces acting upon each other are just switched (in equal mass cases -- this code does mass-weight the vector switching for colliders with unequal masses, which is not reflected in the equations).


Step 1: Determine the 3D angle between the two colliders.




enter image description here



Step 2: Calculate the colliders' force vectors towards each other.



enter image description here



Step 3: Decompose this vector into x'-y'-z' components, where x' is aligned with the center-line.



enter image description here


enter image description here



Vector fields


Vectors are defined in spherical coordinates by (ρ,θ,φ), where


$ρ$ is the length of the vector,$θ$ is the angle between the positive Z-axis and the vector in question $(0 ≤ θ ≤ π)$, and $φ$ is the angle between the projection of the vector onto the X-Y-plane and the positive X-axis $(0 ≤ φ < 2π)$.


by:


$${\displaystyle {\begin{bmatrix}x\\y\\z\end{bmatrix}}={\begin{bmatrix}\rho \sin \theta \cos \phi \\\rho \sin \theta \sin \phi \\\rho \cos \theta \end{bmatrix}}.}$$


Above is from Wikipedia, so it does not take into account his remark about x' being aligned along the center line.



Step 4: Before switching the colliders' force vectors, determine the force vector normal to the center-line so we can recompose the new collision.



enter image description here



enter image description here



Step 5: Switch the colliders' force vectors.



enter image description here



Step 6: Compose the new vectors into a new velocity:



enter image description here1)




Assumptions:


1) All collisions are elastic.


2) All particles are perfect spheres.


3) That the objects can come closer than the sum of the radii of the two particles.


4) Only two particles can collide at a time. If three technically hit together, the particle with the lowest array index will collide with the second lowest, then separately with the next lowest. Then, if the second is still close enough to the third, a third collision will result.



No comments:

Post a Comment

classical mechanics - Moment of a force about a given axis (Torque) - Scalar or vectorial?

I am studying Statics and saw that: The moment of a force about a given axis (or Torque) is defined by the equation: $M_X = (\vec r \times \...