WorldViz User Forum Can Vizard/OPAL create a perfectly elastic collision?
 Register FAQ Search Today's Posts Mark Forums Read

#1
01-06-2014, 07:26 AM
 performlabrit Member Join Date: Oct 2013 Posts: 77
Can Vizard/OPAL create a perfectly elastic collision?

I'm currently trying to have a ball bounce upon the ground so that the interaction is perfectly elastic. THus, upon bounce, the amount of energy lost would be equal to the "coefficient of restitution (COR)" that arises between the two colliding objects.

A COR of 1 would mean that a dropped ball would always return to its original height after the bounce, and would bounce forever. A COR of .5 would cause the ball to lose half its energy upon a bounce, and thus each consecutive bounce would reach half the height of the previous bounce.

Using open dynamics engine (ODE), one could do this by simply creating a plane. By default, the plane would have infinite mass and perfect hardness for a completely elastic collision. Thus, to simulate a coefficient of restitution of .5, one only needed to set the ball's bounciness to .5.

OPAL doesn't seem to create physical objects in the same way, and so energy is always lost upon a collision. I believe I need to manually set the density/hardness of the floor for a perfectly elastic collision, but it's unclear how to do this.

Thanks,
- Gabriel Diaz
#2
01-06-2014, 10:57 AM
 performlabrit Member Join Date: Oct 2013 Posts: 77
I've shared this problem with a good friend, and master of ODE (open dynamics engine). The physics engine used by Vizard (OPAL) is just a high-level interface to ODE. He was pretty confused by the issue I'm having, and took a look.

His conclusion is that I should have a perfectly elastic collision when hardness, density, and bounciness are set to 1. If the collision is not perfectly elastic, it's likely because of the way the collision is calculated.

Upon a collision, ODE creates a "collision joint," which has a few influential parameters associated with it. For example, having a constraint force mixing (CFM) parameter > 0 affords some robustness/flexibility in calculations related to the collision at the cost of accuracy. If CFM is 0, then one will have more accurate calculations, but the system will be more likely to crash. By default, the CFM is > 0, and thus a likely source of lost energy upon collision.

To test our guess, that the issue is caused by a CFM > 1 would require the ability to change the CFM of a collision joint. Unfortunately, Vizard/OPAL does not allow the user to modify the CFM parameter. Furthermore, I cannot modify opal, because Vizard provides only the DLL files, and not the source code. I will contact Vizard to see if they can add the function, and will report back.

- gD

Last edited by performlabrit; 01-06-2014 at 11:03 AM.

 Thread Tools Display Modes Rate This Thread Linear Mode Rate This Thread: 5 : Excellent 4 : Good 3 : Average 2 : Bad 1 : Terrible

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is Off Forum Rules
 Forum Jump User Control Panel Private Messages Subscriptions Who's Online Search Forums Forums Home Announcements Vizard Precision Position Tracker (PPT) Plug-in development

 Similar Threads Thread Thread Starter Forum Replies Last Post turgutm Vizard 2 01-05-2011 12:19 AM rubberpimple Vizard 4 09-17-2008 05:27 PM

All times are GMT -7. The time now is 08:40 AM.