From bd8495794ad8a693081efab20598da19d01c02ec Mon Sep 17 00:00:00 2001 From: Salvatore Filippone Date: Tue, 28 Sep 2021 17:59:38 +0200 Subject: [PATCH] More fix for logarithmic transformation. --- amgprec/impl/aggregator/newmatch_interface.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/amgprec/impl/aggregator/newmatch_interface.cpp b/amgprec/impl/aggregator/newmatch_interface.cpp index a4f716c3..aee12aa4 100644 --- a/amgprec/impl/aggregator/newmatch_interface.cpp +++ b/amgprec/impl/aggregator/newmatch_interface.cpp @@ -92,8 +92,13 @@ psb_i_t dnew_Match_If(psb_i_t ipar, psb_i_t matching, psb_d_t lambda, if (weights[i]>maxweight) maxweight=weights[i]; if (weights[i]= 0 && lambda <= 1.0){ + lambda = lambda*eps + (1.0-lambda)*(fmax(maxweight-2.0*minweight,0.0) ); + } fprintf(stderr,"Calling matching: pre %d nt %d lambda %g %g %g\n", preprocess,nt,lambda,maxweight,minweight);