aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/predict-refine.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/predict-refine.c b/src/predict-refine.c
index 97371172..2d845feb 100644
--- a/src/predict-refine.c
+++ b/src/predict-refine.c
@@ -618,6 +618,9 @@ static int iterate(struct reflpeak *rps, int n, UnitCell *cell,
for ( i=0; i<num_params; i++ ) {
// STATUS("Shift %i = %e\n", i, gsl_vector_get(shifts, i));
+ if ( isnan(gsl_vector_get(shifts, i)) ) {
+ gsl_vector_set(shifts, i, 0.0);
+ }
}
/* Apply shifts */