generalExternalFlow problem with adjusting "resolution"

I have setup a simulation with custom .stl moving and static surfaces. The simulation works all the way through the number of iterations I want when resolution=4, but I get the following error interrupting my run when I try any other value for resolution:

At iteration 23000, t = 2.4541000000e+01
Average kinetic energy: -nan
generalExternalFlow: /home/kmalik9/palabos-v2.0r0/src/offLattice/immersedWalls3D.hh:1112: plb::RecomputeImmersedForce3D<T, Descriptor, NormalFunction>::RecomputeImmersedForce3D(NormalFunction, T, T, bool) [with T = double; Descriptor = plb::descriptors::D3Q19Descriptor; NormalFunction = SurfaceNormalFunction]: Assertion `densityOffset_ > (T) 0’ failed.
[EBKR-KMALIK-V01:02595] *** Process received signal ***
[EBKR-KMALIK-V01:02595] Signal: Aborted (6)
[EBKR-KMALIK-V01:02595] Signal code: (-6)

Any help is appreciated.

-Kaustav

Hey Kmalik9,

it’s hard to say what the exact cause of the error is from what you posted. It’s clear that it’s caused by the fact that your simulation is reaching a nan value and hence the assertion of DensityOffset> 0 fails.
The cause of the nan could be anything from stability issues to the geometry as far as i can tell.

sorry i can’t be of more help

Hi Catsgomeow,

I have noticed that the error interrupts on the iteration where the full inlet velocity is reached. For example, when I set the inlet velocity to reach (25,0,0) at iteration 2000, the run gets interrupted at iteration 2000. Does that provide any useful information?

Thanks,
Kaustav

Hey Kaustav,
To be honest I’ve personally never used the generalexternalflow example or worked with immersedwalls so I don’t know how much help I’ll be.
but i’ll do my best with what i’ve learned.
Is your velocity changing gradually or are you just setting it to 25 at step 2000 ? it could be that you’re tau value is suddenly too low or something at higher resolutions ?

Hi,

Actually no, I have set a parameter in the xml configuration file called startIter, which determines the iteration at which full inlet velocity is reached. Until then, the inlet velocity gradually increases. If that does not help, could you elaborate a little on what you were saying about the tau term?

I was just thinking that if the velocity was suddenly changing the tau might value might fall outside of the 0.5>tau>2 range (this also assumes you’re still using BGK ) but if you’re using a gradual increase this seems less likely to me. You could just print the tau value at various points to check this though.

I’m very unsure about this but if your velocity is 25 lb/lt though might be too fast, I might be wrong about this ( one of the palabos people can confirm) but I think the maximum velocity in LB units is ~ 0.4.

Are you also outputting the vtk’s ? do you see any instabilities forming before the simulation crashes?