Spheres overlap in periodic simulations

Asked by Andres Escobar

Hello,

I am currently performing a simulation of an inclined flume that goes across the X-axis with periodic walls on the sides(Y-axis). This runs without any major concern mainly thanks to the help provided on this website to many other users. However, when it comes to doing the post-processing, I have noticed that when a sphere crosses the periodic border the following thing occurs:

The sphere's Y-axis(width) coordinates do not restart despite being now on the opposite side of the flume. Instead, they keep increasing "out of the flume". This is not a big concern since this can be easily adjusted on the post-processing and I'm aware this could be useful in other scenarios. Nevertheless, When the sphere crosses the periodic border, it seems that no contact is considered against those particles that did not cross the periodic boundary(or did it more than once). This is observed after manually calculating each contact overlap. When doing this, spheres on the same "coordinates" do have normal overlaps but those who are not on the same boundary have a huge range of overlap(up to one radius) as if no interaction occurs.

Based on this I am curious if this could be a bug or if I am missing any contact law that would allow contact between particles that are not on the same "coordinates".
Finally, I have attached a few code lines regarding the engines used and how I add the spheres.
If any additional information is required, or if there are any suggestions(or ideas), I'd be delighted to read about it.
Best,

Andrés

Additional information:

How spheres are added:
(This is not really relevant, just to emphasize that I add spheres through O.bodies.append(utils.sphere()) command.

for i in np.arange(4*d,lr,2*d):
  for j in np.arange(d+hr,5*hr,2*d):
      for k in np.arange(-wc/2+3*d,wc/2-3*d,2*d):
          O.bodies.append(utils.sphere((i,k,j),radius=float(random.randint(int(100000*(d-disp)),int(100000*(d+disp))))/100000,material=sphereMat))

Engines:
O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Box_Aabb()],allowBiggerThanPeriod=True),
   InteractionLoop(
# handle sphere+sphere and box+sphere collisions
   [Ig2_Sphere_Sphere_ScGeom(),Ig2_Box_Sphere_ScGeom()],
   [Ip2_ViscElMat_ViscElMat_ViscElPhys()],
   [Law2_ScGeom_ViscElPhys_Basic()]),
   NewtonIntegrator(gravity=(g*sin(slope),0,-g*cos(slope)), damping=0), #add gravity
   VTKRecorder(fileName=addrec+'3d-'+str(zeta)+'-vtk-',recorders=['all'],iterPeriod=it),
]

Question information

Language:
English Edit question
Status:
Answered
For:
Yade Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Karol Brzezinski (kbrzezinski) said :
#1

Hi Andres,

I am not familiar with the history of your simulation. Thus, I am not sure what do you mean by 'periodic'. The MWE would be useful [1].

When it comes to positions of spheres in periodic simulations, Bruno Chareyre once commented it like this [2]:
"Particles leaving from right and appearing on left is just a visualization trick. In memory positions remain untouched, they are all over the place instead of staying in their initial period. "

Cheers,
Karol

[1] https://www.yade-dem.org/wiki/Howtoask
[2] https://answers.launchpad.net/yade/+question/696150

Can you help with this problem?

Provide an answer of your own, or ask Andres Escobar for more information if necessary.

To post a message you must log in.