SPH and walls

Submitted by moritzhoefert on Wed, 10/12/2011 - 22:02

Hello all,

what is the best way of incorporating walls into SPH simulations? I have tried three options (see attachment to this post):

1. hybrid pair style. somehow pair_hybrid seems to be incompatible with sph... probably because of the way how pair_hybrid determines the number of sub styles.
2. union of primitives. A particle penetrated into the wall. Lowering the time step by an order of magnitude did not help
3. mesh/tet and wall/region/sph. Apparently there are some implementations missing: ERROR: RegTetMesh::surface_interior()This feature is not available for tet mesh regions

Did I do anything wrong? Who has experience with walls that are more complicated than the boundary surface of a primitive? What are your suggestions?

Thanks for any help!
Regards,
Moritz

PS: The file bucket.stl loaded in the hybrid example is taken from the liggghts examples.

AttachmentSize
Plain text icon sph-union.txt2.44 KB
Plain text icon sph-vtk.txt2.3 KB
Plain text icon sph-hybrid.txt2.88 KB
ckloss's picture

ckloss | Thu, 10/13/2011 - 10:02

>>1. hybrid pair style. somehow pair_hybrid seems to be incompatible with sph
should be only an arg-parsing problem - will be fixed in the next release
>>2. union of primitives. A particle penetrated into the wall.
That should work - will discuss it with Andreas
>>3. mesh/tet and wall/region/sph. Apparently there are some implementations missing:
That's correct

Christoph

moritzhoefert | Wed, 10/19/2011 - 11:35

Dear Andreas, dear Christoph,

I would appreciate your opinion on that issue a lot. It would be good to know where I have to look for the error in the input file regarding the region issue.

@ all: Did anyone implement the missing functions in fix wall/region/sph like RegTetMesh::surface_interior()?

Thank you for your replies!
Cheers,
Moritz

ckloss's picture

ckloss | Wed, 10/19/2011 - 14:33

I will come back to you as I have time to take a closer look, but it may take a little while

>>@ all: Did anyone implement the missing functions in fix wall/region/sph like RegTetMesh::surface_interior()?
I do not think so... this will require some re-write of the mesh implementation that has not yet been tackled.

Cheers and greets from Linz, Christoph

moritzhoefert | Wed, 01/11/2012 - 09:03

Hi Andreas and Christoph,

thank you for addressing the problem!

All the best,
Moritz

moritzhoefert | Wed, 01/11/2012 - 17:44

Hello Andreas,

could you publish the liggghts script you tested the bug fix with? Then I could use yours as a template. I still get the error with my liggghts sph script although I fixed the bug according to the description above. Thanks in advance!

Cheers,
Moritz

aaigner's picture

aaigner | Tue, 01/10/2012 - 15:07

Hi Moritz,

Sorry, it took some time, but now I found the bug. It is in RegBlock::surface_interior in region_block.cpp.
Replace in line 136:
if (x[0] < xlo || x[0] > xhi || x[1] < ylo || x[1] > zhi || x[2] < ylo || x[2] > zhi) return 0;
by
if (x[0] < xlo || x[0] > xhi || x[1] < ylo || x[1] > yhi || x[2] < zlo || x[2] > zhi) return 0;
This bug will also be fixed in the next release of Liggghts.

One remark concerning your example: Be aware the fact that (additional) convex edges, which are created by union/intersection of regions are not computed directly and hence wall/particles forces in the cutoff volume around these points suffer from inaccuracies. (Check the documentation of wall/region/sph.. the second important note)

Regards,
Andreas