Search In
• More options...
Find results that contain...
Find results in...

# Basic physics

## Recommended Posts

Alright. In my eternally procrastinated quest to build a physics engine for my game, I'm have to relearn some simple physics. I managed to get an A in physics class, and not learn a damn thing at the same time. So anyways, here it is:

A given object, say object A, has a given vector named va1 . Va1's magnitude is A's speed x mass. So for example, object A has a mass of 5 and a speed of 2 for a magnitude of 10 (in some standard units). Object B is standing still, and depending on the situation, has various masses. So its vector, vb1, is 0. When object A collides with object B, there's energy transfer, and I need to know exactly how it works

Now, forget for a moment that there's energy 'lost' in the transfer (i.e. turning into heat, sound, whatever). And for sake of argument, this is a frictionless environment. Finally, don't worry about direction

I know that if both objects are a mass of 5, then when A hits B, something like this happens:
B exerts the force on A that A exerted on B. Therefore, a second vector will be added to A, and A will come to a stop. A second vector will be added to B and B will go up to a speed of 2 so that no energy is lost. If B's mass were 2, then it's speed would go up to 5.

However, B may not be able to exert that much force in A to stop it, and so both objects would keep on moving in the direction A was moving in. Or A might just bounce off B.

This should give you a good idea of what I know. Here's what I want:
Can someone give me a few instances of collision events and explain the machanics to me so I have a good idea of how to make this. I'd greatly appreciate it, and kudos to anyone who read this far.

Ugh... brings back memories of high school physics. Bad memories of doing badly in the class, but still having fun... weird.

JavaGuy4230 said:

And for sake of argument, this is a frictionless environment.

But I assume it accounts for inertia?

How fucking hard can it be to program equal and opposite reactions!?

Depends on whether you want an elastic or inelastic collision.

If you create a working atomic model and throw in a few billions of atoms then the collisions should work out automatically.

Tempted to give a lengthy reply to this but I don't have time for lengthy physics discussions until Wednesday night. :p

Tobester said:

How fucking hard can it be to program equal and opposite reactions!?

Do it.

DC

Shit, this reminds me of how much I should right now be revising a phat load of A-level physics. I've forgotten how momentum works. Although I can recall basic facts to do with the photo-electric effect. Yay me.