While testing the Cut Drop Algorithm in MueLu_CoalesceDropFactory_def.hpp using the unit tests in CoalesceDropFactory.cpp, I noticed that some entries with a value of -1 were being kept while other entries that also have a value of -1 were being dropped in the same row. This is caused by a combination of the fact that at least one off diagonal entry must be kept and a corner case when threshold is less than 1 which causes only the first off diagonal entry to be kept. A check for this scenario needs to be added so that entries of the same value are either all kept or all dropped. The unit test should also be modified accordingly.
Bug Report
@jhux2 @cgcgcg @csiefer2
Description
While testing the Cut Drop Algorithm in MueLu_CoalesceDropFactory_def.hpp using the unit tests in CoalesceDropFactory.cpp, I noticed that some entries with a value of -1 were being kept while other entries that also have a value of -1 were being dropped in the same row. This is caused by a combination of the fact that at least one off diagonal entry must be kept and a corner case when threshold is less than 1 which causes only the first off diagonal entry to be kept. A check for this scenario needs to be added so that entries of the same value are either all kept or all dropped. The unit test should also be modified accordingly.
https://github.com/trilinos/Trilinos/blob/bf922e75428ef7dd925811f0a532d05dd9cff808/packages/muelu/test/unit_tests/CoalesceDropFactory.cpp#L1410-L1440
https://github.com/trilinos/Trilinos/blob/bf922e75428ef7dd925811f0a532d05dd9cff808/packages/muelu/src/Graph/MatrixTransformation/MueLu_CoalesceDropFactory_def.hpp#L577-L593