How Does the Jacobian Matrix Impact Collision Response in Physics Engines?

  • Context: Undergrad 
  • Thread starter Thread starter g3ronimo
  • Start date Start date
  • Tags Tags
    Jacobian
Click For Summary

Discussion Overview

The discussion centers around the role of the Jacobian matrix in collision response within physics engines. Participants explore the mathematical foundations necessary for implementing collision solvers, particularly in the context of iterative versus single-pass algorithms. The conversation includes requests for resources and examples related to the Jacobian matrix and its application in physics simulations.

Discussion Character

  • Exploratory
  • Technical explanation
  • Debate/contested
  • Mathematical reasoning

Main Points Raised

  • One participant expresses difficulty in understanding the Jacobian matrix and seeks simpler resources for learning about its connection to collision response.
  • Another participant suggests specific online resources for understanding the Jacobian matrix.
  • A request for examples of using the Jacobian matrix with forces and torques is made.
  • One participant argues that the method of solving contact constraints is more important than the form of the constraints, mentioning the sequential impulse solver attributed to Erin Catto as a potentially useful approach.
  • There is a discussion about the availability of literature on the sequential impulse solver and its relationship to the Jacobian matrix, with suggestions to search for related terms and references.
  • Participants mention that the Bullet physics engine implements a Jacobian formulation in 3D, contrasting it with Box2D's 2D implementation.
  • There is mention of a formal method called projected Gauss-Seidel, with a suggestion that it is conceptually similar to the sequential impulse approach.

Areas of Agreement / Disagreement

Participants do not reach a consensus on the necessity of the Jacobian matrix for improving physical accuracy in collision response. There are competing views on the importance of the method used to solve contact constraints versus the mathematical formulation employed.

Contextual Notes

Some participants note limitations in their understanding of the mathematics involved, particularly regarding the Jacobian matrix and its applications. There are also references to the complexity of existing literature, which may not be accessible to all participants.

g3ronimo
Messages
3
Reaction score
0
Hello,
I'm trying to make my own physics engine. I've already made one with momentum and an very easy
collision solver, but it was creepy and full of bugs because I solved the contacts one after another.
Then I read about the difference between iterative and single pass algotrithms and I tried to get into some deeper math but I was definitely limited by my little knowledge in matrices. So I started to improve this but apart from learning the basic handling with matrices I have some problems understanding the Jacobian matrix and its connection to the collision response. Could you recommend
me some "simpy explained" resources on this topic? I had a look into Game Physics from David Eberly
but the math required for this book is too heavy for me in moment. I am familiar with differentation
and things like that from school but It's hard for me to master resources with such a strong level of
abstraction.

Thanks in advance and excuse for my beginner english:)
 
Physics news on Phys.org
Could you give me an example how to use it with forces? ( and or torques )
 
g3ronimo said:
Hello,
I'm trying to make my own physics engine. I've already made one with momentum and an very easy
collision solver, but it was creepy and full of bugs because I solved the contacts one after another.
Then I read about the difference between iterative and single pass algotrithms and I tried to get into some deeper math but I was definitely limited by my little knowledge in matrices. So I started to improve this but apart from learning the basic handling with matrices I have some problems understanding the Jacobian matrix and its connection to the collision response. Could you recommend
me some "simpy explained" resources on this topic? I had a look into Game Physics from David Eberly
but the math required for this book is too heavy for me in moment. I am familiar with differentation
and things like that from school but It's hard for me to master resources with such a strong level of
abstraction.

Thanks in advance and excuse for my beginner english:)

I don't think moving to a Jacobian form will help you much, providing that what you're doing is physically correct.

The key to solving your contact constraints is how you solve them, not the form that they're in. The method that you're most likely to be interested is the incredibly simple sequential impulse solver attributed to Erin Catto.

One thing that will be useful to you, that you may not find as you study this, is as you iterate through your solver, if the required impulse at a contact is ever negative, then you should completely remove the accumulated impulse from that contact.

Another thing that isn't often discussed is how to solve for any residual interpenetration. It's less critical, but you can just follow a similar method for position too once you've solved for velocity.
 
Last edited:
craigi said:
The key to solving your contact constraints is how you solve them, not the form that they're in. The method that you're most likely to be interested is the incredibly simple sequential impulse solver attributed to Erin Catto.

Can I read about it somewhere or do I have to check the Box2d source code? My main purpose
was to get more physical accuracy and in this context Erin Catto always mentioned the Jacobian.
I think he never really described his solver or maybe I just missed it.:confused:
 
g3ronimo said:
Can I read about it somewhere or do I have to check the Box2d source code? My main purpose
was to get more physical accuracy and in this context Erin Catto always mentioned the Jacobian.
I think he never really described his solver or maybe I just missed it.:confused:

I don't have a good reference for it, but if you search "sequential impulse solver", you should find it. It's really not very complicated. You can guess how it works from its name.

Box2D, as its name suggests is 2 dimensional. The Bullet source code implements it in 3D and uses a Jacobian formulation, if I recall correctly.

I don't know if the sequential impulse solver was ever presented formally. Try searching for Brian Mirtich too.

There is a formal method called projected Gauss-Seidel, but they can be demonstrated to be equivalent and the sequential impulse approach is much easier conceptualise. If you can't find a good reference for it, then you could examine the PGS method and you should be able to see how it works.
 
Last edited:

Similar threads

  • · Replies 9 ·
Replies
9
Views
2K
  • · Replies 5 ·
Replies
5
Views
9K
  • · Replies 14 ·
Replies
14
Views
4K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 45 ·
2
Replies
45
Views
5K
  • · Replies 11 ·
Replies
11
Views
3K
  • · Replies 1 ·
Replies
1
Views
4K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 1 ·
Replies
1
Views
5K