# Physics Simulation Forum

 Page 1 of 1 [ 5 posts ]
 Print view Previous topic | Next topic
Author Message
 Post subject: Position Based Meshless PlasticityPosted: Wed May 31, 2017 7:16 am

Joined: Wed May 31, 2017 6:19 am
Posts: 4
Hi all,

I'm currently trying to work through a Position Based approach to a soft body. The basic idea is to take Position Based Fluids (PBF) and use a constitutive model instead of the density constraint. Since it's a meshless model I'm using the idea of an incremental deformation gradient from here and trying to use a fixed corotated constitutive model from here.

The constraint would be to minimize the energy density for each particle. Calculating the energy is relatively easy but I'm having a hard time deriving the gradient of the energy with respect to the new particle position.

The snow paper gives an equation for the derivative of the energy with respect to the deformation gradient:

Attachment:

energy.png [ 3.76 KiB | Viewed 1963 times ]

I believe I could just multiply that by the derivative of the deformation gradient with respect to the new positions(X is a matrix of current positions, Y is a matrix of predicted positions):

Attachment:

deformation.png [ 3.54 KiB | Viewed 1963 times ]

But... that's just the incremental update so it needs to be multiplied by the cumulative deformation (which for differentiation is just a constant). Since I want the gradient of the energy constraint my understanding is that I would multiply the above two derivatives (which are both 3x3 matrices) by the gradient of the shape function to end up with a 3 element vector. That is the part of PBF that I don't completely understand.

Attachment:

pbf_constraint_gradient.png [ 4.85 KiB | Viewed 1963 times ]

Shows the gradient of the density constraint. The gradient for each particle is summed up and used in the lambda calculation but based on the above formulation don't they end up canceling out? Since the calculation for the ith particle is actually the sum of all other particles.

I'd love some help understanding the lambda calculation in PBF or the derivative of the deformation gradient with respect to new positions.

Thanks

Top

 Post subject: Re: Position Based Meshless PlasticityPosted: Thu Jun 01, 2017 11:26 pm

Joined: Wed May 31, 2017 6:19 am
Posts: 4
I found a helpful implementation of the Position Based Fluids paper that showed me how the constraint is actually calculated.

https://github.com/InteractiveComputerGraphics/PositionBasedDynamics/blob/master/PositionBasedDynamics/PositionBasedFluids.cpp

Inside the function "computePBFLagrangeMultiplier" it sums the gradient of all neighbor particles and separately sums the squared norm of all gradients. At the end it adds the squared norm of the sum of the gradients which is the ith particle's contribution. That was the part I misunderstood, even though the signs are opposite that doesn't matter if it is summing the squared norm (where they will all be positive).

Still working through the gradient of the constraint, but I'm thinking it may be easier to use the Strain Based Dynamics approach first since that doesn't require extracting the rotation.

Top

 Post subject: Re: Position Based Meshless PlasticityPosted: Mon Jun 05, 2017 6:36 am

Joined: Wed May 31, 2017 6:19 am
Posts: 4
Working through the gradient calculation using the Strain Based Dynamics approach, here's what I got (first time writing LaTeX, it's kinda funky):

Attachment:

partial derivative deformation.png [ 18.07 KiB | Viewed 1744 times ]

There's a problem here once you start using the SPH weights.

Depending on how you decide to apply it, is it the weight calculated for the predicted position? The current position?

Or maybe multiply each column of Y by the weight at the predicted position and each column of X by the weight at the current position?

If you multiply Y by the predicted weight than the above derivation falls apart because each column of XY depends on all 3 components, instead of giving you clean columns like above. I guess that's not a big deal, I might try both ways and see which gives good results.

Top

 Post subject: Re: Position Based Meshless PlasticityPosted: Thu Jun 29, 2017 8:47 pm

Joined: Sat Aug 19, 2006 11:52 pm
Posts: 211
Have you tried the approach described in Muller "Meshless Deformations Based on Shape Matching"? AFAIK that's a popular way to implement meshless soft bodies with plastic deformations in a position-based simulation that might be worth a look. This paper from the same author has some useful references: http://matthias-mueller-fischer.ch/publications/stablePolarDecomp.pdf

Top

 Post subject: Re: Position Based Meshless PlasticityPosted: Wed Nov 15, 2017 2:21 am

Joined: Wed May 31, 2017 6:19 am
Posts: 4
This is a little delayed but...

I have been looking at the shape matching papers. The problem with those is even though they are "meshless", they still have the idea of an "original" position. For my purposes that doesn't really work since I'm working with a fluid. I've tried it where the current positions are considered the original position for just that frame, but it doesn't preserve volume very well and doesn't have the best performance. I'm guessing there is just too much drift per frame.

I ended up using position based fluids combined with "fake" friction. I calculate the average velocity of all the neighbor particles (using SPH weights as well) and then constrain the motion of each particle to be along that direction. It kind of works but has weird artifacts so I'm still playing with it.

Top

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

#### 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