- #1
black_em2
- 6
- 0
I am trying to program the elastic collision response between a ball and an immovable obstacle (such as a rock with infinite mass). However I can't seem to figure out the angle at which the ball would bounce off of the object. Both objects are to be considered as circles, with their positions given as their centers, and their acceleration, velocity, and position are stored in X and Y components.
Based on this image, the angle that the ball would reflect would be equal to the orthogonal of the line between their centers and parallel to the normal surface between them. Is this true?
I am having a very hard time trying to determine the angle after the collision. Is there a way to do this using only vectors and no trig? My group members think so, but I don't know how you wouldn't use trig for this. Right now I am using C++ but will later be incorporated in objective-C. Please help!
Thank You
Based on this image, the angle that the ball would reflect would be equal to the orthogonal of the line between their centers and parallel to the normal surface between them. Is this true?
I am having a very hard time trying to determine the angle after the collision. Is there a way to do this using only vectors and no trig? My group members think so, but I don't know how you wouldn't use trig for this. Right now I am using C++ but will later be incorporated in objective-C. Please help!
Thank You
Last edited by a moderator: