cyclic coordinate descent inverse kinematics

Started by
3 comments, last by Genjix 16 years, 11 months ago
Hi! I'm trying to implement some form of inverse kinematics, and from what I've read it seems this method is better than the Jacobian variant- I hope I've made the correct choice! Anyway, from what I'm reading it seems that from the root bone I just have to iteratively nudge them 1 degree at a time, minimising the distance to the target at each step. Is that correct? From CCD article, I think theres a mistake on that page too. It defines
F = F1M12 + F2M22F3M32
Probably should be,
F = F1M12 + F2M22 + F3M32
How can I use this to make Inverse Kinematics? Is that last section with S, a, b, c, just relevant to proteins, because that seems only relevant for that 2 axis layout. All the equations there seem to be specifically for 2D... How can I do this in 3D? Solving for 2D using trig is easy... But how with 3D, when you have rotation constraints too? Thanks!
Advertisement
Quote:
Anyway, from what I'm reading it seems that from the root bone I just have to iteratively nudge them 1 degree at a time, minimising the distance to the target at each step.

I only glanced at that article and I've never done inverse kinematics myself, but from how you explained it this sounds something like a direct greedy approach to inverse kinematics. I can see how something like that might work, but maybe not in all cases and I don't think it would produce very natural movements. You could loop through each joint and check the closeness to the goal if it were left alone, moved one degree up, or moved one degree down. Then bend that joint(or not) to whichever position had the highest fitness. For ball socket joints 2 perpendicular regular joints could be used really close together.
Quote:
I'm trying to implement some form of inverse kinematics, and from what I've read it seems this method is better than the Jacobian variant- I hope I've made the correct choice!

I never implemented CCD, but I did Transpose, PI, and DLS, and there is a pretty big difference in them, but CCD apparently is fine if you are only ever making very small changes,...

Dampened Least Squares would be my recommendation though.
(get some source code for IK here:
http://jgt.akpeters.com/papers/BussKim05/
)
Quote:Original post by Genjix
I'm trying to implement some form of inverse kinematics, and from what I've read it seems this method is better than the Jacobian variant- I hope I've made the correct choice!

It's often more efficient than the Jacobian variant, particularly for long joint chains. It is less likely to produce realistic motions, particularly for large target displacement.

Quote:Anyway, from what I'm reading it seems that from the root bone I just have to iteratively nudge them 1 degree at a time, minimising the distance to the target at each step. Is that correct?

No. The way CCD works is, you numerically figure out which position is best for that particular joint, keeping all other joints constant.

Here's an example. Suppose my right upper arm is out in front of me and my forearm is pointing straight up (try that out now) and I want to reach out to a point 3 feet in front of me. Let's assume I move my shoulder, then my elbow. So first I'd pivot my shoulder down while keeping my elbow locked at a 90 degree angle, with the result that my hand would be close to the target point but not touching it. Then I'd move only my elbow, while keeping my shoulder at the position I'd found before. Again I wouldn't quite get there, but I'd put my elbow in the best possible position for that shoulder position. Then I'd only move my shoulder again. And so on, until I hit the target, or at least got close enough.
Quote:Original post by Sneftel
Quote:Original post by Genjix
I'm trying to implement some form of inverse kinematics, and from what I've read it seems this method is better than the Jacobian variant- I hope I've made the correct choice!

It's often more efficient than the Jacobian variant, particularly for long joint chains. It is less likely to produce realistic motions, particularly for large target displacement.

Quote:Anyway, from what I'm reading it seems that from the root bone I just have to iteratively nudge them 1 degree at a time, minimising the distance to the target at each step. Is that correct?

No. The way CCD works is, you numerically figure out which position is best for that particular joint, keeping all other joints constant.

Here's an example. Suppose my right upper arm is out in front of me and my forearm is pointing straight up (try that out now) and I want to reach out to a point 3 feet in front of me. Let's assume I move my shoulder, then my elbow. So first I'd pivot my shoulder down while keeping my elbow locked at a 90 degree angle, with the result that my hand would be close to the target point but not touching it. Then I'd move only my elbow, while keeping my shoulder at the position I'd found before. Again I wouldn't quite get there, but I'd put my elbow in the best possible position for that shoulder position. Then I'd only move my shoulder again. And so on, until I hit the target, or at least got close enough.


Thanks! This is kind of what I meant though :)

How does IK tie into the whole situation then of animated characters and the environment? Say I'm running up stairs- I'm told IK would be used here- surely I would just interpolate and stop moving an FK chain if theres a collision response instead of using IK?

Thanks again.

This topic is closed to new replies.

Advertisement