gandalfcode / gandalf

GANDALF (Graphical Astrophysics code for N-body Dynamics And Lagrangian Fluids)
GNU General Public License v2.0
46 stars 12 forks source link

Kelvin-Helmholtz fails with Meshless test #93

Closed dhubber closed 8 years ago

dhubber commented 8 years ago

The Kelvin-helmholtz test using the khi.dat file in tests/hydro_tests changing the sim parameter to mfvmuscl fails on the master branch (and other merged/rebased branches) with the assertion :

Assertion failed: (itype != none), function CopyDataToGhosts, file /Users/dah/code/gandalf/src/MeshlessFV/MfvCommon.cpp, line 361

Doesn't seem to happen with other ICs so not sure yet if it's a problem with setting up the ICs or something with periodic ghosts in the meshless (or a combination of the two). Used g++ 5.4 with OpenMP (2 cores) but no MPI.

rbooth200 commented 8 years ago

I'm aware of this issue. It was introduced by the reallocate branch. The call to mfvneib->SearchBoundaryGhostParticles(tghost, simbox, mfv) online 105 of MeshlessFV/MfvMusclSimulation.cpp invalidates the partdata pointer. I've fixed the bug the timing branch, but really we should stop creating local pointers to the particle data structure and let functions create their own from the hydro object when needed.

dhubber commented 8 years ago

Ah, ok. Didn't come across it myself before and didn't notice it being flagged up (trying to get my own branch working before diving into the others). Anyway, in that case I'll close this issue and also submit a pull request for my branch so (unique) issues with it can be discussed there.