Dhea H.

asked • 06/04/20

What is the Formula of getting the x,y of a point when a ball is colliding inside the rectangle

Simulation Scenario:

I have 900x600 size of a rectangle


The first angle of the ball when bouncing the edge of the rectangle is 40degrees.

Starting position of the ball is:

Px = 500

Py = 450 (edited)


Assuming there is no friction or gravity as I just want to simulate the path of the ball.

What are the points when the ball reaches to the wall as it bounces 5x of the rectangle?


How to get the reflection points that are located at the sides of the table?


Thank you.

Logan B.

Is the 900 x 600 in the format height x width? If not, then you may have the initial position of the ball mis-typed.
Report

06/04/20

Dhea H.

Yes you are right. The initial of the ball should be (500,450). Sorry about that. Can you help how to get those points or the bounding coordinates that the ball bounce to the edge of the rectangle? Thank you for your help.
Report

06/04/20

3 Answers By Expert Tutors

By:

Tom K. answered • 06/04/20

Tutor
4.9 (95)

Knowledgeable and Friendly Math and Statistics Tutor

Dhea H.

Hi Tom, Can you explain more on how did you come up these coordinates (500,450), (679,600), (900,414), (406,0), (0,341)? Thank You
Report

06/04/20

Tom K.

The first point is the starting point. You go until you either reach the top or the right. In this case, to reach the right, you would have to be far above 600, so you reach 600 first (at 679, 600; remember slope is .8391), then you reflect and are moving at slope -.8391 to the right and reach (900,414); you then have slope .8391 until you reach (406, 0), ...I can provide an Excel sheet with formulas.
Report

06/07/20

William W. answered • 06/04/20

Tutor
4.9 (1,021)

Top Pre-Calc Tutor

Dhea H.

Hi William, How do I get the next 4-5 bounding points based on the angle of reflection when it bounces back to the side, bottom etc.? And what if this 40 degrees angle will position at the bottom right and it bounces first at the right side of the table going to the top? In calculating the next bounding points, what is the best technique in getting the reflected angle? Thanks in advance.
Report

06/04/20

Logan B. answered • 06/04/20

Tutor
New to Wyzant

Intuitive Mathematics Instructor Focused on Advanced Mathematics

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.