Parallel problem: can't find particles crossing processors

Submitted by cheng1988sjtu on Fri, 03/03/2017 - 03:16

Hi,

I'm using CFDEM coupling 3.5.1, which couples Openfoam 2.4.x and LIGGGHTS 3.5.0. and I've tried to run one settling case with 4 processors. Here is what I found that's wierd behavior:

I have 800 particles, and in the drag model, I added the following line to output the particle location :

if (index==200) //index is particle ID, it's ranging from 0 to 799, so there must be one particle index =200
{
Pout << "pos = " << particleCloud_.position(index)<<endl;
}

so normally, I will get some output like:
at time t = 0.5s
[0] pos = 0.001
...
it's interesting to see that when the particle crosses the processors, there is no output of this line, for example (my fluid dt = 0.0001):

at t=0.5 s, out put is [0] pos = 0.001
at t = 0.5001s, output is nothing!!!
at t = 0.5002s, output is [1] pos = 0.0045

This means that when particles crosses the processors, there is one time step that the code cannot find the particle, how is that? Does anyone has this experience? how to fix this problem??

Thanks!

cheng1988sjtu | Fri, 03/03/2017 - 03:33

The output line will execute when the cellID is valid, i.e. particleCloud_.cellIDs()[index][0]>=0, and if we trace back to the problem, it seems to be due to findCell() function in locateM(), anybody has a clue?
thanks!

C.Z. U of D

cheng1988sjtu | Mon, 03/06/2017 - 04:24

For those who had the same problem, it looks like it's because some times particles are slightly outside of the simulation box, and in this case, it makes sense that the cellID using findCell is invalid.

C.Z. U of D

j-kerbl's picture

j-kerbl | Wed, 03/08/2017 - 17:05

Hi Cheng,

thanks for posting the answer!

Cheers,
Josef