Reputation: 65
I'm currently creating a system of spheres which can actuate to push each other away. There are center bodies (teal) at each corner which are connected to connecting bodies (yellow) via PrismaticJoint
which are connected in the same way to the next corner.
When creating a one dimensional system of spheres, for example, a 1x1x4 system, I run into no errors and the system behaves as expected.
In trying to create a system of eight spheres in a 2x2x2 orientation, I'm running into mobilization errors. Here is what the system looks like:
And the error:
terminate called after throwing an instance of 'std::runtime_error'
what(): This mobilizer is creating a closed loop since the outboard body already has an inboard mobilizer connected to it. If a physical loop is really needed, consider using a constraint instead.
Aborted (core dumped)
I understand that the error comes for joints sharing child or outward bodies, like in the case for two sides of the cube actuating one corner. Unfortunately, I haven't found a way to pivot using constraints successfully. How can I better define this system?
Upvotes: 0
Views: 105
Reputation: 678
One way to address this is to use a Drake bushing element (essentially a stiff spring and damper) to emulate a "weld" constraint. There is a nice example of this approach in Drake -- see examples/multibody/four_bar.
The general idea is to break topological loops by sawing through one or more bodies, then welding them back together with a bushing (which does not count as a topological loop).
Upvotes: 1