Calculating Ball Speed and Direction After 2D Collision: Game Programming Tips

AI Thread Summary
To calculate the speed and direction of two balls after a 2D collision, one must apply the principles of momentum conservation. The equations for both the x and y dimensions should be established to account for the velocities of both balls before the collision. The discussion highlights the importance of determining whether the collision is elastic or inelastic, with a focus on billiard ball-like behavior. Resources such as Wikipedia provide equations for elastic collisions, which may be relevant depending on the game's mechanics. Accurate ball behavior in the game can be achieved by implementing these calculations while considering future adjustments for friction and other forces.
Cruncher
Messages
5
Reaction score
0
Okay this is a question about after two balls collide knowing their speeds and directions and mass before collision, what is their speed and direction after collision in two dimensional space.


more specifically i need to know this because i am programming a game in which i need accurate ball behavior so, assuming collision occurs at the origin, and ball one comes from x degrees and ball 2 comes from x degrees, and i know their speeds, and can make up a mass for them based on their size,

how do i figure out their direction and speed? also note that at this point i am ignoring friction or anyother outside forces, but that will change in later development

thanks for any help and guidance you could give me

Cruncher,
 
Physics news on Phys.org
You need to use the equation for collisions. I don't know whether in your case it is elastic or inelastic. Write an equation for each dimension, one for all momentum in the x direction and one for all the momentum in the y direction.
 
it is not elastic, it is as though 2 billiard balls hit each other.. do you know where i could find these equations? thanks

Cruncher
 
The rope is tied into the person (the load of 200 pounds) and the rope goes up from the person to a fixed pulley and back down to his hands. He hauls the rope to suspend himself in the air. What is the mechanical advantage of the system? The person will indeed only have to lift half of his body weight (roughly 100 pounds) because he now lessened the load by that same amount. This APPEARS to be a 2:1 because he can hold himself with half the force, but my question is: is that mechanical...
Hello everyone, Consider the problem in which a car is told to travel at 30 km/h for L kilometers and then at 60 km/h for another L kilometers. Next, you are asked to determine the average speed. My question is: although we know that the average speed in this case is the harmonic mean of the two speeds, is it also possible to state that the average speed over this 2L-kilometer stretch can be obtained as a weighted average of the two speeds? Best regards, DaTario
Some physics textbook writer told me that Newton's first law applies only on bodies that feel no interactions at all. He said that if a body is on rest or moves in constant velocity, there is no external force acting on it. But I have heard another form of the law that says the net force acting on a body must be zero. This means there is interactions involved after all. So which one is correct?

Similar threads

Replies
9
Views
1K
Replies
4
Views
2K
Replies
3
Views
715
Replies
3
Views
2K
Replies
13
Views
3K
Back
Top