Sign in to follow this  

Rigid body phyisics

This topic is 4197 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I'm developing a video game, in which I'm making a charactar with rigid-body physics (also known as "ragdoll" physics). The way I've made it is probably not completely realistic, because I only use velocity vectors to calculate the position of each joint of the "ragdoll", based on an initial velocity vector applied to a joint. If you want to check it out, you can download it here. The way I do this is illustated in this image: Diagram1 Anyway, the problem I have now is how to calculate the velocity vector of joints that make an angle that is restricted (an angle that shouldn't get any bigger, for example). This simplified diagram illustrates my problem: Diagram2 In the diagram, how should I calculate vectors v1 and v2? Note that in the diagram, the entire body should be rigid, because of the angle restriction. I would truly appreciante any help on this...

Share this post


Link to post
Share on other sites
This is fairly simple. As you've illustrated it, both links are rigid linked, due to one angle being maxed. So, if there is no rotation, V1 and V2 are identical to the known V, e.g., V1 = V2 = V.

Now, lets supposed that the whole thing is rotating with an angular velocity, w (radians/sec). Note that w is a vector. Still hold the two links to be rigidly linked---the angle remains at its max setting. In this case, you have to include the rotation in the computation of the velocities V1 and V2. Here's how you do it, using a kinematic relationship:

1) Let r1 = the vector from the point with the known velocity to point 1, which has velocity V1

r1 = location_of_point_1 - location_of_point_with_known_velocity_V

2) Compute the contribution of rotational velocity onto the translational velocity of point 1. 'x' means cross product


V1_rot = w x r1


3) Assign the translational contribution:


V1_trans = V


4) Add them together to get the full translational velocity of point 1:


V1 = V1_trans + V1_rot

...or...

V1 = V + (w x r1)


That is all! Do the same thing to find V2. The difference will only be that r2 is different from r1.

Share this post


Link to post
Share on other sites

This topic is 4197 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this