Skip to content

Commit

Permalink
Bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
abkein committed Jan 15, 2025
1 parent 201c2c7 commit 7aae1a0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/fix_cluster_crush_delete.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@

#include <cmath>
#include <cstring>
#include <algorithm>
#include <unordered_map>

using namespace LAMMPS_NS;
Expand Down Expand Up @@ -376,6 +377,8 @@ void FixClusterCrushDelete::pre_exchange()
}
}

std::sort(p2m.data(), p2m.data() + p2m.size(), [](auto a, auto b) { return a > b; });

c2c.reset();
c2c[comm->me] = clusters2crush_local;
::MPI_Allgather(&clusters2crush_local, 1, MPI_INT, c2c.data(), 1, MPI_INT, world);
Expand Down

0 comments on commit 7aae1a0

Please sign in to comment.