I’m trying to add a rigid object in MLS-MPM simulation to simulate interaction between rigid objects and elastic objects, I’m wondering if there is any example to show how to add a rigid object in a MLS-MPM simulation. Thanks.
Hi,
A simple solution would be to restrict the degrees of freedom of an elastic body to SO(2) in 2D and SO(3) in 3D. For example, this repo GitHub - runck/taichi_boat_on_sea shows a quick fix to simulate rigid bodies within the MLS-MPM framework.
If your rigid-body contains thin-shells (which is normally considered hard to solve using material point methods), you might also want to try CPIC. Here’s a sample implementation of CPIC and MPM using Taichi: GitHub - Zhijie-YU/MLS_MPM_CPIC: CPIC cases implemented with taichi.
Best,
TT
Hi Tiantian, thanks a lot for your reply, very useful. I will have a look and try
Hello, I’ve been learning about this recently, but I’m getting an error when I try to run the code on the https://github.com/Zhijie-YU/MLS_MPM_CPIC/blob/main/mpm_fan_rotation.py page. I am not sure what is causing this and if it is due to a version iteration.How can I solve this problem? Pleace
Yes, it does have something to do with version updates, adding [None] to the index will solve the problem!
Hello, I also have some problems when running the mpm_fan_rotation.py,
How did you change ‘’‘J_line[None] = m_line * length**2 / 3.0 * n_bodies # total J for a fan’‘’ this code to let both variables in the same data type? It seems some variables in Expr and some are ScalarField.
Here is :J_line[None] = m_line[None] * length ** 2 / 3.0 * n_bodies
here
Hi, Yunlong
Thanks for the answer, except for some ‘ScalarField’ Problems, it still has some problems showing that the type of og_Vec is invalid.
Because [ omega[None] ] should be used here as well. u didnt use [None]
Hello!
I made those changes and the rotation sample compiled.
Although, I run it and it freezes after starting. It never renders but my GPU is working a lot. I can hear its fans spinning and its temperature is 73º on average. Something is quite wrong with it. I tried to use Vulkan with same results.
By the way, I am trying to code a sample using this algo (MLS MPM CPIC) on a Vulkan wrapper for prototyping purposes before I implement it in a bigger project but haven’t had luck yet.
Particles get stuck after reaching these rigid boundaries. They also traspass them (using Nvidia Nsight Graphics acceleration structure viewer):
These are the rigid particles over a cuboid mesh (using Nvidia Nsight Graphics acceleration structure viewer):
You can see here how they get sticky on surfaces:
I hope you can point me out what I can do in order to prevent particles to cross rigid boundaries and get trap there.
Cheers,
Jaime.