cb-geo / mpm

CB-Geo High-Performance Material Point Method
https://www.cb-geo.com/research/mpm
Other
247 stars 82 forks source link

Neighbour Particles #569

Closed bodhinandach closed 4 years ago

bodhinandach commented 4 years ago

I am adding some functions to add neighbor particles in a similar fashion to cells. There are three functions of compute_particle_neighbours overloaded:

  1. global: if needed for all particles
  2. for particles inside a specific cell: suppose free surface cell, or cell with refinement

I will add testing in the following commits. Let me know if you have any comments and suggestions to optimize it.

codecov[bot] commented 4 years ago

Codecov Report

Merging #569 into develop will increase coverage by 0.05%. The diff coverage is 100%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #569      +/-   ##
===========================================
+ Coverage     96.8%   96.86%   +0.05%     
===========================================
  Files          111      111              
  Lines        23658    24044     +386     
===========================================
+ Hits         22902    23288     +386     
  Misses         756      756
Impacted Files Coverage Δ
include/particles/particle_base.h 100% <ø> (ø) :arrow_up:
include/mesh.h 83.33% <ø> (ø) :arrow_up:
include/mesh.tcc 95.12% <100%> (+0.19%) :arrow_up:
tests/graph_test.cc 93.61% <100%> (ø) :arrow_up:
include/particles/particle.tcc 93.99% <100%> (+0.06%) :arrow_up:
include/solvers/mpm_base.tcc 72.05% <100%> (ø) :arrow_up:
tests/mesh_neighbours_test.cc 100% <100%> (ø)
tests/mpi_transfer_particle_test.cc 100% <100%> (ø) :arrow_up:
include/particles/particle.h 100% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 92249b9...fbe5f34. Read the comment docs.

bodhinandach commented 4 years ago

@kks32 Sure! Thanks a lot, also for the modification. I will make the test sometime in the upcoming week.

bodhinandach commented 4 years ago

@kks32 as for the add_neighbour function in particle, I meant to have this function for adding a single particle to the neighbourhood, but not necessarily do the search for the cell. Think about adaptive particle refinement or cloning. But, I guess it can be removed at the moment as it is not currently used.

bodhinandach commented 4 years ago

@kks32 @srhgk2 can you check this once more? This is ready to merge I guess.

kks32 commented 4 years ago

@bodhinandach It's not done yet, we need to still add tests to check if the particle neighbours are working fine when cells are distributed across different MPI tasks. I'll update your test cases with MPI calls

bodhinandach commented 4 years ago

@kks32 Thanks for adding the MPI test. Just curiosity, with the current test format, can you run in both non-mpi and mpi?

kks32 commented 4 years ago

@bodhinandach It will run only for MPI

lock[bot] commented 4 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

lock[bot] commented 4 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.