From d6c8a6c2c453fd00ae7530f2dbd4558b72fa110a Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Fri, 29 Jul 2022 18:11:26 -0700 Subject: [PATCH] sfdpgen SparseStressMajorizationSmoother_new: remove inverse distance weighting This scheme is unused. --- lib/sfdpgen/post_process.c | 7 ------- lib/sfdpgen/post_process.h | 2 +- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/lib/sfdpgen/post_process.c b/lib/sfdpgen/post_process.c index a25201dae..588525857 100644 --- a/lib/sfdpgen/post_process.c +++ b/lib/sfdpgen/post_process.c @@ -361,13 +361,6 @@ StressMajorizationSmoother SparseStressMajorizationSmoother_new(SparseMatrix A, w[nz] = -1/(dist*dist); } break; - case WEIGHTING_SCHEME_INV_DIST: - if (dist*dist == 0){ - w[nz] = -100000; - } else { - w[nz] = -1/(dist); - } - break; case WEIGHTING_SCHEME_NONE: w[nz] = -1; break; diff --git a/lib/sfdpgen/post_process.h b/lib/sfdpgen/post_process.h index 84c58d593..343bdf0f9 100644 --- a/lib/sfdpgen/post_process.h +++ b/lib/sfdpgen/post_process.h @@ -75,7 +75,7 @@ typedef StressMajorizationSmoother SparseStressMajorizationSmoother; void SparseStressMajorizationSmoother_delete(SparseStressMajorizationSmoother sm); -enum {WEIGHTING_SCHEME_NONE, WEIGHTING_SCHEME_INV_DIST, WEIGHTING_SCHEME_SQR_DIST}; +enum {WEIGHTING_SCHEME_NONE, WEIGHTING_SCHEME_SQR_DIST}; SparseStressMajorizationSmoother SparseStressMajorizationSmoother_new(SparseMatrix A, int dim, double lambda, double *x, int weighting_scheme, int scale_initial_coord); -- 2.40.0