Particle splitting "a la EAGLE"
This implements a new small physics module: overly-massive particle splitting.
At a rebuild time that does not coincide with a repartition (to avoid creating unnecessary trouble),
we loop over all the gas particles and identify which ones are above a given mass threshold. These
are then split into two equivalent pieces and slightly offset from each other.
We create a companion gpart
as well and relink the particle.
All this is done on a node-by-node basis and just before rebuild such that the reorganisation and possible exchange
of particles is done correctly.
Additional subgrid-related fields that also need splitting are offset to the respective subgrid implementation.
The only bit that needs to be properly taken care of is the reallocation of the arrays in case we run out of space.
Merge request reports
Activity
Note that this should happen rarely in any real simulation and is really only here to avoid dramatic situations. However, given that the low-z ICs we use were run with a code that does not split particles, the first few rebuilds trigger a lot of these events. Which makes it relatively easy to verify that the feature works.
I have run our usual test cases but if you can have a look at it that would be great.
added 1 commit
- 20ebce4a - When creating a new particle, preserve the odd/even nature of IDs.
added 21 commits
-
20ebce4a...220dbc37 - 20 commits from branch
master
- be65a629 - Merge branch 'master' into particle_splitting
-
20ebce4a...220dbc37 - 20 commits from branch
added 1 commit
- 303487b1 - Add the splitting of particles to the list of changes from original EAGLE in the README file.
changed milestone to %Paris
added feature request label
- Resolved by Matthieu Schaller
- Resolved by Matthieu Schaller
- Resolved by Matthieu Schaller
added 32 commits
-
303487b1...74145955 - 30 commits from branch
master
- 99ffc5f3 - Merge branch 'master' into particle_splitting
- a2df5493 - Only duplicate the gpart in the particle splitting code when we are running with gravity.
-
303487b1...74145955 - 30 commits from branch
Ah yes, indeed! Thanks for checking. I have protected the lines touching the gpart with a check for gravity policy.
Edited by Matthieu Schaller- Resolved by Matthieu Schaller
- Resolved by Peter W. Draper
added 1 commit
- f33ee46c - Print the reallocation messages only in verbose mode.