Skip to content
Snippets Groups Projects

Particle splitting "a la EAGLE"

Merged Matthieu Schaller requested to merge particle_splitting into master

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

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Peter W. Draper
  • Matthieu Schaller added 32 commits

    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.

    Compare with previous version

  • Ah yes, indeed! Thanks for checking. I have protected the lines touching the gpart with a check for gravity policy.

    Edited by Matthieu Schaller
  • Matthieu Schaller resolved all discussions

    resolved all discussions

  • Peter W. Draper
  • Peter W. Draper
  • If you resolve those minor issue it all looks ready to go, but we should make an issue to consider using the threadpool for the particle loops.

  • added 1 commit

    • f33ee46c - Print the reallocation messages only in verbose mode.

    Compare with previous version

  • Thanks! And, yes, I agree; an issue about threadpooling the whole thing would be good.

  • Peter W. Draper resolved all discussions

    resolved all discussions

  • Peter W. Draper resolved all discussions

    resolved all discussions

  • Peter W. Draper resolved all discussions

    resolved all discussions

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading