[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Physics module status note, more things...



Peter Gebauer wrote:

I don't have a clue about the math involved to calculate the force, but I could give it a stab.

As Archimedes pointed out, the upward force on an immersed
body is equal to the weight of water it displaces. So just
apply a force proportional to the volume that is under
the water.

You'll also want a drag force proportional to the velocity
of the body and the immersed volume, to stop it from
accelerating indefinitely while submerged, and to damp
down oscillations when it's floating on the surface.

--
Greg