# Physics Simulation Forum

 Page 1 of 1 [ 1 post ]
 Print view Previous topic | Next topic
Author Message
 Post subject: Revolute joint between two particlesPosted: Wed Feb 06, 2013 11:12 pm

Joined: Sun Jul 08, 2012 11:32 am
Posts: 74
Hi,

I am having trouble with implementing a revolute joint between two particles. I am representing the particle as having a position, velocity and acceleration and no angular dynamic components.

So the constraint derivation is as follows:

C = xa + ra - xb - rb
CDot = va - vb

CDot = [ 1 -1] [va vb]T

So the Jacobian is [1 -1]

I initially store the anchor in local coords of each particle

localA = worldAnchor - particleA.position
localB = worldAnchor - particleB.position

Since the particles do not rotate, they have an identity matrix at all times with translation components on their last row

[ 1 0 0 0 ]
[ 0 1 0 0 ]
[ 0 0 1 0 ]
[ tx ty tz 1 ]

So transferring the anchor points to world coords, I do the following:

worldAnchor1 = localA + m_pParticleA->position
worldAnchor2 = localB + m_pParticleB->position

Then the radii between the anchors and the bodies becomes:

ra = worldAnchor1 - m_pParticleA->position
rb = worldAnchor2 - m_pParticleB->position

This undoes the previous addition and returns world anchors to local anchors. How do I go about doing this properly?

Top

 Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending
 Page 1 of 1 [ 1 post ]

#### Who is online

Users browsing this forum: No registered users and 4 guests

 You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forumYou cannot post attachments in this forum

Search for:
 Jump to:  Select a forum ------------------ BULLET PHYSICS LIBRARY USERS    General Bullet Physics Support and Feedback    Release Announcements    Applications, Games, Demos or Movies using Bullet PHYSICS AUTHORING TOOLS, SERIALIZATION AND STANDARDS    Physics authoring tools, serialization, standards and related topics RESEARCH AND DEVELOPMENT IN COLLISION DETECTION & PHYSICS. Don't post Bullet support questions here!    Research and development discussion about Collision Detection and Physics Simulation    Links, Papers, Libraries, Demos, Movies, Comparisons       Non-technical forum and license/patent discussion    Career Opportunities