Simulate ball colliding with moving parabolic surface

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Simulate ball colliding with moving parabolic surface

Postby MrPrezident » Tue Oct 02, 2018 11:51 pm

I'm trying to simulate some balls bouncing on a moving parabolic surface. How would I go about handling the collisions for the parabolic surface? Do I need to create a parabolic collision primitive?
MrPrezident
 
Posts: 13
Joined: Tue Oct 02, 2018 11:30 pm

Re: Simulate ball colliding with moving parabolic surface

Postby Julio Jerez » Wed Oct 03, 2018 9:59 am

there is not support for implicit surfaces.
only convex implicit solids like boxes, cylinder, capsule, cones and convex polyhedras.

for static meshes you could make a user define mesh.

if your moving parabolic shape is solid, you could make it a high density convex hull.

but that's the scope of the engine.
Julio Jerez
Moderator
Moderator
 
Posts: 11045
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Simulate ball colliding with moving parabolic surface

Postby MrPrezident » Wed Oct 03, 2018 5:40 pm

I can't use a convex hull because the shape is not convex. The shape I am using is a solid cylinder where the top of the cylinder is a symmetrical concave paraboloid surface instead of a flat surface (i.e. z = a*x^2 + a*x^2 + b). According to the wiki, it says that you can "define your own collision primitive types."
http://newtondynamics.com/wiki/index.ph ... primitives

I would have thought that defining a custom collision primitive would solve my problem. Is that not true, or is the problem that I can only define a convex primitive?
MrPrezident
 
Posts: 13
Joined: Tue Oct 02, 2018 11:30 pm

Re: Simulate ball colliding with moving parabolic surface

Postby Julio Jerez » Wed Oct 03, 2018 6:39 pm

I think is said this
UserMeshCollision provides the application with a method of overloading the built-in collision system for background objects.


background mean object that do not move. The collision system does not have the knowledge of concave shape. Background objects are as static work because they are broken in a series of convex polygons and because the minkoweky some of two convex shapes is a convex shape with a non zero volume, then one of the two shapes can be flat plane.

having concave shape colliding with concave shape means that at the atomic level they have to be broken into convex polygons, but there exist the possibility that the mink sum of tow convex polygon is a zero volume shape which the algorithm does not handle at all.
Julio Jerez
Moderator
Moderator
 
Posts: 11045
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Simulate ball colliding with moving parabolic surface

Postby MeltingPlastic » Wed Oct 03, 2018 7:26 pm

you would have to use something like this: http://kmamou.blogspot.com/2014/11/v-hacd-v20-is-here.html to break up your object into smaller convex shapes. Then use newton to form a compound collision consisting of all of those shapes. Or if you know the exact specifications of your object you could generate your own shapes by sampling your surface equation.
MeltingPlastic
 
Posts: 221
Joined: Fri Feb 07, 2014 11:30 pm

Re: Simulate ball colliding with moving parabolic surface

Postby MrPrezident » Thu Oct 04, 2018 11:52 am

Thanks for the responses. I'll have to see if I can get vhcad to work. I tried using a tool called convexify (it's part of a SketchUp extension), but it gave some error saying that the points were not planer or something like that. I may also try manually breaking it up. The shape is very symmetrical, so I may be able to use some duplicate along path tool or something like that.
MrPrezident
 
Posts: 13
Joined: Tue Oct 02, 2018 11:30 pm

Re: Simulate ball colliding with moving parabolic surface

Postby Julio Jerez » Thu Oct 04, 2018 1:24 pm

if you can get the shape as a collection of convex the compound collision will do the trick
For a general case http://kmamou.blogspot.com/2014/11/v-ha ... -here.html
is very good, and my guess is that the google tool is use that anyway.

since as you say there is a lot of symmetry in the shape, you can probably do better by procedurally braking into convex pieces.
just remember each convex can not be a flat surface, you need to make your shape some kind of wall with thickness. if you did not do that this is why probably the google too failed.

I can safely say that almost 100% of all convex tools rely of the minkowski property of convex shapes (look it up in Wikipedia) and flat planes do not meet the non zero volume convex necessary condition.
Julio Jerez
Moderator
Moderator
 
Posts: 11045
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles


Return to General Discussion

Who is online

Users browsing this forum: Bing [Bot] and 1 guest

cron