Involves physics but I have to program, can't figure out equation

In summary, the conversation discusses an experiment on an infinitely long "billiards" table with a ball that is sent off at an initial speed and angle. The ball bounces off the sides with no loss of energy and decelerates at a constant rate. The goal is to compute all points where the ball hits the lower wall before running out of energy. The solution suggested is to use a trick of stacking mirror-image versions of the table and using a single equation for the path of the ball.
  • #1
CProgWiz
2
0
Involves physics but I have to program, can't figure out equation!

Homework Statement


Imagine an experiment performed on an infinitely long “billiards” table. This table is bounded at the far side and the near side, and these sides are a distance w apart. A ball (of diameter 0) is adjacent to the near side, at x coordinate 0. It is sent off at an initial speed v and at an angle . (is measured as follows: if the ball heads straight to the left, that would be -90 degrees, if it heads straight across that would be 0degrees, and if it heads straight to the right that would be 90 degrees.) The ball decelerates at a rate of d. When the ball bounces off either side, the bounce is “true”; that is, it bounces off just like a ray of light bouncing off a perfect mirror. The collisions with the top or bottom of the table absorbs no energy.

Compute all points where the ball hits the lower wall before it runs out of energy and stops.
(In the x direction)

Homework Equations



I don't know, that's what I need help figuring out!

The Attempt at a Solution



Well, I was thinking that the angle at which the ball is struck in the beginning, must be equal to the angle that the ball bounces off the wall at, each time.

I'm not sure if I should use momentum, or what! I'm more or less LOST! Help please.
 
Physics news on Phys.org
  • #2


An often used trick for theses sorts of problems is to imagine stacking a series of mirror-image versions of the table side by side or end to end. Then imagine that the ball, when it strikes a side, rather than bouncing it passes through to the next mirror-image table and proceeds in a straight line. This straight line motion image simplifies things considerably since you can use a single equation for a line for the path.

attachment.php?attachmentid=40221&stc=1&d=1319287015.gif
 

Attachments

  • Fig1.gif
    Fig1.gif
    2.8 KB · Views: 512

Related to Involves physics but I have to program, can't figure out equation

1. What kind of physics principles do I need to understand in order to program?

In order to program, it is important to have a basic understanding of principles such as kinematics, mechanics, and electricity and magnetism. These concepts will help you understand how objects move and interact in the physical world, which is essential for writing accurate and effective code.

2. How can I use physics equations in my programming?

Physics equations can be used in programming to model and simulate real-world scenarios. By plugging in variables and values into these equations, you can create algorithms that accurately represent the behavior of physical systems.

3. What resources can I use to learn more about the physics concepts I need for programming?

There are many resources available online, such as textbooks, tutorials, and videos, that can help you learn more about the physics principles you need for programming. Additionally, many programming languages have libraries or modules specifically designed for physics simulations.

4. How can I check if my code accurately represents the physics involved?

In order to ensure that your code accurately represents the physics involved, you can test it by comparing the results to real-world data or by running simulations and observing the behavior of the virtual system. You can also consult with other programmers or physics experts for feedback and validation.

5. Can I program without a strong background in physics?

While having a strong understanding of physics can be beneficial for programming, it is not always necessary. Many programming languages have built-in functions and libraries that simplify the use of physics equations. Additionally, there are resources available that provide step-by-step instructions on how to use these functions for specific applications.

Similar threads

  • Programming and Computer Science
Replies
10
Views
3K
Replies
34
Views
2K
  • Engineering and Comp Sci Homework Help
Replies
3
Views
1K
  • Introductory Physics Homework Help
Replies
3
Views
3K
Replies
15
Views
5K
Replies
6
Views
1K
  • Classical Physics
Replies
14
Views
1K
  • STEM Academic Advising
2
Replies
63
Views
5K
  • Engineering and Comp Sci Homework Help
Replies
2
Views
1K
Back
Top