Skip to content
Snippets Groups Projects

Alternative definition of the number of neighbours

Merged Matthieu Schaller requested to merge eagle_ngb_def2 into master
1 unresolved thread

Better way to implement the alternative definition of the neighbour number.

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
318 of particles to use. By default, we use
319
320 .. math::
321 n_i = \sum_j W(\|\mathbf{r}_i - \mathbf{r}_j\|, h_i)
322
323 but switching on the ``use_mass_weighted_num_ngb`` flag changes the
324 defintion to:
325
326 .. math::
327 n_i = \frac{\rho_i}{m_i}
328
329 where the density has been computed in the traditional SPH way
330 (i.e. :math:`\rho_i = \sum_j m_j W(\|\mathbf{r}_i - \mathbf{r}_j\|,
331 h_i)`). Note that in the case where all the particles in the simulation
332 have the same mass, the two definitions lead to the same number density
333 value.
  • Other than the final documentation comment this looks good to me.

  • added 1 commit

    • 2639e8ec - Add a message of caution about the alternative neighbour number definition.

    Compare with previous version

  • Good suggestion. Done.

  • mentioned in commit be03ddca

  • Please register or sign in to reply
    Loading