Pressure, friction, force transfer, and data read-back?

Please don't post Bullet support questions here, use the above forums instead.
Boris
Posts: 1
Joined: Tue Apr 21, 2009 5:02 pm

Pressure, friction, force transfer, and data read-back?

Post by Boris »

Hi, this is my first post on this forum. Please bear with me, as I have no prior experience with these sorts of physics simulations (though otherwise I'm an experienced coder.) It's a rather steep learning curve for me; any help is appreciated.

I am working on a bit of research, which in part involves simulating various modes of locomotion. The basic problem statement:

* I have a 2D height map (polygonal representation) surface, which is the "ground". Each vertex on the surface has a friction coefficient property, which is linearly interpolated between vertices (so, parts of the surface may be more slippery, while other parts are rougher.)

* Resting on that surface (gravitationally), is what I think is basically a ragdoll (please correct me if I'm wrong): a chain of basic shapes (maybe spheres) attached to a "skeleton". The potential configurations are highly variable, but the basic skeleton building blocks consist of bones and ball-socket joints, with bones incompressible and joints having rotational range constraints.

* The skeleton is driven by very crude actuators, which simply apply an amount of rotational force to a particular joint in a particular direction around a particular axis. With actuators active, the parts of the "body" (defined by the basic shapes attached to the skeleton) touching the ground will create a motive force, which should propagate through the skeleton to all the other parts -- eventually causing the entire body to move in some way, perhaps mostly just thrashing or twisting about without really accomplishing much, but also hopefully sometimes propelling it relative to the ground in some overall direction. (Of course, another source of motion forces would be the momentum/inertia of the various parts of the body as they are pushed/pulled by other parts.) The body cannot intersect/interpenetrate itself.

* The idea is to start with a given configuration of the skeleton relative to the ground, apply an initial set of forces to each joint, and let the system "relax" for a few time-slices. Then read-back some data (elaborated below), feed that data into an algorithm that will re-adjust the forces on joints, and simulate the system for a few more time-slices. Rinse, repeat, etc.

* The data I need to be able to read-back includes the points at which the body is touching the ground, as well as the pressure applied to the ground at each of those points. It would also be very nice to know the tension/compression load and torque created at each joint by the body's own weight and inertia, as these forces cascade throughout the skeleton. Lastly, it would be neat to have an acceleration read-out from the various parts of the body.

Note that I don't need really high accuracy, or really high degree of realism. Just a superficial first-order approximation will suffice. I'm not too worried about perfect conservation of energy, though any violations shouldn't be so egregious as to render the simulation utterly unrealistic. The simulation would also have to run reasonably fast (at least 100 Hz, if not faster -- so at most 10 milliseconds per cycle) on a regular mid-range PC (assuming a skeleton of limited complexity -- on the order of at most a few dozen bones/joints.)

So the first key question is, will I be able to achieve my goals with Bullet? I've read through a number of posts on this forum, but I'm still not sure that Bullet would provide *all* the functionality I need.

If not, can anyone suggest a physics engine that would work for me?

Better yet, are there already any demos or applications resembling mine out there, with available source?

Lastly, can you suggest any good book on the topic, suitable for someone who has never done computational physics before, and is not initially familiar with all the math, algorithms, and jargon involved (I have done Calculus and Linear Algebra, but I never studied tensors or worked with Jacobians, for example)?

Thanks very much for any help whatsoever!