Nurturing innovative business models to build tomorrow's enterprises

Realistic 2-D Collision Simulation

By Thomas Cheah • November 22, 2001 • Filed in: Software Technology

This Java application simulates a realistic collision of spherical objects in a two dimensional space. The calculations for the collision response in this simulator is based on the Newton’s “Conservation of Linear Momentum” theory. This theory said, when a collision occurs in an isolated system, the total momentum of the objects in the system before the collision equals to the total momentum afer the collision”. This theory is used to calculate the velocity of the objects after collision. Certain collisions are called elastic collision, which both momentum and kinetic energy are conserved. In an inelastic collision, the total kinetic energy before and after the collision is not conserved. In a 2-D collision, we also know the fact that only the velocity that is parallel to the collision direction is changed. The velocity that is perpendicular to the collision direction remains unaffected. With these knowledge in mind, we can create a somewhat realsitic simulator that illustrates the collision among spherical objects.


How to run the program:

  1. Download the Java archive of the application here.
  2. You need to have Java Runtime version 1.3 or above installed on your PC.
  3. Double click on the Java archive 2d_collision.jar that you have downloaded.
  4. If it fails to run, you need to execute it in Command Prompt / Console. Go to the directory where your download is saved. Type java -jar 2d_collision.jar

Instructions:

  1. The bottom panel has several attributes that you can alter to create a collision system that you desire.
  2. The Coefficient of Restitution accepts a real number from 0.0 to 1.0. The value determines the elasitcity of the collision in the system. A value of 1.0 will create a perfectly elastic collision among objects, while 0.0 will make the collision in the system totally inelastic.
  3. After you had changed the attributes, click on Apply button to reinitialize the simulator with the new settings.
  4. Click on Start button to begin the simulation and Stop button to stop it.

This program let you experiment with the following:

  • Conservation of Linear Momentum in an isolated system.
  • The collision response among spherical objects in a two dimensional space.

About The Author

Thomas CheahThomas Cheah is the Principal CTO-for-hire of Procto. He helps business owners and executives to innovate their business model thru strategic technology management so that they get 80% of the benefit for 20% of the cost. If you have innovative ideas but do not the technical expertise, he is your partner to validate and build your digital business models. Thomas believes that constant business innovation is increasingly important in today's business environment so that our business is prepare for rapid change of customer behavior, rising cost, and globalization in order to stay ahead (or away) of competition.

Learn more about Thomas.

Comments

I appreciate your work , regards for all the useful posts .

Fantastic post however , I was wondering if you could write a litte more on this subject?
I’d be very grateful if you could elaborate a little bit further. Appreciate it!

 

Leave a Comment

« | Home | »